From patchwork Fri Jul 13 06:13:22 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Chia-Lin Kao (AceLan)" X-Patchwork-Id: 1193881 Return-Path: X-Original-To: patchwork-linux-acpi@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 57FBA3FC5A for ; Fri, 13 Jul 2012 06:13:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1030810Ab2GMGN3 (ORCPT ); Fri, 13 Jul 2012 02:13:29 -0400 Received: from mail-pb0-f46.google.com ([209.85.160.46]:44128 "EHLO mail-pb0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1030267Ab2GMGN2 (ORCPT ); Fri, 13 Jul 2012 02:13:28 -0400 Received: by pbbrp8 with SMTP id rp8so4969671pbb.19 for ; Thu, 12 Jul 2012 23:13:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:subject:date:message-id:x-mailer; bh=iur0MldXtDGnSx/QtaYoTmbH4bhb5uxspJrbsqsA9wY=; b=MrgTNg49f2Yr2TpEm9zf/DJ3eZ1a0y6KuepBwhcuoqbzb7g9NF4/+nmRDXN03Dyj2C LNcVZilIGIWdhN6uF8yf2tibU9TZJxEAEQgfK/uGE4ZJTyLhR75gJSNmgxPdEwFk0nvw kF5doZy3Stme3ivg12Lal33vVDc4PdV4hNm/6vaqxccKZo1N7DsdVdYXApMTAKBBPP5p uVd11yWaPenaUPeG4eKeqFCL+4PZHLfHVQIhmLve0KP44fKmXtKqs9qwmpCSUL92Zku9 LA3S2GQ+rC0+Z5dcoaoFQIKZBGdCHbJA93rFE8btuGkU4jAECT3tsPs7zI8OB157h6s8 CUwg== Received: by 10.68.231.233 with SMTP id tj9mr838189pbc.39.1342160007897; Thu, 12 Jul 2012 23:13:27 -0700 (PDT) Received: from localhost ([210.242.151.101]) by mx.google.com with ESMTPS id hz10sm5363149pbc.32.2012.07.12.23.13.25 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 12 Jul 2012 23:13:26 -0700 (PDT) From: AceLan Kao To: linux-acpi@vger.kernel.org, Len Brown Subject: [PATCH] ACPI button: remove hotkey suspend acpi proc event Date: Fri, 13 Jul 2012 14:13:22 +0800 Message-Id: <1342160002-13427-1-git-send-email-acelan.kao@canonical.com> X-Mailer: git-send-email 1.7.9.5 Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org If user press the suspend hotkey many times quickly, system will keep entering S3 after wake up as many times as user pressed. We do not expect the system enter S3 again after wake up, even if we press the hotkey many times. This issue comes from the acpi proc event will queue the events that didn't process yet, and then report the events one by one when available, so that system will enter S3 after wake up. I think it's safe not to generate the proc event while pressing the suspend hotkey, since "/proc/acpi/event" is deprecated. And system can enter S3 correctly without it. Signed-off-by: AceLan Kao --- drivers/acpi/button.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/acpi/button.c b/drivers/acpi/button.c index d27d072..e35bd92 100644 --- a/drivers/acpi/button.c +++ b/drivers/acpi/button.c @@ -298,8 +298,6 @@ static void acpi_button_notify(struct acpi_device *device, u32 event) pm_wakeup_event(&device->dev, 0); } - - acpi_bus_generate_proc_event(device, event, ++button->pushed); break; default: ACPI_DEBUG_PRINT((ACPI_DB_INFO,