diff options
author | Jeremy Fitzhardinge <jeremy@goop.org> | 2009-02-05 20:30:56 +0100 |
---|---|---|
committer | Jeremy Fitzhardinge <jeremy@goop.org> | 2009-02-06 21:31:48 +0100 |
commit | 777cba16aac5a1096db0b936912eb7fd06fb0cc5 (patch) | |
tree | 5931ae7716da5ec552ccf1decbc2b323264ef139 /arch/x86/include/asm/pgtable.h | |
parent | x86: unify pud_page (diff) | |
download | linux-777cba16aac5a1096db0b936912eb7fd06fb0cc5.tar.xz linux-777cba16aac5a1096db0b936912eb7fd06fb0cc5.zip |
x86: unify pgd_page
Impact: cleanup
Unify and demacro pgd_page.
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Diffstat (limited to 'arch/x86/include/asm/pgtable.h')
-rw-r--r-- | arch/x86/include/asm/pgtable.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtable.h index a871ae55a5c5..c1a36dd1e598 100644 --- a/arch/x86/include/asm/pgtable.h +++ b/arch/x86/include/asm/pgtable.h @@ -495,6 +495,11 @@ static inline unsigned long pgd_page_vaddr(pgd_t pgd) { return (unsigned long)__va((unsigned long)pgd_val(pgd) & PTE_PFN_MASK); } + +static inline struct page *pgd_page(pgd_t pgd) +{ + return pfn_to_page(pgd_val(pgd) >> PAGE_SHIFT); +} #endif /* PAGETABLE_LEVELS > 3 */ #endif /* __ASSEMBLY__ */ |