p4-projects@freebsd.org
[Top] [All Lists]

PERFORCE change 100784 for review

Subject: PERFORCE change 100784 for review
From: John Baldwin
Date: Thu, 6 Jul 2006 18:30:06 GMT
http://perforce.freebsd.org/chv.cgi?CH=100784

Change 100784 by jhb@jhb_mutex on 2006/07/06 18:29:47

        Revert this change.  It ends up tripping a panic because in the
        case of an "extra" thread exiting td_ksegrp will be NULL when we
        do PROC_UNLOCK().  If the proc mtx is contested and this thread
        has a regular user priority for it's base priority, then in
        sched_unlend_prio() when we go to fetch the most recent user
        priority from the ksegroup we panic.

Affected files ...

.. //depot/projects/smpng/sys/kern/kern_thread.c#91 edit

Differences ...

==== //depot/projects/smpng/sys/kern/kern_thread.c#91 (text+ko) ====

@@ -579,6 +579,7 @@
                                ksegrp_unlink(kg);
                                ksegrp_stash(kg);
                        }
+                       PROC_UNLOCK(p);
                        td->td_ksegrp   = NULL;
                        PCPU_SET(deadthread, td);
                } else {
@@ -601,9 +602,9 @@
                 * This includes an EX threaded process that is coming
                 * here via exit1(). (exit1 dethreads the proc first).
                 */
+               PROC_UNLOCK(p);
        }
 
-       PROC_UNLOCK(p);
        td->td_state = TDS_INACTIVE;
        CTR1(KTR_PROC, "thread_exit: cpu_throw() thread %p", td);
        cpu_throw(td, choosethread());
_______________________________________________
p4-projects@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/p4-projects
To unsubscribe, send any mail to "p4-projects-unsubscribe@xxxxxxxxxxx"

<Prev in Thread] Current Thread [Next in Thread>
  • PERFORCE change 100784 for review, John Baldwin <=