From patchwork Wed Oct 29 05:19:23 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jingoo Han X-Patchwork-Id: 5184521 Return-Path: X-Original-To: patchwork-linux-input@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 9DED29F318 for ; Wed, 29 Oct 2014 05:19:07 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9B397201CD for ; Wed, 29 Oct 2014 05:19:06 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 96E15201C7 for ; Wed, 29 Oct 2014 05:19:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751453AbaJ2FTE (ORCPT ); Wed, 29 Oct 2014 01:19:04 -0400 Received: from mailout3.samsung.com ([203.254.224.33]:8327 "EHLO mailout3.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750712AbaJ2FTD (ORCPT ); Wed, 29 Oct 2014 01:19:03 -0400 Received: from epcpsbgr1.samsung.com (u141.gpu120.samsung.co.kr [203.254.230.141]) by mailout3.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0NE60094DXFPPB80@mailout3.samsung.com> for linux-input@vger.kernel.org; Wed, 29 Oct 2014 14:19:01 +0900 (KST) Received: from epcpsbgm1.samsung.com ( [203.254.230.47]) by epcpsbgr1.samsung.com (EPCPMTA) with SMTP id CC.01.17016.5C870545; Wed, 29 Oct 2014 14:19:01 +0900 (KST) X-AuditID: cbfee68d-f79296d000004278-17-545078c5f362 Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm1.samsung.com (EPCPMTA) with SMTP id A4.16.20081.5C870545; Wed, 29 Oct 2014 14:19:01 +0900 (KST) Received: from DOJG1HAN03 ([10.89.38.123]) by mmp1.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0NE6003P8XFPGC90@mmp1.samsung.com>; Wed, 29 Oct 2014 14:19:01 +0900 (KST) From: Jingoo Han To: 'Dmitry Torokhov' Cc: linux-input@vger.kernel.org, 'Jingoo Han' References: <000501cff337$c5f23750$51d6a5f0$%han@samsung.com> In-reply-to: <000501cff337$c5f23750$51d6a5f0$%han@samsung.com> Subject: [PATCH 2/3] Input: mouse - Use __maybe_unused instead of ifdef around suspend/resume Date: Wed, 29 Oct 2014 14:19:23 +0900 Message-id: <000601cff337$e67d5cc0$b3781640$%han@samsung.com> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 7bit X-Mailer: Microsoft Office Outlook 12.0 Thread-index: Ac/zN8J8CkkH3DsSQPu700SXSoYnTQAAA9oQ Content-language: ko x-cr-hashedpuzzle: 6bw= Bqub EL2Y HL9C IADY KDvT MveI ND83 QaAH Q+Iv R0I6 SRpZ UMHW YxlA eAZ9 gkHl; 3; ZABtAGkAdAByAHkALgB0AG8AcgBvAGsAaABvAHYAQABnAG0AYQBpAGwALgBjAG8AbQA7AGoAZwAxAC4AaABhAG4AQABzAGEAbQBzAHUAbgBnAC4AYwBvAG0AOwBsAGkAbgB1AHgALQBpAG4AcAB1AHQAQAB2AGcAZQByAC4AawBlAHIAbgBlAGwALgBvAHIAZwA=; Sosha1_v1; 7; {C07565D3-426E-48FA-8BA0-114505FB2A20}; agBnADEALgBoAGEAbgBAAHMAYQBtAHMAdQBuAGcALgBjAG8AbQA=; Wed, 29 Oct 2014 05:19:17 GMT; WwBQAEEAVABDAEgAIAAyAC8AMwBdACAASQBuAHAAdQB0ADoAIABtAG8AdQBzAGUAIAAtACAAVQBzAGUAIABfAF8AbQBhAHkAYgBlAF8AdQBuAHUAcwBlA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7RioAQg7c39CwOL3rBaHF54SVW i5ufvrE6MHvsnHWX3aNvyypGj8+b5AKYoxoYbTJSE1NSixRS85LzUzLz0m2VvIPjneNNzQwM dQ0tLcyVFPISc1NtlVx8AnTdMnOANikplCXmlAKFAhKLi5X07TBNCA1x07WAaYzQ9Q0Jgusx MkADCesYM+bPX8xa8Faq4sXPx2wNjLvFuhg5OCQETCSm/bHuYuQEMsUkLtxbz9bFyMUhJLCI UeLq1ZOMIAkhgV+MEnvfGIHYbAJqEl++HGYH6RURMJSYsaYKJMws4CxxdOoiZohyW4lZjw8w gZRwCthJXDyqABIWFoiX2HJ0JwuIzSKgKvFr7x4wmxeofNW0ncwQtqDEj8n3WCBGakms33mc CcKWl9i85i0zxMXqEo/+6kIcYCRx52sJRIWIxL4X7xghHpnBKtF0KhnCNpU4uWA/+wRGkVlI FsxCsmAWkgWzkIxawMiyilE0tSC5oDgpPddQrzgxt7g0L10vOT93EyM4DTyT2sG4ssHiEKMA B6MSD++L5IAQIdbEsuLK3EOMEhzMSiK8O8yBQrwpiZVVqUX58UWlOanFhxhNgf6fyCwlmpwP TFF5JfGGxiZmRpZGZhZGJubmSuK8B1qtA4UE0hNLUrNTUwtSi2D6mDg4pRoYd05XmTgv9NAh faYpK4IFd91gT/etfN+xuXnlovXJ2uGxGpwXJ3C9sJikNv+3qcIzjXK2+Z0OG6Ys0Pz9vCrj Xq+PS7zrkb4MeX0epfWHHG2tlzv0nI/gSOLkEbv5wzbiJ+O/VXI5H6oXfTcvzVWQSfUVP9jk al/jWf5mQ8wciwXXMhlMzsQrsRRnJBpqMRcVJwIAI6HR1hkDAAA= DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Use __maybe_unused instead of ifdef guards around suspend/resume functions, in order to increase build coverage and fix build warnings. Signed-off-by: Jingoo Han --- drivers/input/mouse/cyapa.c | 6 ++---- drivers/input/mouse/navpoint.c | 6 ++---- drivers/input/mouse/synaptics_i2c.c | 6 ++---- 3 files changed, 6 insertions(+), 12 deletions(-) diff --git a/drivers/input/mouse/cyapa.c b/drivers/input/mouse/cyapa.c index b409c3d..1d978c7 100644 --- a/drivers/input/mouse/cyapa.c +++ b/drivers/input/mouse/cyapa.c @@ -905,8 +905,7 @@ static int cyapa_remove(struct i2c_client *client) return 0; } -#ifdef CONFIG_PM_SLEEP -static int cyapa_suspend(struct device *dev) +static int __maybe_unused cyapa_suspend(struct device *dev) { int ret; u8 power_mode; @@ -929,7 +928,7 @@ static int cyapa_suspend(struct device *dev) return 0; } -static int cyapa_resume(struct device *dev) +static int __maybe_unused cyapa_resume(struct device *dev) { int ret; struct cyapa *cyapa = dev_get_drvdata(dev); @@ -944,7 +943,6 @@ static int cyapa_resume(struct device *dev) enable_irq(cyapa->irq); return 0; } -#endif /* CONFIG_PM_SLEEP */ static SIMPLE_DEV_PM_OPS(cyapa_pm_ops, cyapa_suspend, cyapa_resume); diff --git a/drivers/input/mouse/navpoint.c b/drivers/input/mouse/navpoint.c index 1ccc88a..6901727 100644 --- a/drivers/input/mouse/navpoint.c +++ b/drivers/input/mouse/navpoint.c @@ -318,8 +318,7 @@ static int navpoint_remove(struct platform_device *pdev) return 0; } -#ifdef CONFIG_PM_SLEEP -static int navpoint_suspend(struct device *dev) +static int __maybe_unused navpoint_suspend(struct device *dev) { struct platform_device *pdev = to_platform_device(dev); struct navpoint *navpoint = platform_get_drvdata(pdev); @@ -333,7 +332,7 @@ static int navpoint_suspend(struct device *dev) return 0; } -static int navpoint_resume(struct device *dev) +static int __maybe_unused navpoint_resume(struct device *dev) { struct platform_device *pdev = to_platform_device(dev); struct navpoint *navpoint = platform_get_drvdata(pdev); @@ -346,7 +345,6 @@ static int navpoint_resume(struct device *dev) return 0; } -#endif static SIMPLE_DEV_PM_OPS(navpoint_pm_ops, navpoint_suspend, navpoint_resume); diff --git a/drivers/input/mouse/synaptics_i2c.c b/drivers/input/mouse/synaptics_i2c.c index ad82260..878f184 100644 --- a/drivers/input/mouse/synaptics_i2c.c +++ b/drivers/input/mouse/synaptics_i2c.c @@ -614,8 +614,7 @@ static int synaptics_i2c_remove(struct i2c_client *client) return 0; } -#ifdef CONFIG_PM_SLEEP -static int synaptics_i2c_suspend(struct device *dev) +static int __maybe_unused synaptics_i2c_suspend(struct device *dev) { struct i2c_client *client = to_i2c_client(dev); struct synaptics_i2c *touch = i2c_get_clientdata(client); @@ -628,7 +627,7 @@ static int synaptics_i2c_suspend(struct device *dev) return 0; } -static int synaptics_i2c_resume(struct device *dev) +static int __maybe_unused synaptics_i2c_resume(struct device *dev) { int ret; struct i2c_client *client = to_i2c_client(dev); @@ -643,7 +642,6 @@ static int synaptics_i2c_resume(struct device *dev) return 0; } -#endif static SIMPLE_DEV_PM_OPS(synaptics_i2c_pm, synaptics_i2c_suspend, synaptics_i2c_resume);