This source file includes following definitions.
- sun4c_pmd_align
- sun4c_pgdir_align
- sun4c_virt_to_phys
- sun4c_phys_to_virt
- sun4c_vmalloc_start
- sun4c_pte_page
- sun4c_pmd_page
- sun4c_pgd_page
- sun4c_update_rootmmu_dir
- sun4c_pte_none
- sun4c_pte_present
- sun4c_pte_inuse
- sun4c_pte_clear
- sun4c_pte_reuse
- sun4c_pmd_none
- sun4c_pmd_bad
- sun4c_pmd_present
- sun4c_pmd_inuse
- sun4c_pmd_clear
- sun4c_pmd_reuse
- sun4c_pgd_none
- sun4c_pgd_bad
- sun4c_pgd_present
- sun4c_pgd_inuse
- sun4c_pgd_clear
- sun4c_pgd_reuse
- sun4c_pte_read
- sun4c_pte_write
- sun4c_pte_exec
- sun4c_pte_dirty
- sun4c_pte_young
- sun4c_pte_cow
- sun4c_pte_wrprotect
- sun4c_pte_rdprotect
- sun4c_pte_exprotect
- sun4c_pte_mkclean
- sun4c_pte_mkold
- sun4c_pte_uncow
- sun4c_pte_mkwrite
- sun4c_pte_mkread
- sun4c_pte_mkexec
- sun4c_pte_mkdirty
- sun4c_pte_mkyoung
- sun4c_pte_mkcow
- sun4c_mk_pte
- sun4c_pgd_set
- sun4c_pte_modify
- sun4c_pgd_offset
- sun4c_pmd_offset
- sun4c_pte_offset
- sun4c_pte_free_kernel
- sun4c_pmd_set
- sun4c_pte_alloc_kernel
- sun4c_pmd_free_kernel
- sun4c_pmd_alloc_kernel
- sun4c_pte_free
- sun4c_pte_alloc
- sun4c_pmd_free
- sun4c_pmd_alloc
- sun4c_pgd_free
- sun4c_pgd_alloc
- sun4c_invalidate
- sun4c_switch_to_context
- sun4c_get_context
- sun4c_mapioaddr
- sun4c_paging_init
- sun4c_test_wp
- ld_mmu_sun4c
1
2
3
4
5
6
7
8
9
10
11
12
13
14 #include <linux/kernel.h>
15 #include <linux/sched.h>
16
17 #include <asm/processor.h>
18 #include <asm/page.h>
19 #include <asm/pgtable.h>
20 #include <asm/vac-ops.h>
21 #include <asm/vaddrs.h>
22 #include <asm/asi.h>
23 #include <asm/contregs.h>
24 #include <asm/kdebug.h>
25
26 unsigned int sun4c_pmd_align(unsigned int addr) { return SUN4C_PMD_ALIGN(addr); }
27 unsigned int sun4c_pgdir_align(unsigned int addr) { return SUN4C_PGDIR_ALIGN(addr); }
28
29 extern int num_segmaps, num_contexts;
30
31
32
33
34
35
36
37
38 static inline unsigned int sun4c_virt_to_phys(unsigned int vaddr)
39 {
40 unsigned int paddr = 0;
41 unsigned int voff = (vaddr - PAGE_OFFSET);
42 int i;
43
44 for(i=0; sp_banks[i].num_bytes != 0; i++) {
45 if(voff < paddr + sp_banks[i].num_bytes) {
46
47 return sp_banks[i].base_addr + voff - paddr;
48 } else
49 paddr += sp_banks[i].num_bytes;
50 }
51
52 printk("sun4c_virt_to_phys: Could not make translation for vaddr %08lx\n", (unsigned long) vaddr);
53 SP_ENTER_DEBUGGER;
54 }
55
56 static inline unsigned long
57 sun4c_phys_to_virt(unsigned long paddr)
58 {
59 int i;
60 unsigned long offset = PAGE_OFFSET;
61
62 for (i=0; sp_banks[i].num_bytes != 0; i++)
63 {
64 if (paddr >= sp_banks[i].base_addr &&
65 paddr < (sp_banks[i].base_addr
66 + sp_banks[i].num_bytes)) {
67 return (paddr - sp_banks[i].base_addr) + offset;
68 } else
69 offset += sp_banks[i].num_bytes;
70 }
71 printk("sun4c_phys_to_virt: Could not make translation for paddr %08lx\n", (unsigned long) paddr);
72 SP_ENTER_DEBUGGER;
73 }
74
75 unsigned long
76 sun4c_vmalloc_start(void)
77 {
78 return ((high_memory + SUN4C_VMALLOC_OFFSET) & ~(SUN4C_VMALLOC_OFFSET-1));
79 }
80
81
82
83
84
85 unsigned long
86 sun4c_pte_page(pte_t pte)
87 {
88 unsigned long page;
89
90 page = ((pte_val(pte) & _SUN4C_PFN_MASK) << (PAGE_SHIFT));
91 return sun4c_phys_to_virt(page);
92 }
93
94 unsigned long
95 sun4c_pmd_page(pmd_t pmd)
96 {
97 return ((pmd_val(pmd) & _SUN4C_PGD_PFN_MASK) << (_SUN4C_PGD_PAGE_SHIFT));
98 }
99
100 unsigned long
101 sun4c_pgd_page(pgd_t pgd)
102 {
103 return ((pgd_val(pgd) & _SUN4C_PGD_PFN_MASK) << (_SUN4C_PGD_PAGE_SHIFT));
104 }
105
106
107 void
108 sun4c_update_rootmmu_dir(struct task_struct *tsk, pgd_t *pgdir)
109 {
110 (tsk)->tss.pgd_ptr = (unsigned long) (pgdir);
111
112
113
114 return;
115 }
116
117 int sun4c_pte_none(pte_t pte) { return !pte_val(pte); }
118 int sun4c_pte_present(pte_t pte) { return pte_val(pte) & _SUN4C_PAGE_VALID; }
119 int sun4c_pte_inuse(pte_t *ptep) { return mem_map[MAP_NR(ptep)] != 1; }
120 void sun4c_pte_clear(pte_t *ptep) { pte_val(*ptep) = 0; }
121 void sun4c_pte_reuse(pte_t *ptep)
122 {
123 if(!(mem_map[MAP_NR(ptep)] & MAP_PAGE_RESERVED))
124 mem_map[MAP_NR(ptep)]++;
125 }
126
127 int sun4c_pmd_none(pmd_t pmd) { return !pmd_val(pmd); }
128 int sun4c_pmd_bad(pmd_t pmd)
129 {
130 return ((pmd_val(pmd) & _SUN4C_PGD_MMU_MASK) != _SUN4C_PAGE_TABLE);
131 }
132
133 int sun4c_pmd_present(pmd_t pmd) { return pmd_val(pmd) & _SUN4C_PAGE_VALID; }
134 int sun4c_pmd_inuse(pmd_t *pmdp) { return 0; }
135 void sun4c_pmd_clear(pmd_t *pmdp) { pmd_val(*pmdp) = 0; }
136 void sun4c_pmd_reuse(pmd_t * pmdp) { }
137
138 int sun4c_pgd_none(pgd_t pgd) { return 0; }
139 int sun4c_pgd_bad(pgd_t pgd) { return 0; }
140 int sun4c_pgd_present(pgd_t pgd) { return 1; }
141 int sun4c_pgd_inuse(pgd_t *pgdp) { return mem_map[MAP_NR(pgdp)] != 1; }
142 void sun4c_pgd_clear(pgd_t * pgdp) { }
143 void sun4c_pgd_reuse(pgd_t *pgdp)
144 {
145 if (!(mem_map[MAP_NR(pgdp)] & MAP_PAGE_RESERVED))
146 mem_map[MAP_NR(pgdp)]++;
147 }
148
149
150
151
152
153 int sun4c_pte_read(pte_t pte) { return pte_val(pte) & _SUN4C_PAGE_VALID; }
154 int sun4c_pte_write(pte_t pte) { return pte_val(pte) & _SUN4C_PAGE_WRITE; }
155 int sun4c_pte_exec(pte_t pte) { return pte_val(pte) & _SUN4C_PAGE_VALID; }
156 int sun4c_pte_dirty(pte_t pte) { return pte_val(pte) & _SUN4C_PAGE_DIRTY; }
157 int sun4c_pte_young(pte_t pte) { return pte_val(pte) & _SUN4C_PAGE_REF; }
158 int sun4c_pte_cow(pte_t pte) { return pte_val(pte) & _SUN4C_PAGE_COW; }
159
160 pte_t sun4c_pte_wrprotect(pte_t pte) { pte_val(pte) &= ~_SUN4C_PAGE_WRITE; return pte; }
161 pte_t sun4c_pte_rdprotect(pte_t pte) { pte_val(pte) |= _SUN4C_PAGE_PRIV; return pte; }
162 pte_t sun4c_pte_exprotect(pte_t pte) { pte_val(pte) |= _SUN4C_PAGE_PRIV; return pte; }
163 pte_t sun4c_pte_mkclean(pte_t pte) { pte_val(pte) &= ~_SUN4C_PAGE_DIRTY; return pte; }
164 pte_t sun4c_pte_mkold(pte_t pte) { pte_val(pte) &= ~_SUN4C_PAGE_REF; return pte; }
165 pte_t sun4c_pte_uncow(pte_t pte) { pte_val(pte) &= ~_SUN4C_PAGE_COW; return pte; }
166 pte_t sun4c_pte_mkwrite(pte_t pte) { pte_val(pte) |= _SUN4C_PAGE_WRITE; return pte; }
167 pte_t sun4c_pte_mkread(pte_t pte) { pte_val(pte) &= ~_SUN4C_PAGE_PRIV; return pte; }
168 pte_t sun4c_pte_mkexec(pte_t pte) { pte_val(pte) &= ~_SUN4C_PAGE_PRIV; return pte; }
169 pte_t sun4c_pte_mkdirty(pte_t pte) { pte_val(pte) |= _SUN4C_PAGE_DIRTY; return pte; }
170 pte_t sun4c_pte_mkyoung(pte_t pte) { pte_val(pte) |= _SUN4C_PAGE_REF; return pte; }
171 pte_t sun4c_pte_mkcow(pte_t pte) { pte_val(pte) |= _SUN4C_PAGE_COW; return pte; }
172
173
174
175
176
177 pte_t
178 sun4c_mk_pte(unsigned long page, pgprot_t pgprot)
179 {
180 pte_t pte;
181
182 if(page & (~PAGE_MASK)) panic("sun4c_mk_pte() called with unaligned page");
183 page = sun4c_virt_to_phys(page);
184 pte_val(pte) = ((page>>PAGE_SHIFT)&_SUN4C_PFN_MASK);
185 pte_val(pte) |= (pgprot_val(pgprot) & _SUN4C_MMU_MASK);
186 return pte;
187 }
188
189 void
190 sun4c_pgd_set(pgd_t * pgdp, pte_t * ptep)
191 {
192 pgd_val(*pgdp) = (_SUN4C_PAGE_TABLE & _SUN4C_PGD_MMU_MASK);
193 pgd_val(*pgdp) |= (((((unsigned long) ptep)) >>
194 (_SUN4C_PGD_PAGE_SHIFT)) & _SUN4C_PGD_PFN_MASK);
195 }
196
197 pte_t
198 sun4c_pte_modify(pte_t pte, pgprot_t newprot)
199 {
200 pte_val(pte) = (pte_val(pte) & _SUN4C_PAGE_CHG_MASK);
201 pte_val(pte) |= pgprot_val(newprot);
202 return pte;
203 }
204
205
206 pgd_t *
207 sun4c_pgd_offset(struct task_struct * tsk, unsigned long address)
208 {
209 return ((pgd_t *) (tsk->tss.pgd_ptr)) +
210 (address >> SUN4C_PGDIR_SHIFT);
211 }
212
213
214 pmd_t *
215 sun4c_pmd_offset(pgd_t * dir, unsigned long address)
216 {
217 return (pmd_t *) dir;
218 }
219
220
221 pte_t *
222 sun4c_pte_offset(pmd_t * dir, unsigned long address)
223 {
224 return (pte_t *) sun4c_pmd_page(*dir) + ((address >> PAGE_SHIFT) & (SUN4C_PTRS_PER_PTE - 1));
225 }
226
227
228
229
230
231
232 void
233 sun4c_pte_free_kernel(pte_t *pte)
234 {
235 mem_map[MAP_NR(pte)] = 1;
236 free_page((unsigned long) pte);
237 }
238
239 static inline void
240 sun4c_pmd_set(pmd_t * pmdp, pte_t * ptep)
241 {
242 pmd_val(*pmdp) = (_SUN4C_PAGE_TABLE & _SUN4C_PGD_MMU_MASK);
243 pmd_val(*pmdp) |= ((((unsigned long) ptep) >> (_SUN4C_PGD_PAGE_SHIFT)) & _SUN4C_PGD_PFN_MASK);
244 }
245
246
247 pte_t *
248 sun4c_pte_alloc_kernel(pmd_t *pmd, unsigned long address)
249 {
250 pte_t *page;
251
252
253 address = (address >> PAGE_SHIFT) & (SUN4C_PTRS_PER_PTE - 1);
254 if (sun4c_pmd_none(*pmd)) {
255
256 page = (pte_t *) get_free_page(GFP_KERNEL);
257 if (sun4c_pmd_none(*pmd)) {
258 if (page) {
259 sun4c_pmd_set(pmd, page);
260 mem_map[MAP_NR(page)] = MAP_PAGE_RESERVED;
261 return page + address;
262 }
263 sun4c_pmd_set(pmd, (pte_t *) BAD_PAGETABLE);
264 return NULL;
265 }
266 free_page((unsigned long) page);
267 }
268 if (sun4c_pmd_bad(*pmd)) {
269 printk("Bad pmd in pte_alloc_kernel: %08lx\n", pmd_val(*pmd));
270 sun4c_pmd_set(pmd, (pte_t *) BAD_PAGETABLE);
271 return NULL;
272 }
273
274 return (pte_t *) sun4c_pmd_page(*pmd) + address;
275 }
276
277
278
279
280
281 void
282 sun4c_pmd_free_kernel(pmd_t *pmd)
283 {
284 return;
285 }
286
287 pmd_t *
288 sun4c_pmd_alloc_kernel(pgd_t *pgd, unsigned long address)
289 {
290 return (pmd_t *) pgd;
291 }
292
293 void
294 sun4c_pte_free(pte_t *pte)
295 {
296 free_page((unsigned long) pte);
297 }
298
299 pte_t *
300 sun4c_pte_alloc(pmd_t * pmd, unsigned long address)
301 {
302 pte_t *page;
303
304 address = (address >> PAGE_SHIFT) & (SUN4C_PTRS_PER_PTE - 1);
305 if (sun4c_pmd_none(*pmd)) {
306 page = (pte_t *) get_free_page(GFP_KERNEL);
307 if (sun4c_pmd_none(*pmd)) {
308 if (page) {
309 sun4c_pmd_set(pmd, page);
310 return page + address;
311 }
312 sun4c_pmd_set(pmd, (pte_t *) BAD_PAGETABLE);
313 return NULL;
314 }
315 free_page((unsigned long) page);
316 }
317 if (sun4c_pmd_bad(*pmd)) {
318 printk("Bad pmd in pte_alloc: %08lx\n", pmd_val(*pmd));
319 sun4c_pmd_set(pmd, (pte_t *) BAD_PAGETABLE);
320 halt();
321 return NULL;
322 }
323
324 return (pte_t *) sun4c_pmd_page(*pmd) + address;
325 }
326
327
328
329
330
331 void
332 sun4c_pmd_free(pmd_t * pmd)
333 {
334 return;
335 }
336
337 pmd_t *
338 sun4c_pmd_alloc(pgd_t * pgd, unsigned long address)
339 {
340 return (pmd_t *) pgd;
341 }
342
343
344 void
345 sun4c_pgd_free(pgd_t *pgd)
346 {
347 free_page((unsigned long) pgd);
348 }
349
350
351
352
353
354 pgd_t *
355 sun4c_pgd_alloc(void)
356 {
357 return (pgd_t *) get_free_page(GFP_KERNEL);
358 }
359
360 void
361 sun4c_invalidate(void)
362 {
363 flush_vac_context();
364 }
365
366 void
367 sun4c_switch_to_context(int context)
368 {
369 __asm__ __volatile__("stba %0, [%1] %2" : :
370 "r" (context),
371 "r" (AC_CONTEXT), "i" (ASI_CONTROL));
372
373 return;
374 }
375
376 int
377 sun4c_get_context(void)
378 {
379 register int ctx;
380
381 __asm__ __volatile__("lduba [%1] %2, %0" :
382 "=r" (ctx) :
383 "r" (AC_CONTEXT), "i" (ASI_CONTROL));
384
385 return ctx;
386 }
387
388
389
390
391
392 void
393 sun4c_mapioaddr(unsigned long physaddr, unsigned long virt_addr,
394 int bus_type, int rdonly)
395 {
396 unsigned long page_entry;
397
398 page_entry = ((physaddr >> PAGE_SHIFT) & _SUN4C_PFN_MASK);
399
400 if(!rdonly)
401 page_entry |= (PTE_V | PTE_ACC | PTE_NC | PTE_IO);
402 else
403 page_entry |= (PTE_V | PTE_P | PTE_NC | PTE_IO);
404
405 page_entry &= (~PTE_RESV);
406
407
408
409
410 put_pte(virt_addr, page_entry);
411 return;
412 }
413
414
415 extern unsigned long free_area_init(unsigned long, unsigned long);
416 extern unsigned long eintstack, intstack;
417
418
419
420
421
422
423
424
425 extern unsigned long start;
426
427 static unsigned long mempool;
428
429 unsigned long
430 sun4c_paging_init(unsigned long start_mem, unsigned long end_mem)
431 {
432 unsigned long addr, vaddr, kern_begin, kern_end;
433 unsigned long prom_begin, prom_end;
434 int phys_seg, i, min_prom_segmap;
435 pgd_t *pgdp;
436 pmd_t *pmdp;
437 pte_t *ptep;
438
439 mempool = start_mem;
440
441
442 invalid_segment = (num_segmaps - 1);
443
444 memset(swapper_pg_dir, 0, PAGE_SIZE);
445 memset(pg0, 0, PAGE_SIZE);
446
447 for(vaddr=0; vaddr<(4*1024*1024); vaddr+=SUN4C_REAL_PGDIR_SIZE)
448 put_segmap(vaddr, invalid_segment);
449 for(vaddr=0; vaddr<(256*1024); vaddr+=PAGE_SIZE) put_pte(vaddr, 0);
450
451
452 for(i=0; i<num_segmaps; i++) phys_seg_map[i] = PSEG_AVL;
453 for(i=num_segmaps; i<PSEG_ENTRIES; i++) phys_seg_map[i] = PSEG_RSV;
454
455 kern_begin = KERNBASE;
456 kern_end = ((unsigned long) &end);
457 prom_begin = LINUX_OPPROM_BEGVM;
458 prom_end = LINUX_OPPROM_ENDVM;
459
460
461
462
463
464
465
466
467
468
469
470
471
472 if(sp_banks[0].base_addr != 0)
473 panic("sun4c_paging_init: First physical address in first bank is not zero!\n");
474
475
476
477
478
479
480 for(vaddr = KERNBASE; vaddr < end_mem; vaddr+=PAGE_SIZE) {
481 pgdp = sun4c_pgd_offset(current, vaddr);
482 pmdp = sun4c_pmd_offset(pgdp, vaddr);
483 if(sun4c_pmd_none(*pmdp)) {
484 pgd_set(pgdp, (pte_t *) mempool);
485 mempool += PAGE_SIZE;
486 }
487 ptep = sun4c_pte_offset(pmdp, vaddr);
488 *ptep = sun4c_mk_pte(vaddr, SUN4C_PAGE_KERNEL);
489 }
490
491
492
493
494
495
496 if(kern_begin & (~SUN4C_REAL_PGDIR_MASK)) {
497 panic("paging_init() Kernel not segmap aligned, halting...");
498 }
499
500
501
502
503 for(addr=kern_begin; addr < kern_end; addr += SUN4C_REAL_PGDIR_SIZE) {
504 if(get_segmap(addr) == invalid_segment) {
505 panic("paging_init() AIEEE, Kernel has invalid mapping, halting...");
506 }
507 phys_seg = get_segmap(addr);
508 phys_seg_map[phys_seg] = PSEG_KERNEL;
509
510 for(i=0; i<num_contexts; i++)
511 (*romvec->pv_setctxt)(i, (char *) addr, phys_seg);
512 }
513
514 for(addr=((unsigned long) (&empty_zero_page)) + PAGE_SIZE;
515 addr < ((unsigned long) (&etext)); addr += PAGE_SIZE)
516 put_pte(addr, (get_pte(addr) & (~(PTE_W | PTE_NC))));
517
518
519
520
521
522
523
524
525
526
527 if(prom_begin & (~SUN4C_REAL_PGDIR_MASK)) {
528 panic("paging_init() Boot PROM not segmap aligned, halting...");
529 halt();
530 }
531
532 min_prom_segmap = 254;
533 for(addr=KADB_DEBUGGER_BEGVM; addr < prom_end; addr += SUN4C_REAL_PGDIR_SIZE) {
534 if(get_segmap(addr) == invalid_segment)
535 continue;
536 phys_seg = get_segmap(addr);
537 if(phys_seg < min_prom_segmap) min_prom_segmap = phys_seg;
538 phys_seg_map[phys_seg] = PSEG_RSV;
539
540
541
542 if((addr>=LINUX_OPPROM_BEGVM) && (addr<LINUX_OPPROM_ENDVM))
543 for(vaddr=addr; vaddr < (addr+SUN4C_REAL_PGDIR_SIZE); vaddr+=PAGE_SIZE)
544 put_pte(vaddr, (get_pte(vaddr) | PTE_P));
545
546
547 for(i=0; i<num_contexts; i++)
548 (*romvec->pv_setctxt)(i, (char *) addr, phys_seg);
549 }
550
551
552 put_pte(0x0, 0x0);
553
554
555 phys_seg = (min_prom_segmap - 1);
556 for(addr = (IOBASE_VADDR + SUN4C_REAL_PGDIR_SIZE); addr < (IOBASE_VADDR + IOBASE_LEN);
557 addr += SUN4C_REAL_PGDIR_SIZE) {
558 if(addr & (~SUN4C_REAL_PGDIR_MASK)) {
559 panic("paging_init() IO segment not aligned, halting...");
560 }
561 phys_seg_map[phys_seg] = PSEG_RSV;
562 put_segmap(addr, phys_seg--);
563 }
564 phys_seg_map[IOBASE_SUN4C_SEGMAP] = PSEG_RSV;
565
566 start_mem = PAGE_ALIGN(mempool);
567 start_mem = free_area_init(start_mem, end_mem);
568 start_mem = PAGE_ALIGN(start_mem);
569
570
571 invalidate();
572
573 return start_mem;
574 }
575
576
577 unsigned long
578 sun4c_test_wp(unsigned long start_mem)
579 {
580 unsigned long addr, segmap;
581 unsigned long page_entry;
582
583 wp_works_ok = -1;
584 page_entry = pte_val(sun4c_mk_pte(PAGE_OFFSET, SUN4C_PAGE_READONLY));
585 put_pte((unsigned long) 0x0, page_entry);
586
587
588 __asm__ __volatile__("st %%g0, [0x0]\n\t": : :"memory");
589 put_pte((unsigned long) 0x0, 0x0);
590 if (wp_works_ok < 0)
591 wp_works_ok = 0;
592
593
594 for(addr=PAGE_OFFSET; addr<start_mem; addr+=SUN4C_REAL_PGDIR_SIZE)
595 phys_seg_map[get_segmap(addr)]=PSEG_KERNEL;
596
597
598 for(segmap=invalid_segment; segmap<PSEG_ENTRIES; segmap++)
599 phys_seg_map[segmap]=PSEG_RSV;
600
601 return start_mem;
602 }
603
604
605
606
607 void
608 ld_mmu_sun4c(void)
609 {
610 printk("Loading sun4c MMU routines\n");
611
612
613 pmd_shift = SUN4C_PMD_SHIFT;
614 pmd_size = SUN4C_PMD_SIZE;
615 pmd_mask = SUN4C_PMD_MASK;
616 pgdir_shift = SUN4C_PGDIR_SHIFT;
617 pgdir_size = SUN4C_PGDIR_SIZE;
618 pgdir_mask = SUN4C_PGDIR_MASK;
619
620 ptrs_per_pte = SUN4C_PTRS_PER_PTE;
621 ptrs_per_pmd = SUN4C_PTRS_PER_PMD;
622 ptrs_per_pgd = SUN4C_PTRS_PER_PGD;
623
624 page_none = SUN4C_PAGE_NONE;
625 page_shared = SUN4C_PAGE_SHARED;
626 page_copy = SUN4C_PAGE_COPY;
627 page_readonly = SUN4C_PAGE_READONLY;
628 page_kernel = SUN4C_PAGE_KERNEL;
629 page_invalid = SUN4C_PAGE_INVALID;
630
631
632 invalidate = sun4c_invalidate;
633 switch_to_context = sun4c_switch_to_context;
634 pmd_align = sun4c_pmd_align;
635 pgdir_align = sun4c_pgdir_align;
636 vmalloc_start = sun4c_vmalloc_start;
637
638 pte_page = sun4c_pte_page;
639 pmd_page = sun4c_pmd_page;
640 pgd_page = sun4c_pgd_page;
641
642 sparc_update_rootmmu_dir = sun4c_update_rootmmu_dir;
643
644 pte_none = sun4c_pte_none;
645 pte_present = sun4c_pte_present;
646 pte_inuse = sun4c_pte_inuse;
647 pte_clear = sun4c_pte_clear;
648 pte_reuse = sun4c_pte_reuse;
649
650 pmd_none = sun4c_pmd_none;
651 pmd_bad = sun4c_pmd_bad;
652 pmd_present = sun4c_pmd_present;
653 pmd_inuse = sun4c_pmd_inuse;
654 pmd_clear = sun4c_pmd_clear;
655 pmd_reuse = sun4c_pmd_reuse;
656
657 pgd_none = sun4c_pgd_none;
658 pgd_bad = sun4c_pgd_bad;
659 pgd_present = sun4c_pgd_present;
660 pgd_inuse = sun4c_pgd_inuse;
661 pgd_clear = sun4c_pgd_clear;
662 pgd_reuse = sun4c_pgd_reuse;
663
664 mk_pte = sun4c_mk_pte;
665 pgd_set = sun4c_pgd_set;
666 pte_modify = sun4c_pte_modify;
667 pgd_offset = sun4c_pgd_offset;
668 pmd_offset = sun4c_pmd_offset;
669 pte_offset = sun4c_pte_offset;
670 pte_free_kernel = sun4c_pte_free_kernel;
671 pmd_free_kernel = sun4c_pmd_free_kernel;
672 pte_alloc_kernel = sun4c_pte_alloc_kernel;
673 pmd_alloc_kernel = sun4c_pmd_alloc_kernel;
674 pte_free = sun4c_pte_free;
675 pte_alloc = sun4c_pte_alloc;
676 pmd_free = sun4c_pmd_free;
677 pmd_alloc = sun4c_pmd_alloc;
678 pgd_free = sun4c_pgd_free;
679 pgd_alloc = sun4c_pgd_alloc;
680
681 pte_read = sun4c_pte_read;
682 pte_write = sun4c_pte_write;
683 pte_exec = sun4c_pte_exec;
684 pte_dirty = sun4c_pte_dirty;
685 pte_young = sun4c_pte_young;
686 pte_cow = sun4c_pte_cow;
687 pte_wrprotect = sun4c_pte_wrprotect;
688 pte_rdprotect = sun4c_pte_rdprotect;
689 pte_exprotect = sun4c_pte_exprotect;
690 pte_mkclean = sun4c_pte_mkclean;
691 pte_mkold = sun4c_pte_mkold;
692 pte_uncow = sun4c_pte_uncow;
693 pte_mkwrite = sun4c_pte_mkwrite;
694 pte_mkread = sun4c_pte_mkread;
695 pte_mkexec = sun4c_pte_mkexec;
696 pte_mkdirty = sun4c_pte_mkdirty;
697 pte_mkyoung = sun4c_pte_mkyoung;
698 pte_mkcow = sun4c_pte_mkcow;
699
700 return;
701 }