From owner-freebsd-current@FreeBSD.ORG Wed Oct 3 16:42:23 2007 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3551716A494 for ; Wed, 3 Oct 2007 16:42:23 +0000 (UTC) (envelope-from dana.myers@gmail.com) Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.246]) by mx1.freebsd.org (Postfix) with ESMTP id 0046013C505 for ; Wed, 3 Oct 2007 16:42:15 +0000 (UTC) (envelope-from dana.myers@gmail.com) Received: by an-out-0708.google.com with SMTP id c14so941148anc for ; Wed, 03 Oct 2007 09:42:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; bh=XuuXItPH4aQlNEKSHe0xjhATyYPRV1OMfN5eXi4a3bA=; b=ZrIJZQmJgRgNM5ghxn4EIb+gamefBALFmC+hA4KUaxvIr3c4HcavWNstkjXWUsuyruioK+gJ5ASoaUKCfzDii03RbSvScgwBytyUJM/b+snIyTqOq3bsF53tHNNdjYTb9f8W/hwVSp2UoTdqKwEiS8mmaWQkFpijhZpxMIrLfJk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; b=Ks2j+Yp2P3CFqi4OO5RxYtsnlg9ECvyGUEFq1eJryf4BGHa73kCUt/X6QqsrW/JC0m5zqRvLE8h6erm8rPHU0EQzOIf3mvnzzwn6kEoD7VP61RiO4tP+jl0Ij44HysAjbSx2qUgwJQDRgHobeQFcIL6AyZE/uavgZ2QUp5xEGj8= Received: by 10.142.135.9 with SMTP id i9mr717502wfd.1191428238497; Wed, 03 Oct 2007 09:17:18 -0700 (PDT) Received: from ?192.168.0.2? ( [67.180.22.170]) by mx.google.com with ESMTPS id f42sm1547301rvb.2007.10.03.09.17.17 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 03 Oct 2007 09:17:17 -0700 (PDT) Message-ID: <4703C08B.6040703@gmail.com> Date: Wed, 03 Oct 2007 09:17:15 -0700 From: "Dana H. Myers" User-Agent: Thunderbird 2.0.0.6 (Windows/20070728) MIME-Version: 1.0 To: Nate Lawson References: <470002B5.6030002@root.org> <200710031138.28820.jkim@FreeBSD.org> <4703BD8D.1080501@root.org> In-Reply-To: <4703BD8D.1080501@root.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Wed, 03 Oct 2007 17:12:44 +0000 Cc: freebsd-acpi@FreeBSD.org, freebsd-current@FreeBSD.org, Jung-uk Kim Subject: Re: patch: change in acpi taskq behavior X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 Oct 2007 16:42:23 -0000 Nate Lawson wrote: > 1. Run a task at some point in the future but "soon" > 2. Queue a task to be run, definitely after boot is complete > > Notifies are in the first class. Initialization functions for the > various drivers are in the second. ACPI-CA is moving to making all > Notifies completely synchronous (i.e. they wait for the thread to run). Note that I've encountered an issue with synchronous Notify in the Solaris port of ACPI CA on a particular machine. Specifically, the Acer Ferrari 3400 deadlocks while delivering AC/battery events, since Notify() is performed while holding a mutex. The AC/battery driver notify handler evaluates _STA and _BST, and either of these attempt to hold the same mutex. Bob Moore and I have been discussing solutions for this but have nothing firm at this point. While I suppose I *could* make the AC/battery driver Notify handler behave like a high-level interrupt and simply schedule yet another thread to run to handle the Notify, this scheme generally ends up the same as asynchronous Notify in the first place. Dana