plan 9 kernel history: overview | file list | diff list

1990/0925/gnot/mmu.c (diff list | history)

1990/0921/sys/src/9/gnot/mmu.c:40,451990/0925/sys/src/9/gnot/mmu.c:40,49 (short | long | prev | next)
1990/03091    
	flushmmu(); 
	u = (User*)USERADDR; 
1990/0921    
 
1990/0925    
	/* 
 	 *  preload the MMU with the last (up to) NMMU user entries 
	 *  previously faulted into it for this process. 
	 */ 
1990/0921    
	if(u->mc.next >= NMMU){ 
		u->mc.next &= NMMU - 1; 
		for(i = u->mc.next; i < NMMU; i++) 
1990/0921/sys/src/9/gnot/mmu.c:46,521990/0925/sys/src/9/gnot/mmu.c:50,56
1990/0921    
			putxmmu(u->mc.mmu[i].va, u->mc.mmu[i].pa, u->mc.mmu[i].pid); 
	} 
	for(i = 0; i < u->mc.next; i++) 
		putxmmu(u->mc.mmu[i].va, u->mc.mmu[i].pa, u->mc.mmu[i].pid);/**/ 
1990/0925    
		putxmmu(u->mc.mmu[i].va, u->mc.mmu[i].pa, u->mc.mmu[i].pid); 
1990/03091    
} 
 
void 
1990/0921/sys/src/9/gnot/mmu.c:70,761990/0925/sys/src/9/gnot/mmu.c:74,80
1990/0921    
		mp->va = tlbvirt; 
		mp->pid = u->p->pid; 
		u->mc.next++; 
	}/**/ 
1990/0925    
	} 
1990/03091    
	tlbphys |= VTAG(tlbvirt)<<24; 
	UMAP[(tlbvirt&0x003FE000L)>>2] = tlbphys; 
} 
1990/0921/sys/src/9/gnot/mmu.c:84,1021990/0925/sys/src/9/gnot/mmu.c:88,98
1990/0921    
} 
 
void 
flushmmucache(void) 
1990/0925    
clearmmucache(void) 
1990/0921    
{ 
	if(u == 0) 
		panic("flushmmucache"); 
	u->mc.next = 0; 
} 
                 
void 
clearmmucache(void) 
{ 
	if(u == 0) 
		panic("clearmmucache"); 
	memset(&u->mc, 0, sizeof u->mc); 
1990/06021    
} 
 
void 


source code copyright © 1990-2005 Lucent Technologies; see license
Plan 9 distribution
comments to russ cox (rsc@swtch.com)