From owner-cvs-all@FreeBSD.ORG Tue Apr 18 08:10:47 2006 Return-Path: X-Original-To: cvs-all@FreeBSD.org Delivered-To: cvs-all@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DA48A16A403; Tue, 18 Apr 2006 08:10:47 +0000 (UTC) (envelope-from glebius@FreeBSD.org) Received: from cell.sick.ru (cell.sick.ru [217.72.144.68]) by mx1.FreeBSD.org (Postfix) with ESMTP id D03FA43D72; Tue, 18 Apr 2006 08:10:39 +0000 (GMT) (envelope-from glebius@FreeBSD.org) Received: from cell.sick.ru (glebius@localhost [127.0.0.1]) by cell.sick.ru (8.13.4/8.13.3) with ESMTP id k3I8Abm7044662 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 18 Apr 2006 12:10:37 +0400 (MSD) (envelope-from glebius@FreeBSD.org) Received: (from glebius@localhost) by cell.sick.ru (8.13.4/8.13.1/Submit) id k3I8Abmg044661; Tue, 18 Apr 2006 12:10:37 +0400 (MSD) (envelope-from glebius@FreeBSD.org) X-Authentication-Warning: cell.sick.ru: glebius set sender to glebius@FreeBSD.org using -f Date: Tue, 18 Apr 2006 12:10:36 +0400 From: Gleb Smirnoff To: John Baldwin , sam@FreeBSD.org Message-ID: <20060418081036.GU84736@FreeBSD.org> References: <200604171820.k3HIKcx3068404@repoman.freebsd.org> <200604171514.06482.jhb@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <200604171514.06482.jhb@freebsd.org> User-Agent: Mutt/1.5.6i Cc: cvs-src@FreeBSD.org, src-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/dev/hwpmc hwpmc_mod.c src/sys/dev/random randomdev_soft.c src/sys/kern kern_intr.c kern_poll.c kern_synch.c kern_thr.c kern_umtx.c sched_4bsd.c subr_taskqueue.c uipc_mqueue.c src/sys/vm vm_zeroidle.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Apr 2006 08:10:49 -0000 On Mon, Apr 17, 2006 at 03:14:03PM -0400, John Baldwin wrote: J> > Change msleep() and tsleep() to not alter the calling thread's priority J> > if the specified priority is zero. This avoids a race where the calling J> > thread could read a snapshot of it's current priority, then a different J> > thread could change the first thread's priority, then the original thread J> > would call sched_prio() inside msleep() undoing the change made by the J> > second thread. I used a priority of zero as no thread that calls msleep() J> > or tsleep() should be specifying a priority of zero anyway. J> > J> > The various places that passed 'curthread->td_priority' or some variant J> > as the priority now pass 0. J> J> This should fix the problem where the first acpi taskq would run with J> a bogus priority (the sched_prio() when creating the taskqueue seemed J> to be ignored). Sorry for probably lame guess... Is this going to fix the problem with ACPI and new taskqueues? -- Totus tuus, Glebius. GLEBIUS-RIPN GLEB-RIPE