aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-m68k/motorola_pgtable.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-m68k/motorola_pgtable.h')
-rw-r--r--include/asm-m68k/motorola_pgtable.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/include/asm-m68k/motorola_pgtable.h b/include/asm-m68k/motorola_pgtable.h
index 61e4406ed96..b5b78c01eb6 100644
--- a/include/asm-m68k/motorola_pgtable.h
+++ b/include/asm-m68k/motorola_pgtable.h
@@ -130,7 +130,7 @@ static inline void pgd_set(pgd_t *pgdp, pmd_t *pmdp)
130#define pte_present(pte) (pte_val(pte) & (_PAGE_PRESENT | _PAGE_PROTNONE)) 130#define pte_present(pte) (pte_val(pte) & (_PAGE_PRESENT | _PAGE_PROTNONE))
131#define pte_clear(mm,addr,ptep) ({ pte_val(*(ptep)) = 0; }) 131#define pte_clear(mm,addr,ptep) ({ pte_val(*(ptep)) = 0; })
132 132
133#define pte_page(pte) (mem_map + ((unsigned long)(__va(pte_val(pte)) - PAGE_OFFSET) >> PAGE_SHIFT)) 133#define pte_page(pte) virt_to_page(__va(pte_val(pte)))
134#define pte_pfn(pte) (pte_val(pte) >> PAGE_SHIFT) 134#define pte_pfn(pte) (pte_val(pte) >> PAGE_SHIFT)
135#define pfn_pte(pfn, prot) __pte(((pfn) << PAGE_SHIFT) | pgprot_val(prot)) 135#define pfn_pte(pfn, prot) __pte(((pfn) << PAGE_SHIFT) | pgprot_val(prot))
136 136
@@ -143,7 +143,7 @@ static inline void pgd_set(pgd_t *pgdp, pmd_t *pmdp)
143 while (--__i >= 0) \ 143 while (--__i >= 0) \
144 *__ptr++ = 0; \ 144 *__ptr++ = 0; \
145}) 145})
146#define pmd_page(pmd) (mem_map + ((unsigned long)(__va(pmd_val(pmd)) - PAGE_OFFSET) >> PAGE_SHIFT)) 146#define pmd_page(pmd) virt_to_page(__va(pmd_val(pmd)))
147 147
148 148
149#define pgd_none(pgd) (!pgd_val(pgd)) 149#define pgd_none(pgd) (!pgd_val(pgd))
@@ -223,10 +223,10 @@ static inline pte_t *pte_offset_kernel(pmd_t *pmdp, unsigned long address)
223 return (pte_t *)__pmd_page(*pmdp) + ((address >> PAGE_SHIFT) & (PTRS_PER_PTE - 1)); 223 return (pte_t *)__pmd_page(*pmdp) + ((address >> PAGE_SHIFT) & (PTRS_PER_PTE - 1));
224} 224}
225 225
226#define pte_offset_map(pmdp,address) ((pte_t *)kmap(pmd_page(*pmdp)) + ((address >> PAGE_SHIFT) & (PTRS_PER_PTE - 1))) 226#define pte_offset_map(pmdp,address) ((pte_t *)__pmd_page(*pmdp) + (((address) >> PAGE_SHIFT) & (PTRS_PER_PTE - 1)))
227#define pte_offset_map_nested(pmdp, address) pte_offset_map(pmdp, address) 227#define pte_offset_map_nested(pmdp, address) pte_offset_map(pmdp, address)
228#define pte_unmap(pte) kunmap(pte) 228#define pte_unmap(pte) ((void)0)
229#define pte_unmap_nested(pte) kunmap(pte) 229#define pte_unmap_nested(pte) ((void)0)
230 230
231/* 231/*
232 * Allocate and free page tables. The xxx_kernel() versions are 232 * Allocate and free page tables. The xxx_kernel() versions are