summaryrefslogtreecommitdiffstats
path: root/arch/i386/kernel/verify_cpu.S
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2007-07-11 12:18:29 -0700
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-07-12 10:55:54 -0700
commitec481536b15eb0520d8f0204b0294480050fe1f8 (patch)
tree3f959a26ca58477734ea1e4d5370b2d3a33a1680 /arch/i386/kernel/verify_cpu.S
parentf8c09377d754f35a135454181b869ab527cc0757 (diff)
downloadtalos-op-linux-ec481536b15eb0520d8f0204b0294480050fe1f8.tar.gz
talos-op-linux-ec481536b15eb0520d8f0204b0294480050fe1f8.zip
Unify the CPU features vectors between i386 and x86-64
Unify the handling of the CPU features vectors between i386 and x86-64. This also adopts the collapsing of features which are required at compile-time into constant tests from x86-64 to i386. Signed-off-by: H. Peter Anvin <hpa@zytor.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/i386/kernel/verify_cpu.S')
-rw-r--r--arch/i386/kernel/verify_cpu.S12
1 files changed, 6 insertions, 6 deletions
diff --git a/arch/i386/kernel/verify_cpu.S b/arch/i386/kernel/verify_cpu.S
index f1d1eacf4ab0..3efc5c137d14 100644
--- a/arch/i386/kernel/verify_cpu.S
+++ b/arch/i386/kernel/verify_cpu.S
@@ -20,7 +20,7 @@ verify_cpu:
testl $(1<<18),%eax
jz bad
#endif
-#if REQUIRED_MASK1 != 0
+#if REQUIRED_MASK0 != 0
pushfl # standard way to check for cpuid
popl %eax
movl %eax,%ebx
@@ -39,14 +39,14 @@ verify_cpu:
pushfl
popl %eax
cmpl %eax,%ebx
- jz bad # REQUIRED_MASK1 != 0 requires CPUID
+ jz bad # REQUIRED_MASK0 != 0 requires CPUID
movl $0x0,%eax # See if cpuid 1 is implemented
cpuid
cmpl $0x1,%eax
jb bad # no cpuid 1
-#if REQUIRED_MASK1 & NEED_CMPXCHG64
+#if REQUIRED_MASK0 & NEED_CMPXCHG64
/* Some VIA C3s need magic MSRs to enable CX64. Do this here */
cmpl $0x746e6543,%ebx # Cent
jne 1f
@@ -79,10 +79,10 @@ verify_cpu:
#error add proper model checking here
#endif
- andl $REQUIRED_MASK1,%edx
- xorl $REQUIRED_MASK1,%edx
+ andl $REQUIRED_MASK0,%edx
+ xorl $REQUIRED_MASK0,%edx
jnz bad
-#endif /* REQUIRED_MASK1 */
+#endif /* REQUIRED_MASK0 */
popfl
xor %eax,%eax
OpenPOWER on IntegriCloud