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

1990/0814/port/fault.c (diff list | history)

1990/0802/sys/src/9/port/fault.c:43,511990/0814/sys/src/9/port/fault.c:43,49 (short | long | prev | next)
1990/0227    
		/* grow stack */ 
		o = s->o; 
		n = o->npte; 
1990/0802    
		lock(o); 
		if(waserror()){ 
			unlock(o); 
			pprint("can't allocate stack page\n"); 
			goto cant; 
		} 
1990/0802/sys/src/9/port/fault.c:52,571990/0814/sys/src/9/port/fault.c:50,56
1990/0227    
		growpte(o, (s->maxva-addr)>>PGSHIFT); 
1990/0802    
		poperror(); 
1990/0227    
		/* stacks grown down, sigh */ 
1990/0814    
		lock(o); 
1990/0227    
		memcpy(o->pte+(o->npte-n), o->pte, n*sizeof(PTE)); 
		memset(o->pte, 0, (o->npte-n)*sizeof(PTE)); 
		unlock(o); 


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