diff options
Diffstat (limited to 'include/asm-parisc/pgalloc.h')
-rw-r--r-- | include/asm-parisc/pgalloc.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/include/asm-parisc/pgalloc.h b/include/asm-parisc/pgalloc.h index aab66f1bea14..3996dfc30a3f 100644 --- a/include/asm-parisc/pgalloc.h +++ b/include/asm-parisc/pgalloc.h | |||
@@ -115,11 +115,14 @@ pmd_populate_kernel(struct mm_struct *mm, pmd_t *pmd, pte_t *pte) | |||
115 | 115 | ||
116 | #define pmd_populate(mm, pmd, pte_page) \ | 116 | #define pmd_populate(mm, pmd, pte_page) \ |
117 | pmd_populate_kernel(mm, pmd, page_address(pte_page)) | 117 | pmd_populate_kernel(mm, pmd, page_address(pte_page)) |
118 | #define pmd_pgtable(pmd) pmd_page(pmd) | ||
118 | 119 | ||
119 | static inline struct page * | 120 | static inline pgtable_t |
120 | pte_alloc_one(struct mm_struct *mm, unsigned long address) | 121 | pte_alloc_one(struct mm_struct *mm, unsigned long address) |
121 | { | 122 | { |
122 | struct page *page = alloc_page(GFP_KERNEL|__GFP_REPEAT|__GFP_ZERO); | 123 | struct page *page = alloc_page(GFP_KERNEL|__GFP_REPEAT|__GFP_ZERO); |
124 | if (page) | ||
125 | pgtable_page_ctor(page); | ||
123 | return page; | 126 | return page; |
124 | } | 127 | } |
125 | 128 | ||
@@ -135,7 +138,11 @@ static inline void pte_free_kernel(struct mm_struct *mm, pte_t *pte) | |||
135 | free_page((unsigned long)pte); | 138 | free_page((unsigned long)pte); |
136 | } | 139 | } |
137 | 140 | ||
138 | #define pte_free(mm, page) pte_free_kernel(page_address(page)) | 141 | static inline void pte_free_kernel(struct mm_struct *mm, struct page *pte) |
142 | { | ||
143 | pgtable_page_dtor(pte); | ||
144 | pte_free_kernel(page_address((pte)); | ||
145 | } | ||
139 | 146 | ||
140 | #define check_pgt_cache() do { } while (0) | 147 | #define check_pgt_cache() do { } while (0) |
141 | 148 | ||