Sophie

Sophie

distrib > Mageia > 8 > x86_64 > by-pkgid > 32ff79a2cf327f1f341c4104cb58a812 > files > 2

cpuinfo-1.0-0.20090313.29.mga8.src.rpm

=== modified file 'src/cpuinfo-x86.c'
--- src/cpuinfo-x86.c	2009-03-12 23:58:25 +0000
+++ src/cpuinfo-x86.c	2009-05-07 14:46:19 +0000
@@ -1340,7 +1340,11 @@
 	if (bsf_clobbers_eflags())
 	  feature_set_bit(BSFCC);
 
-	if (feature_get_bit(LM))
+	/*
+	 * FIXME: checking size_t size is lame and will be dependent on build,
+	 * 	  is there any way to check EFER.LMA from userspace perhaps?
+	 */
+	if (feature_get_bit(LM) && sizeof(size_t) == 8)
 	  cpuinfo_feature_set_bit(cip, CPUINFO_FEATURE_64BIT);
 
 	if (feature_get_bit(MMX) ||