[long] panic on a recent current

John Baldwin jhb at FreeBSD.org
Wed May 19 05:40:48 PDT 2004


On Tuesday 18 May 2004 03:05 pm, Thierry Herbelot wrote:
> on a recent -current, running KDE and simultaneously building the world.
>
> As the machine is quite slow, I post this message "raw" (further in the
> message : a gdb session and the full dmesg)
> I'm trying to reproduce the panic.
> The kernel config file is the straight "GENERIC".

Here is a possible fix:

Index: kern_sig.c
===================================================================
RCS file: /usr/cvs/src/sys/kern/kern_sig.c,v
retrieving revision 1.276
diff -u -r1.276 kern_sig.c
--- kern_sig.c  12 Apr 2004 15:56:05 -0000      1.276
+++ kern_sig.c  19 May 2004 12:10:47 -0000
@@ -1953,7 +1953,7 @@
                        td->td_priority = PUSER;
                }
        }
-       if (TD_IS_SLEEPING(td)) {
+       if (TD_ON_SLEEPQ(td)) {
                /*
                 * If thread is sleeping uninterruptibly
                 * we can't interrupt the sleep... the signal will

All the other callers check TD_ON_SLEEPQ() rather than TD_IS_SLEEPING() before 
calling sleepq_abort().  A thread can be marked sleeping w/o being on a sleep 
queue during the timed sleepq race workaround.  Also, for what it's worth, 
4.x's psignal() doesn't do an unsleep() in the case that this code does.

-- 
John Baldwin <jhb at FreeBSD.org>  <><  http://www.FreeBSD.org/~jhb/
"Power Users Use the Power to Serve"  =  http://www.FreeBSD.org


More information about the freebsd-current mailing list