From patchwork Wed Jul 7 22:45:34 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rafael Wysocki X-Patchwork-Id: 110748 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.4/8.14.3) with ESMTP id o67MlnUk010484 for ; Wed, 7 Jul 2010 22:47:50 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758123Ab0GGWrt (ORCPT ); Wed, 7 Jul 2010 18:47:49 -0400 Received: from ogre.sisk.pl ([217.79.144.158]:32921 "EHLO ogre.sisk.pl" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756350Ab0GGWrs (ORCPT ); Wed, 7 Jul 2010 18:47:48 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by ogre.sisk.pl (Postfix) with ESMTP id 5765018B602; Thu, 8 Jul 2010 00:32:08 +0200 (CEST) Received: from ogre.sisk.pl ([127.0.0.1]) by localhost (ogre.sisk.pl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 01083-02; Thu, 8 Jul 2010 00:31:51 +0200 (CEST) Received: from ferrari.localnet (220-bem-13.acn.waw.pl [82.210.184.220]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by ogre.sisk.pl (Postfix) with ESMTP id 443E918B60C; Thu, 8 Jul 2010 00:31:51 +0200 (CEST) From: "Rafael J. Wysocki" To: Len Brown Subject: [Resend][PATCH 4/4] ACPI / ACPICA: Fail acpi_gpe_wakeup() if ACPI_GPE_CAN_WAKE is unset Date: Thu, 8 Jul 2010 00:45:34 +0200 User-Agent: KMail/1.13.5 (Linux/2.6.35-rc4; KDE/4.4.4; x86_64; ; ) Cc: ACPI Devel Maling List , Matthew Garrett , Len Brown , linux-pm@lists.linux-foundation.org, Lin Ming , "Moore, Robert" References: <201007080041.38627.rjw@sisk.pl> In-Reply-To: <201007080041.38627.rjw@sisk.pl> MIME-Version: 1.0 Message-Id: <201007080045.34877.rjw@sisk.pl> X-Virus-Scanned: amavisd-new at ogre.sisk.pl using MkS_Vir for Linux Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Wed, 07 Jul 2010 22:47:50 +0000 (UTC) Index: linux-2.6/drivers/acpi/acpica/evxfevnt.c =================================================================== --- linux-2.6.orig/drivers/acpi/acpica/evxfevnt.c +++ linux-2.6/drivers/acpi/acpica/evxfevnt.c @@ -239,7 +239,7 @@ acpi_status acpi_gpe_wakeup(acpi_handle /* Ensure that we have a valid GPE number */ gpe_event_info = acpi_ev_get_gpe_event_info(gpe_device, gpe_number); - if (!gpe_event_info) { + if (!gpe_event_info || !(gpe_event_info->flags & ACPI_GPE_CAN_WAKE)) { status = AE_BAD_PARAMETER; goto unlock_and_exit; }