From owner-freebsd-stable Thu Apr 25 23:13:36 2002 Delivered-To: freebsd-stable@freebsd.org Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by hub.freebsd.org (Postfix) with ESMTP id 61E2B37B400 for ; Thu, 25 Apr 2002 23:13:32 -0700 (PDT) Received: (from dillon@localhost) by apollo.backplane.com (8.11.6/8.9.1) id g3Q6CFq08959; Thu, 25 Apr 2002 23:12:15 -0700 (PDT) (envelope-from dillon) Date: Thu, 25 Apr 2002 23:12:15 -0700 (PDT) From: Matthew Dillon Message-Id: <200204260612.g3Q6CFq08959@apollo.backplane.com> To: JJ Behrens Cc: freebsd-stable@FreeBSD.ORG, Erik Trulsson , @ns.sol.net, Joe Greco Subject: Re: kernel trap 9 with interrupts disabled References: <200204251836.NAA41191@aurora.sol.net> <200204252115.g3PLF6c07119@apollo.backplane.com> <20020425153121.F3601@alicia.nttmcl.com> <20020425230656.GB10349@student.uu.se> <20020425162927.C1444@alicia.nttmcl.com> Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG :> :> :> To get a priority inversion like this one needs at least three tasks :> with different priorities. : :Ah, yes. I stand corrected :) : :Thanks, :-jj Right, you need three tasks, but one of them has absolutely nothing to do with the process holding the resource or the processing trying to get the resource... it simply needs to eat cpu at a priority higher then the process holding the resource. So while you need three processes, the situation winds up being quite common in a heavily loaded system and utterly trivial to reproduce. The reason this is a major problem in -stable instead of just a minor problem is due to the fact that the 'idle priority queue' is a totally separate queue that was hacked together and thrown into the system without any consideration for the consequences. The kernel's normal priority raising mechanism in tsleep() fails utterly when faced with a totally separate queue. This has been a well known problem in -stable for a long time, which is why I changed the 'idprio' to be a root-only command. It's messy to fix in -stable which is why it hasn't been... but it -current is in much better shape. In fact, for a while in -stable nice +20 and nice -20 processes could interfere with each other in the same way even without using 'idprio'. Fortunately that was fixed a few years ago. -Matt To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message