From patchwork Wed Nov 28 02:15:15 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hunter, Jon" X-Patchwork-Id: 1813571 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork2.kernel.org (Postfix) with ESMTP id 8BDD5DF254 for ; Wed, 28 Nov 2012 02:19:58 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1TdXC8-0005CP-NK; Wed, 28 Nov 2012 02:16:12 +0000 Received: from arroyo.ext.ti.com ([192.94.94.40]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1TdXBb-00057A-C0 for linux-arm-kernel@lists.infradead.org; Wed, 28 Nov 2012 02:15:40 +0000 Received: from dlelxv30.itg.ti.com ([172.17.2.17]) by arroyo.ext.ti.com (8.13.7/8.13.7) with ESMTP id qAS2FXFf002599; Tue, 27 Nov 2012 20:15:33 -0600 Received: from DFLE72.ent.ti.com (dfle72.ent.ti.com [128.247.5.109]) by dlelxv30.itg.ti.com (8.13.8/8.13.8) with ESMTP id qAS2FX58018397; Tue, 27 Nov 2012 20:15:33 -0600 Received: from dlelxv24.itg.ti.com (172.17.1.199) by dfle72.ent.ti.com (128.247.5.109) with Microsoft SMTP Server id 14.1.323.3; Tue, 27 Nov 2012 20:15:32 -0600 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dlelxv24.itg.ti.com (8.13.8/8.13.8) with ESMTP id qAS2FWL0024655; Tue, 27 Nov 2012 20:15:32 -0600 Received: from localhost (h114-231.vpn.ti.com [172.24.114.231]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id qAS2FUw05057; Tue, 27 Nov 2012 20:15:31 -0600 (CST) From: Jon Hunter To: Tony Lindgren Subject: [PATCH 3/3] ARM: AM335x: Fix warning in timer.c Date: Tue, 27 Nov 2012 20:15:15 -0600 Message-ID: <1354068915-3378-4-git-send-email-jon-hunter@ti.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1354068915-3378-1-git-send-email-jon-hunter@ti.com> References: <1354068915-3378-1-git-send-email-jon-hunter@ti.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20121127_211539_582888_AE353569 X-CRM114-Status: GOOD ( 13.95 ) X-Spam-Score: -6.1 (------) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-6.1 points) pts rule name description ---- ---------------------- -------------------------------------------------- -5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at http://www.dnswl.org/, high trust [192.94.94.40 listed in list.dnswl.org] 1.5 URIBL_RHS_DOB Contains an URI of a new domain (Day Old Bread) [URIs: ti.com] -0.0 SPF_PASS SPF: sender matches SPF record -0.7 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: linux-omap , Jon Hunter , linux-arm , Igor Grinberg X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org When compiling the kernel with configuration options ... # CONFIG_ARCH_OMAP2 is not set # CONFIG_ARCH_OMAP3 is not set # CONFIG_ARCH_OMAP4 is not set # CONFIG_SOC_OMAP5 is not set CONFIG_SOC_AM33XX=y ... the following build warning is seen. CC arch/arm/mach-omap2/timer.o arch/arm/mach-omap2/timer.c:395:19: warning: ‘omap2_sync32k_clocksource_init’ defined but not used [-Wunused-function] This issue was introduced by commit 6f80b3b (ARM: OMAP2+: timer: remove CONFIG_OMAP_32K_TIMER) where the omap2_sync32k_clocksource_init() is no longer referenced by the timer initialisation function for the AM335x device as it has no 32k-sync timer. Fix this by only including the omap2_sync32k_clocksource_init() function if either OMAP2, OMAP3, OMAP4 or OMAP5 devices are enabled. Cc: Igor Grinberg Signed-off-by: Jon Hunter --- arch/arm/mach-omap2/timer.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/mach-omap2/timer.c b/arch/arm/mach-omap2/timer.c index eb96712..085c7e7 100644 --- a/arch/arm/mach-omap2/timer.c +++ b/arch/arm/mach-omap2/timer.c @@ -386,6 +386,8 @@ static u32 notrace dmtimer_read_sched_clock(void) return 0; } +#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3) || \ + defined(CONFIG_ARCH_OMAP4) || defined(CONFIG_SOC_OMAP5) static struct of_device_id omap_counter_match[] __initdata = { { .compatible = "ti,omap-counter32k", }, { } @@ -451,6 +453,7 @@ static int __init omap2_sync32k_clocksource_init(void) return ret; } +#endif static void __init omap2_gptimer_clocksource_init(int gptimer_id, const char *fck_source)