Go to the documentation of this file. 1 #ifndef _M68K_PGTABLE_H
2 #define _M68K_PGTABLE_H
9 #include <asm/processor.h>
10 #include <linux/sched.h>
18 #include <asm/virtconvert.h>
24 #define set_pte(pteptr, pteval) \
26 *(pteptr) = (pteval); \
28 #define set_pte_at(mm,addr,ptep,pteval) set_pte(ptep,pteval)
37 #define PMD_SIZE (1UL << PMD_SHIFT)
38 #define PMD_MASK (~(PMD_SIZE-1))
42 #define PGDIR_SHIFT 17
43 #elif defined(CONFIG_COLDFIRE)
44 #define PGDIR_SHIFT 22
46 #define PGDIR_SHIFT 25
48 #define PGDIR_SIZE (1UL << PGDIR_SHIFT)
49 #define PGDIR_MASK (~(PGDIR_SIZE-1))
56 #define PTRS_PER_PTE 16
57 #define PTRS_PER_PMD 1
58 #define PTRS_PER_PGD 2048
59 #elif defined(CONFIG_COLDFIRE)
60 #define PTRS_PER_PTE 512
61 #define PTRS_PER_PMD 1
62 #define PTRS_PER_PGD 1024
64 #define PTRS_PER_PTE 1024
65 #define PTRS_PER_PMD 8
66 #define PTRS_PER_PGD 128
68 #define USER_PTRS_PER_PGD (TASK_SIZE/PGDIR_SIZE)
69 #define FIRST_USER_ADDRESS 0
73 #define KMAP_START 0x0DC00000
74 #define KMAP_END 0x0E000000
75 #elif defined(CONFIG_COLDFIRE)
76 #define KMAP_START 0xe0000000
77 #define KMAP_END 0xf0000000
79 #define KMAP_START 0xd0000000
80 #define KMAP_END 0xf0000000
85 #define VMALLOC_START 0x0f800000
86 #define VMALLOC_END m68k_vmalloc_end
87 #elif defined(CONFIG_COLDFIRE)
88 #define VMALLOC_START 0xd0000000
89 #define VMALLOC_END 0xe0000000
98 #define VMALLOC_OFFSET (8*1024*1024)
99 #define VMALLOC_START (((unsigned long) high_memory + VMALLOC_OFFSET) & ~(VMALLOC_OFFSET-1))
100 #define VMALLOC_END KMAP_START
110 #define ZERO_PAGE(vaddr) (virt_to_page(empty_zero_page))
113 #define BITS_PER_PTR (8*sizeof(unsigned long))
116 #define PTR_MASK (~(sizeof(void*)-1))
120 #define SIZEOF_PTR_LOG2 2
136 #define kern_addr_valid(addr) (1)
138 #define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \
139 remap_pfn_range(vma, vaddr, pfn, size, prot)
145 #elif defined(CONFIG_COLDFIRE)
155 #ifdef CONFIG_COLDFIRE
156 # define pgprot_noncached(prot) (__pgprot(pgprot_val(prot) | CF_PAGE_NOCACHE))
158 #ifdef SUN3_PAGE_NOCACHE
159 # define __SUN3_PAGE_NOCACHE SUN3_PAGE_NOCACHE
161 # define __SUN3_PAGE_NOCACHE 0
163 #define pgprot_noncached(prot) \
165 ? (__pgprot(pgprot_val(prot) | __SUN3_PAGE_NOCACHE)) \
166 : ((MMU_IS_851 || MMU_IS_030) \
167 ? (__pgprot(pgprot_val(prot) | _PAGE_NOCACHE030)) \
168 : (MMU_IS_040 || MMU_IS_060) \
169 ? (__pgprot((pgprot_val(prot) & _CACHEMASK040) | _PAGE_NOCACHE_S)) \
179 #define pgtable_cache_init() do { } while (0)
181 #define check_pgt_cache() do { } while (0)