Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 12 May 2003 07:50:18 -0700 (PDT)
From:      Jilles Tjoelker <jilles@stack.nl>
To:        freebsd-bugs@FreeBSD.org
Subject:   Re: kern/51964: panic: race condition with realitexpire() called for	zombie
Message-ID:  <200305121450.h4CEoI6S015236@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/51964; it has been noted by GNATS.

From: Jilles Tjoelker <jilles@stack.nl>
To: Tor.Egge@cvsup.no.freebsd.org
Cc: FreeBSD-gnats-submit@freebsd.org, svdb@stack.nl, unix@stack.nl
Subject: Re: kern/51964: panic: race condition with realitexpire() called for	zombie
Date: Mon, 12 May 2003 16:43:25 +0200

 On Sat, May 10, 2003 at 05:07:56PM +0000, Tor.Egge@cvsup.no.freebsd.org wrote:
 > The enclosed patch should fix the problem if your source is newer than
 > "2003/05/01 14:16:38 PDT" (the struct proc mutex must be persistent).
 
 > If callout_pending() is true then callout_reset() has been called.
 > If callout_active() is false then callout_stop() has been called.
 
 I have upgraded the system and applied the patch. Brief testing
 indicates I can run the itimer program for more than 15 minutes without
 a crash.
 
 > ---------------------------
 > Index: sys/kern/kern_time.c
 > ===================================================================
 > RCS file: /home/ncvs/src/sys/kern/kern_time.c,v
 > retrieving revision 1.101
 > diff -u -r1.101 kern_time.c
 > --- sys/kern/kern_time.c	26 Feb 2003 17:16:38 -0000	1.101
 > +++ sys/kern/kern_time.c	10 May 2003 16:44:41 -0000
 > @@ -527,6 +527,12 @@
 >  
 >  	p = (struct proc *)arg;
 >  	PROC_LOCK(p);
 > +	/* Check for callout being active */
 > +	if (callout_pending(&p->p_itcallout) ||
 > +	    !callout_active(&p->p_itcallout)) {
 > +		PROC_UNLOCK(p);
 > +		return;
 > +	}
 >  	psignal(p, SIGALRM);
 >  	if (!timevalisset(&p->p_realtimer.it_interval)) {
 >  		timevalclear(&p->p_realtimer.it_value);
 > ---------------------------



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200305121450.h4CEoI6S015236>