MP table: Test 0xe0000 when searching MP float pointer structure
authorSepherosa Ziehau <sephe@dragonflybsd.org>
Sat, 27 Jun 2009 13:36:37 +0000 (21:36 +0800)
committerSepherosa Ziehau <sephe@dragonflybsd.org>
Sat, 27 Jun 2009 13:42:31 +0000 (21:42 +0800)
MultiProcessor Specification version 1.4 never mentions this location,
however, some brain-dead BIOSes put MP table there ...  "Extened BIOS"
location is taken from mptable(8) in the base system.

Reported-and-Tested-by: ruse39 on EFnet #dragonflybsd
sys/platform/pc32/i386/mp_machdep.c

index 3dd512a..eba146f 100644 (file)
@@ -71,6 +71,7 @@
 #define WARMBOOT_SEG           (KERNBASE + 0x0469)
 
 #define BIOS_BASE              (0xf0000)
+#define BIOS_BASE2             (0xe0000)
 #define BIOS_SIZE              (0x10000)
 #define BIOS_COUNT             (BIOS_SIZE/4)
 
@@ -391,6 +392,11 @@ mptable_search(void)
        if ((x = mptable_search_sig(target, BIOS_COUNT)) > 0)
                return x;
 
+       /* search the extended BIOS */
+       target = (u_int32_t)BIOS_BASE2;
+       if ((x = mptable_search_sig(target, BIOS_COUNT)) > 0)
+               return x;
+
        /* nothing found */
        return 0;
 }