aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-x86/pgtable-3level.h
diff options
context:
space:
mode:
authorJeremy Fitzhardinge <jeremy@goop.org>2008-07-22 01:59:42 -0400
committerIngo Molnar <mingo@elte.hu>2008-07-22 04:43:44 -0400
commit59438c9fc4f7a92c808c9049bc6b396f98bf954c (patch)
treeb86d6072612075bc256038a3430d86ab04778d51 /include/asm-x86/pgtable-3level.h
parentc2e3277f875b83e5adc34e96989d6d87ec5f80f7 (diff)
x86: rename PTE_MASK to PTE_PFN_MASK
Rusty, in his peevish way, complained that macros defining constants should have a name which somewhat accurately reflects the actual purpose of the constant. Aside from the fact that PTE_MASK gives no clue as to what's actually being masked, and is misleadingly similar to the functionally entirely different PMD_MASK, PUD_MASK and PGD_MASK, I don't really see what the problem is. But if this patch silences the incessent noise, then it will have achieved its goal (TODO: write test-case). Signed-off-by: Jeremy Fitzhardinge <jeremy@goop.org> Cc: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/asm-x86/pgtable-3level.h')
-rw-r--r--include/asm-x86/pgtable-3level.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/asm-x86/pgtable-3level.h b/include/asm-x86/pgtable-3level.h
index c93dbb6c2624..105057f34032 100644
--- a/include/asm-x86/pgtable-3level.h
+++ b/include/asm-x86/pgtable-3level.h
@@ -25,7 +25,7 @@ static inline int pud_none(pud_t pud)
25 25
26static inline int pud_bad(pud_t pud) 26static inline int pud_bad(pud_t pud)
27{ 27{
28 return (pud_val(pud) & ~(PTE_MASK | _KERNPG_TABLE | _PAGE_USER)) != 0; 28 return (pud_val(pud) & ~(PTE_PFN_MASK | _KERNPG_TABLE | _PAGE_USER)) != 0;
29} 29}
30 30
31static inline int pud_present(pud_t pud) 31static inline int pud_present(pud_t pud)
@@ -120,9 +120,9 @@ static inline void pud_clear(pud_t *pudp)
120 write_cr3(pgd); 120 write_cr3(pgd);
121} 121}
122 122
123#define pud_page(pud) ((struct page *) __va(pud_val(pud) & PTE_MASK)) 123#define pud_page(pud) ((struct page *) __va(pud_val(pud) & PTE_PFN_MASK))
124 124
125#define pud_page_vaddr(pud) ((unsigned long) __va(pud_val(pud) & PTE_MASK)) 125#define pud_page_vaddr(pud) ((unsigned long) __va(pud_val(pud) & PTE_PFN_MASK))
126 126
127 127
128/* Find an entry in the second-level page table.. */ 128/* Find an entry in the second-level page table.. */
@@ -160,7 +160,7 @@ static inline int pte_none(pte_t pte)
160 160
161static inline unsigned long pte_pfn(pte_t pte) 161static inline unsigned long pte_pfn(pte_t pte)
162{ 162{
163 return (pte_val(pte) & PTE_MASK) >> PAGE_SHIFT; 163 return (pte_val(pte) & PTE_PFN_MASK) >> PAGE_SHIFT;
164} 164}
165 165
166/* 166/*