diff options
Diffstat (limited to 'include/asm-x86/pgtable.h')
-rw-r--r-- | include/asm-x86/pgtable.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/asm-x86/pgtable.h b/include/asm-x86/pgtable.h index 04caa2f544df..efc329b8a717 100644 --- a/include/asm-x86/pgtable.h +++ b/include/asm-x86/pgtable.h | |||
@@ -186,6 +186,13 @@ static inline int pte_special(pte_t pte) | |||
186 | return pte_val(pte) & _PAGE_SPECIAL; | 186 | return pte_val(pte) & _PAGE_SPECIAL; |
187 | } | 187 | } |
188 | 188 | ||
189 | static inline unsigned long pte_pfn(pte_t pte) | ||
190 | { | ||
191 | return (pte_val(pte) & PTE_PFN_MASK) >> PAGE_SHIFT; | ||
192 | } | ||
193 | |||
194 | #define pte_page(pte) pfn_to_page(pte_pfn(pte)) | ||
195 | |||
189 | static inline int pmd_large(pmd_t pte) | 196 | static inline int pmd_large(pmd_t pte) |
190 | { | 197 | { |
191 | return (pmd_val(pte) & (_PAGE_PSE | _PAGE_PRESENT)) == | 198 | return (pmd_val(pte) & (_PAGE_PSE | _PAGE_PRESENT)) == |