From owner-freebsd-acpi@freebsd.org Sat Sep 26 09:15:35 2015 Return-Path: Delivered-To: freebsd-acpi@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 7B2CC9B8109 for ; Sat, 26 Sep 2015 09:15:35 +0000 (UTC) (envelope-from bounces+73574-3fe6-freebsd-acpi=freebsd.org@sendgrid.net) Received: from o1.l99.sendgrid.net (o1.l99.sendgrid.net [198.37.153.74]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 35F44653 for ; Sat, 26 Sep 2015 09:15:35 +0000 (UTC) (envelope-from bounces+73574-3fe6-freebsd-acpi=freebsd.org@sendgrid.net) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sendgrid.info; h=subject:to:references:from:mime-version:in-reply-to:content-type:content-transfer-encoding; s=smtpapi; bh=QBj5Dy+yg5uq9zFrw+hgfWC/+UI=; b=I8WGsp2gURAOGyBoSS uISvQFnzfModJFjczrzt+hZKJQOhOcBqqFpIe4sbd5qJrK9+fH4wbx1FSlZ9cs6f XOyswftcklNicQx19qTaItg/kpK7BjZLTntKEpJ2ivaMJjiPjCie5oTH8V64O5mQ 4irVUowE7JKF0wpW8s5RTC5t8= Received: by filter0823p1mdw1.sendgrid.net with SMTP id filter0823p1mdw1.7047.560662348 2015-09-26 09:15:32.058209893 +0000 UTC Received: from mail.tarsnap.com (ec2-54-86-246-204.compute-1.amazonaws.com [54.86.246.204]) by ismtpd0003p1iad1.sendgrid.net (SG) with ESMTP id D5QzgkJ4Re26GclMl8Dn-w for ; Sat, 26 Sep 2015 09:15:32.700 +0000 (UTC) Received: (qmail 90744 invoked from network); 26 Sep 2015 09:15:19 -0000 Received: from unknown (HELO clamshell.daemonology.net) (127.0.0.1) by ec2-107-20-205-189.compute-1.amazonaws.com with ESMTP; 26 Sep 2015 09:15:19 -0000 Received: (qmail 47623 invoked from network); 26 Sep 2015 09:15:16 -0000 Received: from unknown (HELO clamshell.daemonology.net) (127.0.0.1) by clamshell.daemonology.net with SMTP; 26 Sep 2015 09:15:16 -0000 Subject: Re: disabling sleep when shutting down To: "freebsd-acpi@freebsd.org" , Jung-uk Kim , John Baldwin , ian Smith References: <55FA3848.7090802@freebsd.org> <55FB233D.2080000@FreeBSD.org> <55FB48E3.20401@freebsd.org> <55FC4F13.3090603@FreeBSD.org> <55FC57F9.3050702@yahoo.com> <55FE5D54.1030806@freebsd.org> <5601A863.5070406@FreeBSD.org> <560262BF.7090107@freebsd.org> <5602DE8D.3020102@FreeBSD.org> <560648A7.4030708@freebsd.org> <56065D33.7080109@obluda.cz> From: Colin Percival Message-ID: <56066224.6020503@freebsd.org> Date: Sat, 26 Sep 2015 02:15:16 -0700 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 In-Reply-To: <56065D33.7080109@obluda.cz> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-SG-EID: t2fXfoZHCw6vGsGKHqKxJ9qWwHSlQfPdDS+3+p6rOCv06w+LEbCMIKBLo64EfUtP13+P0olZBMIJdf czlIiO+J4SUb2pa6G+OKepzW7JR1B9cI5VCBGdWSYeo1Dk/3pA6MulPGwDjuxNS/BDvXYgbtRmHtjy 4vCR5QwPPhsPuns= X-BeenThere: freebsd-acpi@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: ACPI and power management development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Sep 2015 09:15:35 -0000 On 09/26/15 01:54, Dan Lukes wrote: > Colin Percival wrote: >> I've written (but not yet actually compiled or tested, so beware of typos) a patch which I think makes sense. > > It look good. > > But it seems to me the goal has been lost during discussion. It has been > started because of unwilling interaction of LID close and ongoing > shutdown, isn't it ? Yes, I tripped over this in the context of "tell FreeBSD to shut down, then close the lid of my laptop". > Unless I misunderstood the code, your patch seems to solve it for > special case only: > hw.acpi.lid_switch_state=S3 > > But what about Sx states for x -ne 3 ? > > I don't feel to be expert on ACPI code, thus it's possible those states > are handled (=ignored) correctly as well. In such case ignore this message. I may be wrong, but I believe all the ACPI Sx states go through the same function which is checking for suspend_blocked in my patch. -- Colin Percival Security Officer Emeritus, FreeBSD | The power to serve Founder, Tarsnap | www.tarsnap.com | Online backups for the truly paranoid