summaryrefslogtreecommitdiff
path: root/sys/arch/i386
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2023-08-16 09:51:40 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2023-08-16 09:51:40 +0000
commit249092c9f640ccd7b6a28ed40135471f8fcc19c8 (patch)
tree3838fc1b4fde25b3ef17eae1ac193311b22b3897 /sys/arch/i386
parent1bb3db5c2039da1aa32059becfca462ef863307e (diff)
avoid bios sign msr on intel family < 6
the pentium msr list in the sdm does not include it
Diffstat (limited to 'sys/arch/i386')
-rw-r--r--sys/arch/i386/i386/machdep.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/arch/i386/i386/machdep.c b/sys/arch/i386/i386/machdep.c
index 7bbefdfcd6c..9ce08823da5 100644
--- a/sys/arch/i386/i386/machdep.c
+++ b/sys/arch/i386/i386/machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: machdep.c,v 1.667 2023/08/16 07:26:05 jsg Exp $ */
+/* $OpenBSD: machdep.c,v 1.668 2023/08/16 09:51:39 jsg Exp $ */
/* $NetBSD: machdep.c,v 1.214 1996/11/10 03:16:17 thorpej Exp $ */
/*-
@@ -1866,7 +1866,8 @@ identifycpu(struct cpu_info *ci)
if (strcmp(cpu_vendor, "AuthenticAMD") == 0 &&
ci->ci_family >= 0x0f) {
level = rdmsr(MSR_PATCH_LEVEL);
- } else if (strcmp(cpu_vendor, "GenuineIntel") == 0) {
+ } else if (strcmp(cpu_vendor, "GenuineIntel") == 0 &&
+ ci->ci_family >= 6) {
wrmsr(MSR_BIOS_SIGN, 0);
CPUID(1, dummy, dummy, dummy, dummy);
level = rdmsr(MSR_BIOS_SIGN) >> 32;