From patchwork Thu Jul 20 15:51:45 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 9855239 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 67447602BA for ; Thu, 20 Jul 2017 15:54:23 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 586F6286B2 for ; Thu, 20 Jul 2017 15:54:23 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4D274286D6; Thu, 20 Jul 2017 15:54:23 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F079A286B2 for ; Thu, 20 Jul 2017 15:54:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935168AbdGTPyU (ORCPT ); Thu, 20 Jul 2017 11:54:20 -0400 Received: from mout.kundenserver.de ([212.227.126.130]:63615 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934344AbdGTPyU (ORCPT ); Thu, 20 Jul 2017 11:54:20 -0400 Received: from wuerfel.lan ([5.56.224.194]) by mrelayeu.kundenserver.de (mreue002 [212.227.15.129]) with ESMTPA (Nemesis) id 0M4voU-1dp3pO04mk-00zDwT; Thu, 20 Jul 2017 17:53:12 +0200 From: Arnd Bergmann To: Aaro Koskinen , Tony Lindgren Cc: Arnd Bergmann , linux-arm-kernel@lists.infradead.org, linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 07/12] ARM: omap1: avoid unused variable warning Date: Thu, 20 Jul 2017 17:51:45 +0200 Message-Id: <20170720155209.3250880-4-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 In-Reply-To: <20170720154616.3250481-1-arnd@arndb.de> References: <20170720154616.3250481-1-arnd@arndb.de> X-Provags-ID: V03:K0:XvEtgmrEdj1cXzLdnQACwjtxl/wvPW1Uo+u6vyqXhwVkg0Qtmkt FQs+jARkM72hmWrzuuCZU3VXWt3A5P5M/Ic05/0GybqI4mHa8ZxJ+MOwsOUcEbQlXb/A8Vu oo6eSJckrwgPL+82jRa0jepfQmlZVfSuIGw58HF2a6wV15iBeH5t5+d76nSYu9B7UkNYMvk u3nxcfLro0788AEnHfPcw== X-UI-Out-Filterresults: notjunk:1; V01:K0:SGgYUckUfZg=:jyZVfJkbGr+KIxV+2e0N7O 2ttEtvx+4BohyYfeA24ulpgAy76G/71AhQ/3cWC9KnGvvjJ8vkpQjYeuwDVuL+YXWceBHHH46 Eg/SXiRHdsg3aHJA+bZdieW35PLEp+rsIrkLXl3RLRAIwU4mXv1TVeWXFVzpeR+WMQz1zBrtq AAEymbWPkfIAg5/I1c+l8lqtzuNlfmq3mOt5YnwmAWpCbGhFcSS9+UlE6yz8rpya53+dwk+ei Ore8OwCi8noi4vEfir8z2d57EDDKHHClveV2DUonYAPFxVhJsQuJ+FdJ4TU06org+PlbZQU4h vkxvDvAeNBjOMkqkNtLTYsn4o9+lEEUIsJWPB8t00WkRSMi3ypvUBbo1pqD2MKGD49Vg8rmMF kQGnENsvhKKqGr0WXmJYAQwCHWLbRMyEW1OQN0z2q2q/q0ZTdn+yZh38KIGx8QftdhBv9ouUI 2YEdKaL9idq3Y3dkjSd4Hd9oHwbYCgP0YIRCD5hCrkmgyDwuWTdIFWMGNZcdwuZkHqDz1G/Dk TQoOxf6Q8uj4RMLGMKJdcck5ntyPnBipwNEAhFcZhPGCVwKDG2sCEigCR46x/uaKKR4bPv2Ov fLuBo0+peB0VN7mS8dnGdHez86eo5PUHqWbhpJvyruCgQ2xosouuzxu4WeC1VrgylKb1JDSTX 4UJF/gRI6bZhLuTRZvi3MrjDA85yuDbXp0n3cV8a3RuDKL68Zwjvk6nV8LeBFSci+H3HL2rX8 Y7GtTyuz9nOoRJPqlA08zBvVxgWzfXSY0IA/Ng== Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The osk_mistral_init() contains code that is only compiled when CONFIG_PM is set, but it uses a variable that is declared outside of the #ifdef: arch/arm/mach-omap1/board-osk.c: In function 'osk_mistral_init': arch/arm/mach-omap1/board-osk.c:513:7: warning: unused variable 'ret' [-Wunused-variable] This removes the #ifdef around the user of the variable, make it always used. Signed-off-by: Arnd Bergmann Suggested-by: Tony Lindgren Acked-by: Aaro Koskinen --- arch/arm/mach-omap1/board-osk.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/arch/arm/mach-omap1/board-osk.c b/arch/arm/mach-omap1/board-osk.c index 4dfb99504810..95ac1929aede 100644 --- a/arch/arm/mach-omap1/board-osk.c +++ b/arch/arm/mach-omap1/board-osk.c @@ -441,13 +441,11 @@ static struct spi_board_info __initdata mistral_boardinfo[] = { { .chip_select = 0, } }; -#ifdef CONFIG_PM static irqreturn_t osk_mistral_wake_interrupt(int irq, void *ignored) { return IRQ_HANDLED; } -#endif static void __init osk_mistral_init(void) { @@ -515,7 +513,6 @@ static void __init osk_mistral_init(void) gpio_direction_input(OMAP_MPUIO(2)); irq_set_irq_type(irq, IRQ_TYPE_EDGE_RISING); -#ifdef CONFIG_PM /* share the IRQ in case someone wants to use the * button for more than wakeup from system sleep. */ @@ -529,7 +526,6 @@ static void __init osk_mistral_init(void) ret); } else enable_irq_wake(irq); -#endif } else printk(KERN_ERR "OSK+Mistral: wakeup button is awol\n");