Re: [PATCH, resend] x86: x86_{phys,virt}_bits field also for i386

From: H. Peter Anvin
Date: Tue Sep 02 2008 - 18:13:22 EST


Jan Beulich wrote:
Make the x86_{phys,virt}_bits common for 32- and 64-bits, and use the
former in ioremap's phys_addr_valid() check also on 32bit/PAE.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
c->x86_cache_alignment = 32;
c->x86_clflush_size = 32;
+#ifdef CONFIG_X86_PAE
+ c->x86_phys_bits = 36;
+#else
+ c->x86_phys_bits = 32;
+#endif
+ c->x86_virt_bits = 32;

This is logical but wrong. This is supposed to be about the CPU, not about the kernel.

That would mean using the physbit information if it is present, otherwise (pae_feature_bit ? 36 : 32).

-hpa
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/