[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <d2cfb4dc7c7d28ddde78.1211268380@localhost>
Date: Tue, 20 May 2008 08:26:20 +0100
From: Jeremy Fitzhardinge <jeremy@...p.org>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Ingo Molnar <mingo@...e.hu>,
LKML <linux-kernel@...r.kernel.org>,
Thomas Gleixner <tglx@...utronix.de>,
Hugh Dickins <hugh@...itas.com>, Theodore Tso <tytso@....edu>,
Gabriel C <nix.or.die@...glemail.com>,
Keith Packard <keithp@...thp.com>,
"Pallipadi, Venkatesh" <venkatesh.pallipadi@...el.com>,
Eric Anholt <eric@...olt.net>,
"Siddha, Suresh B" <suresh.b.siddha@...el.com>, airlied@...ux.ie,
"Barnes, Jesse" <jesse.barnes@...el.com>,
"Rafael J. Wysocki" <rjw@...k.pl>
Subject: [PATCH 4 of 8] x86: use PTE_MASK in 32-bit PAE
Use PTE_MASK in 3-level pagetables (ie, 32-bit PAE).
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@...rix.com>
---
include/asm-x86/pgtable-3level.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/include/asm-x86/pgtable-3level.h b/include/asm-x86/pgtable-3level.h
--- a/include/asm-x86/pgtable-3level.h
+++ b/include/asm-x86/pgtable-3level.h
@@ -120,9 +120,9 @@
write_cr3(pgd);
}
-#define pud_page(pud) ((struct page *) __va(pud_val(pud) & PAGE_MASK))
+#define pud_page(pud) ((struct page *) __va(pud_val(pud) & PTE_MASK))
-#define pud_page_vaddr(pud) ((unsigned long) __va(pud_val(pud) & PAGE_MASK))
+#define pud_page_vaddr(pud) ((unsigned long) __va(pud_val(pud) & PTE_MASK))
/* Find an entry in the second-level page table.. */
@@ -160,7 +160,7 @@
static inline unsigned long pte_pfn(pte_t pte)
{
- return (pte_val(pte) & ~_PAGE_NX) >> PAGE_SHIFT;
+ return (pte_val(pte) & PTE_MASK) >> PAGE_SHIFT;
}
/*
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists