From patchwork Fri Jul 6 15:15:19 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 10511939 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 CB620603D7 for ; Fri, 6 Jul 2018 15:16:08 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BB2EC286BC for ; Fri, 6 Jul 2018 15:16:08 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id ACA54286BF; Fri, 6 Jul 2018 15:16:08 +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=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 58A88286BC for ; Fri, 6 Jul 2018 15:16:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Owner; bh=uI6yGJO/qRLvvkXMOaS+gJCe75hukWCM3n690Mal2y4=; b=miu JbTbC7+QRuKE8Zp/AJ/bYh8D2MJWDTpXkXkHJVEtNVthQInYtV7hXKEbcaxlXPwIpc5cKl8FRBFxf gQ+YF/UHAEu6FrO7sIsh7x2YrbPqQP4fEw1aJ2Qn2o7LwMmBxgGcqyL/kfrZaHgk8RQFQf3+dGe/0 JbROh7sKMaXqcu3L0+7Jm1FqXIvgA3kD3R14w2e5jBCJwuiaIWk0QbPfZMAewMT3P6DUifrO5796/ /yeyYyPwU9TTIOc5YWzNOkG5T5g7OAnpBRKws0xhoRp/ODR9QbEJW4KrlHxKg8kxEdUZqNK952oTO Gxs0YQnOGfAzbAMfPq/lUIKnTD0kUZQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fbSSr-0006YF-IP; Fri, 06 Jul 2018 15:16:05 +0000 Received: from mout.kundenserver.de ([217.72.192.74]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fbSSo-0006Wo-D7 for linux-arm-kernel@lists.infradead.org; Fri, 06 Jul 2018 15:16:04 +0000 Received: from wuerfel.lan ([46.223.138.35]) by mrelayeu.kundenserver.de (mreue101 [212.227.15.145]) with ESMTPA (Nemesis) id 0Lx70L-1gCZRt2tg1-016eQb; Fri, 06 Jul 2018 17:15:32 +0200 From: Arnd Bergmann To: Simon Horman , Magnus Damm Subject: [PATCH] ARM: shmobile: r8a7779: hide unused r8a7779_platform_cpu_kill Date: Fri, 6 Jul 2018 17:15:19 +0200 Message-Id: <20180706151528.3759312-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K1:H0IJLaOwxpSI1u+aeBkfsD1IXKxfuBvey2775URZ7tvMdSq3R+u 4zk4I4FtmoZePIlCO7iTwcNVG+p6mlT9V3kk4mN46ysuDvwab/JpRVfhHNQNPBtkvdqiIOt f+Ih4lpKl5xZtUwAn9cpE/gSxsi/Mc8us9izmVtXcEWWbFr6tprG9uMyPp6JkUFpyoS8raX sKu2N1Wm/3b+HCNTv1qnQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:2oBWXK5I0bc=:zO2GLzxp1vY/sfKs+i10X2 s69S1rw0tgWXZVArct66OUJqGL5+33h9o2FY+Rk5eq1I+T5WBJdphd3NighY/HTn3mkIo25z8 U80JYR2tdpIy4Vkq5Xxn22F1i2FhZgE4GauLubmQNhFxrkgI1rv+15RlKN669U2LOepSCrZYF LBFeyh3h22QxVBTjThV9V8BcLarN2lHGiJxYGWD4BXnaVIEGnfyQwh29Uin7LN3/Hmf93evlY 4sC5wGRy516OmEoNxNpK1E46EfWoCubcXo2fHkT5UCpgNpAxb8/y5W3bJ4PnE58CRBCBI8E3X +1ET8Eh4XHTK2p7kHQ5By9dzKImUVIAi0pz/1HwBmDdcDz2sxKTDz1gJYsEbzlKHiz3cVAC91 2J/9EYcz5O/gzRU8llmmaU7X9tZXC6ag/VXmB4dFYtJoGLCLKld1lYcbL4VNkJHO8AxDhmDBA azEnwiajV1vOh1QXzJhBeKTkc9Wdg5KZ0E4clU4SXqBAvKq1fHitbRoZk1qKPWBFy4MnLVIhb XPFd/gOaIJuhVZBNohMeQ58X8B/dG2+bQfYm3SabAzefnHx+MofF+jdhCBvGTK48zVdNWgmIv 8T3TcpJol2gia7NBTn+aVI6URPDJ2uuoAFjlI6ukhLume3b4PK/2T7q9BEjX3KY7ZcQoxEpPl TMnL4Zwjb3XUn8+jfAn2XBm5/i4iBchdBuNIvHJimUrs7u1I3ok0BHBSAzHP3BlENdfg= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180706_081602_741730_C49EC8AF X-CRM114-Status: GOOD ( 13.35 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Arnd Bergmann , Geert Uytterhoeven , Yoshihiro Shimoda , linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, Wolfram Sang , linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP After the cleanup in r8a7779_smp_prepare_cpus(), the only remaining caller of r8a7779_platform_cpu_kill() is in an ifdef, which leads to a build warning without CONFIG_HOTPLUG_CPU: arch/arm/mach-shmobile/smp-r8a7779.c:26:12: error: 'r8a7779_platform_cpu_kill' defined but not used [-Werror=unused-function] This moves the function inside of that #ifdef to avoid the warning. Fixes: 62f55ce683e3 ("ARM: shmobile: r8a7779: Stop powering down secondary CPUs during early boot") Signed-off-by: Arnd Bergmann Reviewed-by: Geert Uytterhoeven --- arch/arm/mach-shmobile/smp-r8a7779.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/arch/arm/mach-shmobile/smp-r8a7779.c b/arch/arm/mach-shmobile/smp-r8a7779.c index b7fe1f489b08..0ed73b650c14 100644 --- a/arch/arm/mach-shmobile/smp-r8a7779.c +++ b/arch/arm/mach-shmobile/smp-r8a7779.c @@ -23,17 +23,6 @@ #define AVECR IOMEM(0xfe700040) #define R8A7779_SCU_BASE 0xf0000000 -static int r8a7779_platform_cpu_kill(unsigned int cpu) -{ - int ret = -EIO; - - cpu = cpu_logical_map(cpu); - if (cpu) - ret = rcar_sysc_power_down_cpu(cpu); - - return ret ? ret : 1; -} - static int r8a7779_boot_secondary(unsigned int cpu, struct task_struct *idle) { int ret = -EIO; @@ -55,6 +44,17 @@ static void __init r8a7779_smp_prepare_cpus(unsigned int max_cpus) } #ifdef CONFIG_HOTPLUG_CPU +static int r8a7779_platform_cpu_kill(unsigned int cpu) +{ + int ret = -EIO; + + cpu = cpu_logical_map(cpu); + if (cpu) + ret = rcar_sysc_power_down_cpu(cpu); + + return ret ? ret : 1; +} + static int r8a7779_cpu_kill(unsigned int cpu) { if (shmobile_smp_scu_cpu_kill(cpu))