Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 23 Jul 2002 15:13:09 -0700 (PDT)
From:      Julian Elischer <julian@elischer.org>
To:        Peter Wemm <peter@wemm.org>
Cc:        Yann Berthier <yb@sainte-barbe.org>, current@freebsd.org, alfred@freebsd.org
Subject:   Re: Is it just me or has -current suddenly got massively unstable?
Message-ID:  <Pine.BSF.4.21.0207231458270.7108-100000@InterJet.elischer.org>
In-Reply-To: <20020723070704.7B4CB3925@overcee.wemm.org>

next in thread | previous in thread | raw e-mail | index | archive | help

On Tue, 23 Jul 2002, Peter Wemm wrote:

>  
>         thread_zone = uma_zcreate("THREAD", sizeof (struct thread),
>             thread_ctor, thread_dtor, thread_init, thread_fini,
> -           UMA_ALIGN_CACHE, 0);
> +           UMA_ALIGN_CACHE, UMA_ZONE_NOFREE);
>  }
>  
>  /*
> 
> I haven't paniced yet with that change. :-) For some unknown reason,
> selwakeup() is dereferencing pointers to threads that have long gone and
> the backing store has been freed.  The patch above is a bandaid, not a
> solution.  It basically prevents threads ever being freed back to the
> general pool, even though everything here supposedly does not need that.
> (unlike struct proc and socket, for example).


Peter.. this comment in selrecord scared the heck out of me..
---
     /*
1151          * If the thread is NULL then take ownership of selinfo
1152          * however if the thread is not NULL and the thread points to
1153          * someone else, then we have a collision, otherwise leave it
alone
1154          * as we've owned it in a previous selrecord on this selinfo.
1155          */

-------

it suggests that select still doesn't clean up after itself.

looking in select() however I see:
 836         if (timo > 0)
 837                 error = cv_timedwait_sig(&selwait, &sellock, timo);
 838         else
 839                 error = cv_wait_sig(&selwait, &sellock);
 840         
 841         if (error == 0)
 842                 goto retry;
 843 
 844 done:
 845         clear_selinfo_list(td);

This suggests that there is no way to exit this function without
clearing the thread pointers but your trace suggests otherwise..


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.21.0207231458270.7108-100000>