x86: use pteval_t for _PAGE_FOO
authorJeremy Fitzhardinge <jeremy@goop.org>
Mon, 26 May 2008 22:30:58 +0000 (23:30 +0100)
committerThomas Gleixner <tglx@linutronix.de>
Tue, 27 May 2008 08:01:20 +0000 (10:01 +0200)
commit4226ab93d8ae3fd895abe45879fe34d489a98718
tree4922874bef40068a1ad2adff0f9f265deabed9af
parente490517a039a99d692cb3a5561941b0a5f576172
x86: use pteval_t for _PAGE_FOO

Rather than making _PAGE_* constants signed, and then relying on
sign-extension to make sure that masks derived from them are wide
enough, just explicitly type them pteval_t.  This guarantees that they
and any derived values are the right size for the current pte format.

The reliance on sign extension is fragile, and invokes some very
subtle corners of the C type system.

Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
include/asm-x86/pgtable.h