aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-x86
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-x86')
-rw-r--r--include/asm-x86/pgalloc_32.h8
-rw-r--r--include/asm-x86/pgalloc_64.h10
2 files changed, 9 insertions, 9 deletions
diff --git a/include/asm-x86/pgalloc_32.h b/include/asm-x86/pgalloc_32.h
index 6c21ef951dab..bab12718a913 100644
--- a/include/asm-x86/pgalloc_32.h
+++ b/include/asm-x86/pgalloc_32.h
@@ -36,17 +36,17 @@ static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd, struct page *p
36 * Allocate and free page tables. 36 * Allocate and free page tables.
37 */ 37 */
38extern pgd_t *pgd_alloc(struct mm_struct *); 38extern pgd_t *pgd_alloc(struct mm_struct *);
39extern void pgd_free(pgd_t *pgd); 39extern void pgd_free(struct mm_struct *mm, pgd_t *pgd);
40 40
41extern pte_t *pte_alloc_one_kernel(struct mm_struct *, unsigned long); 41extern pte_t *pte_alloc_one_kernel(struct mm_struct *, unsigned long);
42extern struct page *pte_alloc_one(struct mm_struct *, unsigned long); 42extern struct page *pte_alloc_one(struct mm_struct *, unsigned long);
43 43
44static inline void pte_free_kernel(pte_t *pte) 44static inline void pte_free_kernel(struct mm_struct *mm, pte_t *pte)
45{ 45{
46 free_page((unsigned long)pte); 46 free_page((unsigned long)pte);
47} 47}
48 48
49static inline void pte_free(struct page *pte) 49static inline void pte_free(struct mm_struct *mm, struct page *pte)
50{ 50{
51 __free_page(pte); 51 __free_page(pte);
52} 52}
@@ -63,7 +63,7 @@ static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long addr)
63 return (pmd_t *)get_zeroed_page(GFP_KERNEL|__GFP_REPEAT); 63 return (pmd_t *)get_zeroed_page(GFP_KERNEL|__GFP_REPEAT);
64} 64}
65 65
66static inline void pmd_free(pmd_t *pmd) 66static inline void pmd_free(struct mm_struct *mm, pmd_t *pmd)
67{ 67{
68 BUG_ON((unsigned long)pmd & (PAGE_SIZE-1)); 68 BUG_ON((unsigned long)pmd & (PAGE_SIZE-1));
69 free_page((unsigned long)pmd); 69 free_page((unsigned long)pmd);
diff --git a/include/asm-x86/pgalloc_64.h b/include/asm-x86/pgalloc_64.h
index 8bb564687860..315314ce4bfb 100644
--- a/include/asm-x86/pgalloc_64.h
+++ b/include/asm-x86/pgalloc_64.h
@@ -17,7 +17,7 @@ static inline void pmd_populate(struct mm_struct *mm, pmd_t *pmd, struct page *p
17 set_pmd(pmd, __pmd(_PAGE_TABLE | (page_to_pfn(pte) << PAGE_SHIFT))); 17 set_pmd(pmd, __pmd(_PAGE_TABLE | (page_to_pfn(pte) << PAGE_SHIFT)));
18} 18}
19 19
20static inline void pmd_free(pmd_t *pmd) 20static inline void pmd_free(struct mm_struct *mm, pmd_t *pmd)
21{ 21{
22 BUG_ON((unsigned long)pmd & (PAGE_SIZE-1)); 22 BUG_ON((unsigned long)pmd & (PAGE_SIZE-1));
23 free_page((unsigned long)pmd); 23 free_page((unsigned long)pmd);
@@ -33,7 +33,7 @@ static inline pud_t *pud_alloc_one(struct mm_struct *mm, unsigned long addr)
33 return (pud_t *)get_zeroed_page(GFP_KERNEL|__GFP_REPEAT); 33 return (pud_t *)get_zeroed_page(GFP_KERNEL|__GFP_REPEAT);
34} 34}
35 35
36static inline void pud_free (pud_t *pud) 36static inline void pud_free(struct mm_struct *mm, pud_t *pud)
37{ 37{
38 BUG_ON((unsigned long)pud & (PAGE_SIZE-1)); 38 BUG_ON((unsigned long)pud & (PAGE_SIZE-1));
39 free_page((unsigned long)pud); 39 free_page((unsigned long)pud);
@@ -77,7 +77,7 @@ static inline pgd_t *pgd_alloc(struct mm_struct *mm)
77 return pgd; 77 return pgd;
78} 78}
79 79
80static inline void pgd_free(pgd_t *pgd) 80static inline void pgd_free(struct mm_struct *mm, pgd_t *pgd)
81{ 81{
82 BUG_ON((unsigned long)pgd & (PAGE_SIZE-1)); 82 BUG_ON((unsigned long)pgd & (PAGE_SIZE-1));
83 pgd_list_del(pgd); 83 pgd_list_del(pgd);
@@ -100,13 +100,13 @@ static inline struct page *pte_alloc_one(struct mm_struct *mm, unsigned long add
100/* Should really implement gc for free page table pages. This could be 100/* Should really implement gc for free page table pages. This could be
101 done with a reference count in struct page. */ 101 done with a reference count in struct page. */
102 102
103static inline void pte_free_kernel(pte_t *pte) 103static inline void pte_free_kernel(struct mm_struct *mm, pte_t *pte)
104{ 104{
105 BUG_ON((unsigned long)pte & (PAGE_SIZE-1)); 105 BUG_ON((unsigned long)pte & (PAGE_SIZE-1));
106 free_page((unsigned long)pte); 106 free_page((unsigned long)pte);
107} 107}
108 108
109static inline void pte_free(struct page *pte) 109static inline void pte_free(struct mm_struct *mm, struct page *pte)
110{ 110{
111 __free_page(pte); 111 __free_page(pte);
112} 112}