From patchwork Fri May 8 04:39:38 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Len Brown X-Patchwork-Id: 22527 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n484eCgX005706 for ; Fri, 8 May 2009 04:40:12 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751444AbZEHEkK (ORCPT ); Fri, 8 May 2009 00:40:10 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751481AbZEHEkJ (ORCPT ); Fri, 8 May 2009 00:40:09 -0400 Received: from vms173017pub.verizon.net ([206.46.173.17]:53845 "EHLO vms173017pub.verizon.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751444AbZEHEkI (ORCPT ); Fri, 8 May 2009 00:40:08 -0400 Received: from localhost.localdomain ([96.237.168.40]) by vms173017.mailsrvcs.net (Sun Java(tm) System Messaging Server 6.3-7.04 (built Sep 26 2008; 32bit)) with ESMTPA id <0KJB002RW6A5J0TN@vms173017.mailsrvcs.net> for linux-acpi@vger.kernel.org; Thu, 07 May 2009 23:39:47 -0500 (CDT) Received: from localhost.localdomain (d975xbx2 [127.0.0.1]) by localhost.localdomain (8.14.2/8.14.2) with ESMTP id n484deT3010937; Fri, 08 May 2009 00:39:40 -0400 Received: from localhost (lenb@localhost) by localhost.localdomain (8.14.2/8.14.2/Submit) with ESMTP id n484dcX9010932; Fri, 08 May 2009 00:39:38 -0400 X-Authentication-warning: localhost.localdomain: lenb owned process doing -bs Date: Fri, 08 May 2009 00:39:38 -0400 (EDT) From: Len Brown X-X-Sender: lenb@localhost.localdomain To: Witold Szczeponik Cc: yakui_zhao , Bjorn Helgaas , "Rafael J. Wysocki" , "cedric@belbone.be" , linux-acpi@vger.kernel.org Subject: [PATCH] ACPI: suspend: don't let device _PS3 failure prevent suspend In-reply-to: <4A0330E3.9060909@gmx.net> Message-id: References: <20090505150138.92f3ecd6.akpm@linux-foundation.org> <4A02000D.9030400@gmx.net> <200905061616.36707.bjorn.helgaas@hp.com> <1241660638.3773.90.camel@localhost.localdomain> <4A0330E3.9060909@gmx.net> User-Agent: Alpine 2.00 (LFD 1167 2008-08-23) MIME-version: 1.0 Content-type: TEXT/PLAIN; charset=US-ASCII Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org From: Len Brown 6328a57401dc5f5cf9931738eb7268fcd8058c49 "Enable PNPACPI _PSx Support, v3" added a call to acpi_bus_set_power(handle, ACPI_STATE_D3) to pnpacpi_disable_resource() before the existing call to evaluate _DIS on the device. This caused suspend to fail on the system in http://bugzilla.kernel.org/show_bug.cgi?id=13243 because the sanity check to verify we entered _PS3 failed on the serial port. As a work-around, that sanity check can be disabled system-wide with "acpi.power_nocheck=1" Or perhaps we should just shrug off the _PS3 failure and carry on with _DIS like we used to -- which is what this patch does. Signed-off-by: Len Brown --- drivers/pnp/pnpacpi/core.c | 8 +++----- 1 files changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/pnp/pnpacpi/core.c b/drivers/pnp/pnpacpi/core.c index 9a3a682..9496494 100644 --- a/drivers/pnp/pnpacpi/core.c +++ b/drivers/pnp/pnpacpi/core.c @@ -110,11 +110,9 @@ static int pnpacpi_disable_resources(struct pnp_dev *dev) /* acpi_unregister_gsi(pnp_irq(dev, 0)); */ ret = 0; - if (acpi_bus_power_manageable(handle)) { - ret = acpi_bus_set_power(handle, ACPI_STATE_D3); - if (ret) - return ret; - } + if (acpi_bus_power_manageable(handle)) + acpi_bus_set_power(handle, ACPI_STATE_D3); + /* continue even if acpi_bus_set_power() fails */ if (ACPI_FAILURE(acpi_evaluate_object(handle, "_DIS", NULL, NULL))) ret = -ENODEV; return ret;