Index: include/pmap.h =================================================================== RCS file: /home/ncvs/src/sys/sparc64/include/pmap.h,v retrieving revision 1.12 diff -u -r1.12 pmap.h --- include/pmap.h 8 Jan 2002 05:06:39 -0000 1.12 +++ include/pmap.h 25 Feb 2002 22:25:39 -0000 @@ -68,7 +68,6 @@ struct pmap { TAILQ_HEAD(,pv_entry) pm_pvlist; struct tte *pm_tsb; - struct tte *pm_tsb_tte; vm_object_t pm_tsb_obj; u_int pm_active; u_int pm_context; Index: sparc64/genassym.c =================================================================== RCS file: /home/ncvs/src/sys/sparc64/sparc64/genassym.c,v retrieving revision 1.19 diff -u -r1.19 genassym.c --- sparc64/genassym.c 25 Feb 2002 04:56:50 -0000 1.19 +++ sparc64/genassym.c 25 Feb 2002 22:25:39 -0000 @@ -211,7 +211,6 @@ ASSYM(PM_ACTIVE, offsetof(struct pmap, pm_active)); ASSYM(PM_CONTEXT, offsetof(struct pmap, pm_context)); ASSYM(PM_TSB, offsetof(struct pmap, pm_tsb)); -ASSYM(PM_TSB_TTE, offsetof(struct pmap, pm_tsb_tte)); ASSYM(FP_FB0, offsetof(struct fpstate, fp_fb[0])); ASSYM(FP_FB1, offsetof(struct fpstate, fp_fb[1])); Index: sparc64/pmap.c =================================================================== RCS file: /home/ncvs/src/sys/sparc64/sparc64/pmap.c,v retrieving revision 1.29 diff -u -r1.29 pmap.c --- sparc64/pmap.c 25 Feb 2002 04:56:50 -0000 1.29 +++ sparc64/pmap.c 25 Feb 2002 22:25:40 -0000 @@ -1062,7 +1062,6 @@ pm->pm_count = 1; pm->pm_tsb = NULL; pm->pm_tsb_obj = NULL; - pm->pm_tsb_tte = NULL; TAILQ_INIT(&pm->pm_pvlist); bzero(&pm->pm_stats, sizeof(pm->pm_stats)); } @@ -1082,7 +1081,6 @@ if (pm->pm_tsb == NULL) { pm->pm_tsb = (struct tte *)kmem_alloc_pageable(kernel_map, PAGE_SIZE_8K); - pm->pm_tsb_tte = tsb_kvtotte((vm_offset_t)pm->pm_tsb); } /* @@ -1725,7 +1723,6 @@ { vm_offset_t tsb; u_long context; - u_long data; pmap_t pm; /* @@ -1734,24 +1731,16 @@ */ pm = &td->td_proc->p_vmspace->vm_pmap; context = pm->pm_context; - data = pm->pm_tsb_tte->tte_data; tsb = (vm_offset_t)pm->pm_tsb; KASSERT(context != 0, ("pmap_activate: activating nucleus context")); KASSERT(context != -1, ("pmap_activate: steal context")); KASSERT(pm->pm_active == 0, ("pmap_activate: pmap already active?")); - pm->pm_active |= PCPU_GET(cpumask); - wrpr(pstate, 0, PSTATE_MMU); - __asm __volatile("mov %0, %%g7" : : "r" (tsb)); + mov(tsb, TSB_REG); wrpr(pstate, 0, PSTATE_NORMAL); - stxa(TLB_DEMAP_VA(tsb) | TLB_DEMAP_NUCLEUS | TLB_DEMAP_PAGE, - ASI_DMMU_DEMAP, 0); - membar(Sync); - stxa(AA_DMMU_TAR, ASI_DMMU, tsb); - stxa(0, ASI_DTLB_DATA_IN_REG, data | TD_L); - membar(Sync); + pm->pm_active |= 1 << PCPU_GET(cpuid); stxa(AA_DMMU_PCXR, ASI_DMMU, context); membar(Sync); wrpr(pstate, 0, PSTATE_KERNEL); Index: sparc64/swtch.s =================================================================== RCS file: /home/ncvs/src/sys/sparc64/sparc64/swtch.s,v retrieving revision 1.12 diff -u -r1.12 swtch.s --- sparc64/swtch.s 8 Jan 2002 05:10:07 -0000 1.12 +++ sparc64/swtch.s 25 Feb 2002 22:25:40 -0000 @@ -190,27 +190,11 @@ stw %o3, [%o2 + VM_PMAP + PM_ACTIVE] /* - * Load the address of the user tsb and the tte data that maps it into - * kernel space and set the lock bit. + * Switch to mmu globals and install the preloaded tsb pointer. */ ldx [%o2 + VM_PMAP + PM_TSB], %o3 - ldx [%o2 + VM_PMAP + PM_TSB_TTE], %o4 - ldx [%o4 + TTE_DATA], %o4 - or %o4, TD_L, %o4 - - /* - * Switch to mmu globals, install the preloaded tsb pointer and map - * the new tsb. We also disable interrupts so that this is as atomic - * as can be. - */ wrpr %g0, PSTATE_MMU, %pstate mov %o3, TSB_REG - or %o3, TLB_DEMAP_NUCLEUS | TLB_DEMAP_PAGE, %o5 - stxa %g0, [%o5] ASI_DMMU_DEMAP - mov AA_DMMU_TAR, %o5 - stxa %o3, [%o5] ASI_DMMU - stxa %o4, [%g0] ASI_DTLB_DATA_IN_REG - membar #Sync wrpr %g0, PSTATE_KERNEL, %pstate /*