From patchwork Tue Oct 9 15:40:54 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonathan Austin X-Patchwork-Id: 1570621 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork1.kernel.org (Postfix) with ESMTP id D54E340135 for ; Tue, 9 Oct 2012 15:42:55 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1TLbvj-0004Fq-1t; Tue, 09 Oct 2012 15:41:11 +0000 Received: from service87.mimecast.com ([91.220.42.44]) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1TLbvd-0004CR-9E for linux-arm-kernel@lists.infradead.org; Tue, 09 Oct 2012 15:41:06 +0000 Received: from cam-owa1.Emea.Arm.com (fw-tnat.cambridge.arm.com [217.140.96.21]) by service87.mimecast.com; Tue, 09 Oct 2012 16:41:00 +0100 Received: from [10.1.68.61] ([10.1.255.212]) by cam-owa1.Emea.Arm.com with Microsoft SMTPSVC(6.0.3790.0); Tue, 9 Oct 2012 16:41:00 +0100 Message-ID: <50744586.6010806@arm.com> Date: Tue, 09 Oct 2012 16:40:54 +0100 From: Jonathan Austin User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.28) Gecko/20120313 Lightning/1.0b2 Thunderbird/3.1.20 MIME-Version: 1.0 To: Arnd Bergmann Subject: Re: [PATCH 4/9] ARM: export default read_current_timer References: <1349796183-30648-1-git-send-email-arnd@arndb.de> <1349796183-30648-5-git-send-email-arnd@arndb.de> In-Reply-To: <1349796183-30648-5-git-send-email-arnd@arndb.de> X-OriginalArrivalTime: 09 Oct 2012 15:41:00.0493 (UTC) FILETIME=[7B8C87D0:01CDA634] X-MC-Unique: 112100916410010601 X-Spam-Note: CRM114 invocation failed X-Spam-Score: -2.6 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.6 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [91.220.42.44 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Will Deacon , Russell King , Stephen Boyd , "linux-kernel@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" 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 Hi Arnd, On 09/10/12 16:22, Arnd Bergmann wrote: > read_current_timer is used by get_cycles since "ARM: 7538/1: delay: > add registration mechanism for delay timer sources", and get_cycles > can be used by device drivers in loadable modules, so it has to > be exported. > > Without this patch, building imote2_defconfig fails with > > ERROR: "read_current_timer" [crypto/tcrypt.ko] undefined! [...] > arch/arm/lib/delay.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/arch/arm/lib/delay.c b/arch/arm/lib/delay.c > index 9d0a300..0dc5385 100644 > --- a/arch/arm/lib/delay.c > +++ b/arch/arm/lib/delay.c > @@ -45,6 +45,7 @@ int read_current_timer(unsigned long *timer_val) > *timer_val = delay_timer->read_current_timer(); > return 0; > } > +EXPORT_SYMBOL_GPL(read_current_timer); Perhaps this fits better in armksyms.c? That way it lives with arm_delay_ops and friends. I've got a patch doing it like that, which I can put in Russell's patch-system, unless you prefer doing it in delay.c for any reason? Jonny (Here's the original patch sent to the kernel-janitors list and Will Deacon) -------8<--------- On ARM, get_cycles() is implemented in terms of read_current_timer(), but the latter is not exported to modules, resulting in failure to link: ERROR: "read_current_timer" [fs/ext4/ext4.ko] undefined! This patch exports the symbol as required. Reported-by: Fengguang Wu Acked-by: Will Deacon Signed-off-by: Jonathan Austin --- arch/arm/kernel/armksyms.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/arch/arm/kernel/armksyms.c b/arch/arm/kernel/armksyms.c index 60d3b73..6a37f8d 100644 --- a/arch/arm/kernel/armksyms.c +++ b/arch/arm/kernel/armksyms.c @@ -50,6 +50,7 @@ extern void fpundefinstr(void); /* platform dependent support */ EXPORT_SYMBOL(arm_delay_ops); +EXPORT_SYMBOL(read_current_timer); /* networking */ EXPORT_SYMBOL(csum_partial);