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

1992/0108/power/trap.c (diff list | history)

1992/0102/sys/src/9/power/trap.c:364,3701992/0108/sys/src/9/power/trap.c:364,370 (short | long | prev | next)
1990/0227    
/* 
 * Call user, if necessary, with note 
 */ 
void 
1992/0108    
int 
1990/0227    
notify(Ureg *ur) 
{ 
1991/1218    
	int l; 
1992/0102/sys/src/9/power/trap.c:374,3801992/0108/sys/src/9/power/trap.c:374,380
1991/1110    
	if(u->p->procctl) 
		procctl(u->p); 
1991/1230    
	if(u->nnote == 0) 
1990/0227    
		return; 
1992/0108    
		return 0; 
1991/1114    
 
	s = spllo(); 
1991/1216    
	qlock(&u->p->debug); 
1992/0102/sys/src/9/power/trap.c:424,4291992/0108/sys/src/9/power/trap.c:424,430
1990/0227    
	} 
1991/1216    
	qunlock(&u->p->debug); 
1991/1114    
	splx(s); 
1992/0108    
	return 1; 
1990/0227    
} 
 
/* 
1992/0102/sys/src/9/power/trap.c:544,5511992/0108/sys/src/9/power/trap.c:545,552
1991/1114    
	splhi(); 
	if(r1!=FORK && (u->p->procctl || u->nnote)){ 
1992/0102    
		u->svr1 = ret; 
1990/0227    
		notify(ur); 
1992/0102    
		return ur->r1; 
1992/0108    
		if(notify(ur)) 
			return ur->r1; 
1990/0227    
	} 
1991/0705    
 
1990/0227    
	return ret; 


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