From patchwork Sun Sep 27 07:52:54 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ingo Molnar X-Patchwork-Id: 50301 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 n8R7rbv4024601 for ; Sun, 27 Sep 2009 07:53:37 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753369AbZI0Hxc (ORCPT ); Sun, 27 Sep 2009 03:53:32 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753373AbZI0Hxc (ORCPT ); Sun, 27 Sep 2009 03:53:32 -0400 Received: from mx2.mail.elte.hu ([157.181.151.9]:60893 "EHLO mx2.mail.elte.hu" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753369AbZI0Hxb (ORCPT ); Sun, 27 Sep 2009 03:53:31 -0400 Received: from elvis.elte.hu ([157.181.1.14]) by mx2.mail.elte.hu with esmtp (Exim) id 1MroYz-0005tm-Lq from ; Sun, 27 Sep 2009 09:53:03 +0200 Received: by elvis.elte.hu (Postfix, from userid 1004) id E22EC3E22DD; Sun, 27 Sep 2009 09:52:54 +0200 (CEST) Date: Sun, 27 Sep 2009 09:52:54 +0200 From: Ingo Molnar To: Len Brown Cc: torvalds@linux-foundation.org, akpm@linux-foundation.org, linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [origin tree build failure] [PATCH] thinkpad-acpi: Fix build on !CONFIG_THINKPAD_ACPI_HOTKEY_POLL Message-ID: <20090927075254.GA20847@elte.hu> References: <200909260519.n8Q5JrB6016778@hera.kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <200909260519.n8Q5JrB6016778@hera.kernel.org> User-Agent: Mutt/1.5.18 (2008-05-17) Received-SPF: neutral (mx2.mail.elte.hu: 157.181.1.14 is neither permitted nor denied by domain of elte.hu) client-ip=157.181.1.14; envelope-from=mingo@elte.hu; helo=elvis.elte.hu; X-ELTE-SpamScore: -1.5 X-ELTE-SpamLevel: X-ELTE-SpamCheck: no X-ELTE-SpamVersion: ELTE 2.0 X-ELTE-SpamCheck-Details: score=-1.5 required=5.9 tests=BAYES_00 autolearn=no SpamAssassin version=3.2.5 -1.5 BAYES_00 BODY: Bayesian spam probability is 0 to 1% [score: 0.0000] Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org > drivers/platform/x86/thinkpad_acpi.c | 632 +++++++++++++++++++--------- -tip testing found that these changes caused a build failure in drivers/platform/x86/thinkpad_acpi.c when !CONFIG_THINKPAD_ACPI_HOTKEY_POLL - the fix is attached below. Thanks, Ingo -------------------------> From 7f6443f7238a0aa9014b11a0a31ab76825d75cdf Mon Sep 17 00:00:00 2001 From: Ingo Molnar Date: Sun, 27 Sep 2009 09:47:46 +0200 Subject: [PATCH] thinkpad-acpi: Fix build on !CONFIG_THINKPAD_ACPI_HOTKEY_POLL This build error: drivers/platform/x86/thinkpad_acpi.c: In function 'tpacpi_hotkey_driver_mask_set': drivers/platform/x86/thinkpad_acpi.c:2238: error: lvalue required as left operand of assignment Triggers because in the !CONFIG_THINKPAD_ACPI_HOTKEY_POLL case tpacpi_hotkey_driver_mask_set ymbol is defined to a constant literal - which is not an lvalue so cannot be assigned to. The whole tpacpi_hotkey_driver_mask_set() function is not used in the !CONFIG_THINKPAD_ACPI_HOTKEY_POLL, so enclose it with an #ifdef. Signed-off-by: Ingo Molnar --- drivers/platform/x86/thinkpad_acpi.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-acpi" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/platform/x86/thinkpad_acpi.c b/drivers/platform/x86/thinkpad_acpi.c index 3910f2f..a52dbc9 100644 --- a/drivers/platform/x86/thinkpad_acpi.c +++ b/drivers/platform/x86/thinkpad_acpi.c @@ -2216,6 +2216,7 @@ static int hotkey_user_mask_set(const u32 mask) return rc; } +#ifdef CONFIG_THINKPAD_ACPI_HOTKEY_POLL /* * Sets the driver hotkey mask. * @@ -2244,6 +2245,7 @@ static int tpacpi_hotkey_driver_mask_set(const u32 mask) return rc; } +#endif static int hotkey_status_get(int *status) {