From patchwork Thu Jul 31 18:42:05 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabio Estevam X-Patchwork-Id: 4658601 Return-Path: X-Original-To: patchwork-linux-input@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id A334CC0338 for ; Thu, 31 Jul 2014 18:42:29 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DBFB420138 for ; Thu, 31 Jul 2014 18:42:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id AB48B2012E for ; Thu, 31 Jul 2014 18:42:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751818AbaGaSm0 (ORCPT ); Thu, 31 Jul 2014 14:42:26 -0400 Received: from mail-vc0-f177.google.com ([209.85.220.177]:52921 "EHLO mail-vc0-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751502AbaGaSm0 (ORCPT ); Thu, 31 Jul 2014 14:42:26 -0400 Received: by mail-vc0-f177.google.com with SMTP id hy4so4829675vcb.22 for ; Thu, 31 Jul 2014 11:42:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=XgMpqWBjHatP3+Jnjesfo39Q9q6o35TUZGAXYYx6guw=; b=PCc+ENgmI5z3FbMF7lRvGGq3DC/rrfnRBrdCI96+0EtToChqH/aSaAnzDyCmbzw2H8 +vSly0XAba5oX6uj9AP7seCZI1TagDzVyGbRZShaI2ctUG/J2VIFKC33HLLXB19ObO7P ufzLsWWwo4+qhzJj4YxdRNSbGFvgrGPQzq5qzyMcvVajsaDr1rY+8+pVufrFDDK3gkpz Jb7emREdqH53j5zT3JM2Bcv7bTwMI8BCd/zGPCHdJqfw26QD5V30xf1byE6fE0iEkNMC HUvgzZeMXSRPcxH+0GLDRdsrB0i6pzkVr0kJpidGkxpM6bvKrThwjlzOukzO15QrnTb9 cLvQ== X-Received: by 10.220.5.138 with SMTP id 10mr42811vcv.67.1406832145512; Thu, 31 Jul 2014 11:42:25 -0700 (PDT) Received: from localhost.localdomain ([186.207.90.28]) by mx.google.com with ESMTPSA id mz10sm15419510vdb.17.2014.07.31.11.42.23 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 31 Jul 2014 11:42:24 -0700 (PDT) From: Fabio Estevam To: dmitry.torokhov@gmail.com Cc: linux-input@vger.kernel.org, Fabio Estevam Subject: [PATCH] Input: imx_keypad - Remove ifdef Date: Thu, 31 Jul 2014 15:42:05 -0300 Message-Id: <1406832125-3814-1-git-send-email-festevam@gmail.com> X-Mailer: git-send-email 1.9.1 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, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=ham 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 From: Fabio Estevam We can annonate the suspend/resume functions with '__maybe_unused' and get rid of the ifdef, which makes the code smaller and simpler Signed-off-by: Fabio Estevam --- drivers/input/keyboard/imx_keypad.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/input/keyboard/imx_keypad.c b/drivers/input/keyboard/imx_keypad.c index 8280cb1..20a99c3 100644 --- a/drivers/input/keyboard/imx_keypad.c +++ b/drivers/input/keyboard/imx_keypad.c @@ -531,8 +531,7 @@ static int imx_keypad_probe(struct platform_device *pdev) return 0; } -#ifdef CONFIG_PM_SLEEP -static int imx_kbd_suspend(struct device *dev) +static int __maybe_unused imx_kbd_suspend(struct device *dev) { struct platform_device *pdev = to_platform_device(dev); struct imx_keypad *kbd = platform_get_drvdata(pdev); @@ -552,7 +551,7 @@ static int imx_kbd_suspend(struct device *dev) return 0; } -static int imx_kbd_resume(struct device *dev) +static int __maybe_unused imx_kbd_resume(struct device *dev) { struct platform_device *pdev = to_platform_device(dev); struct imx_keypad *kbd = platform_get_drvdata(pdev); @@ -575,7 +574,6 @@ err_clk: return ret; } -#endif static SIMPLE_DEV_PM_OPS(imx_kbd_pm_ops, imx_kbd_suspend, imx_kbd_resume);