Messages in this thread Patch in this message | | | Date | Thu, 04 Mar 2004 12:39:01 -0500 | From | Brian Gerst <> | Subject | [PATCH] PnP BIOS exception fixes |
| |
This patch fixes two errors in fixup_exception() for PnP BIOS faults: - Check for the correct segments used for the BIOS - Fix asm constraints so that EIP and ESP are properly reloaded
-- Brian Gerst diff -urN linux-bk/arch/i386/mm/extable.c linux/arch/i386/mm/extable.c --- linux-bk/arch/i386/mm/extable.c 2004-02-15 00:41:41.000000000 -0500 +++ linux/arch/i386/mm/extable.c 2004-03-04 10:45:32.988904488 -0500 @@ -12,7 +12,7 @@ const struct exception_table_entry *fixup; #ifdef CONFIG_PNPBIOS - if (unlikely((regs->xcs | 8) == 0x88)) /* 0x80 or 0x88 */ + if (unlikely((regs->xcs & ~15) == (GDT_ENTRY_PNPBIOS_BASE << 3))) { extern u32 pnp_bios_fault_eip, pnp_bios_fault_esp; extern u32 pnp_bios_is_utter_crap; @@ -21,7 +21,7 @@ __asm__ volatile( "movl %0, %%esp\n\t" "jmp *%1\n\t" - : "=a" (pnp_bios_fault_esp), "=b" (pnp_bios_fault_eip)); + : : "g" (pnp_bios_fault_esp), "g" (pnp_bios_fault_eip)); panic("do_trap: can't hit this"); } #endif | |