diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2006-04-18 17:42:25 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2006-04-18 17:42:25 +0000 |
commit | 3d9fe2b09dea6c2b02b26080914a3bbecd8bc757 (patch) | |
tree | f8153b652b47bc4c6707f758eaef9de85cb05aa8 /sys | |
parent | a79d4650269ccbf7d834e122e74d6caee0d0c49b (diff) |
If mpbios doesn't specify a valid CPU signature, fall back on information
from the boot processor.
ok mpf@, mickey@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/i386/i386/mpbios.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/sys/arch/i386/i386/mpbios.c b/sys/arch/i386/i386/mpbios.c index 2c9fb7221fe..ad9e667364c 100644 --- a/sys/arch/i386/i386/mpbios.c +++ b/sys/arch/i386/i386/mpbios.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mpbios.c,v 1.7 2005/12/12 13:54:09 mickey Exp $ */ +/* $OpenBSD: mpbios.c,v 1.8 2006/04/18 17:42:24 kettenis Exp $ */ /* $NetBSD: mpbios.c,v 1.2 2002/10/01 12:56:57 fvdl Exp $ */ /*- @@ -740,6 +740,17 @@ mpbios_cpu(ent, self) * of the flags on at least some MP bioses */ caa.feature_flags = entry->feature_flags; + + /* + * XXX some MP bioses don't specify a valid CPU signature; use + * the result of the 'cpuid' instruction for the processor + * we're running on + */ + if ((caa.cpu_signature & 0x00000fff) == 0) { + extern int cpu_id, cpu_feature; + caa.cpu_signature = cpu_id; + caa.feature_flags = cpu_feature; + } #endif config_found_sm(self, &caa, mp_print, mp_match); |