aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/asm-um/pgalloc.h12
-rw-r--r--include/asm-um/pgtable-3level.h9
2 files changed, 10 insertions, 11 deletions
diff --git a/include/asm-um/pgalloc.h b/include/asm-um/pgalloc.h
index 8fcb2fc0a892..ea49411236dc 100644
--- a/include/asm-um/pgalloc.h
+++ b/include/asm-um/pgalloc.h
@@ -42,11 +42,13 @@ static inline void pte_free(struct page *pte)
42#define __pte_free_tlb(tlb,pte) tlb_remove_page((tlb),(pte)) 42#define __pte_free_tlb(tlb,pte) tlb_remove_page((tlb),(pte))
43 43
44#ifdef CONFIG_3_LEVEL_PGTABLES 44#ifdef CONFIG_3_LEVEL_PGTABLES
45/* 45
46 * In the 3-level case we free the pmds as part of the pgd. 46extern __inline__ void pmd_free(pmd_t *pmd)
47 */ 47{
48#define pmd_free(x) do { } while (0) 48 free_page((unsigned long)pmd);
49#define __pmd_free_tlb(tlb,x) do { } while (0) 49}
50
51#define __pmd_free_tlb(tlb,x) tlb_remove_page((tlb),virt_to_page(x))
50#endif 52#endif
51 53
52#define check_pgt_cache() do { } while (0) 54#define check_pgt_cache() do { } while (0)
diff --git a/include/asm-um/pgtable-3level.h b/include/asm-um/pgtable-3level.h
index 32cd6236f245..786c25727289 100644
--- a/include/asm-um/pgtable-3level.h
+++ b/include/asm-um/pgtable-3level.h
@@ -69,14 +69,11 @@ static inline pmd_t *pmd_alloc_one(struct mm_struct *mm, unsigned long address)
69 return pmd; 69 return pmd;
70} 70}
71 71
72static inline void pmd_free(pmd_t *pmd){ 72extern inline void pud_clear (pud_t *pud)
73 free_page((unsigned long) pmd); 73{
74 set_pud(pud, __pud(0));
74} 75}
75 76
76#define __pmd_free_tlb(tlb,x) do { } while (0)
77
78static inline void pud_clear (pud_t * pud) { }
79
80#define pud_page(pud) \ 77#define pud_page(pud) \
81 ((struct page *) __va(pud_val(pud) & PAGE_MASK)) 78 ((struct page *) __va(pud_val(pud) & PAGE_MASK))
82 79