From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S261319AbUK1WpL (ORCPT ); Sun, 28 Nov 2004 17:45:11 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S261156AbUK1WpK (ORCPT ); Sun, 28 Nov 2004 17:45:10 -0500 Received: from ozlabs.org ([203.10.76.45]:57021 "EHLO ozlabs.org") by vger.kernel.org with ESMTP id S261596AbUK1Wm0 (ORCPT ); Sun, 28 Nov 2004 17:42:26 -0500 Subject: Re: EXPORT_SYMBOL_NOVERS question From: Rusty Russell To: vlobanov Cc: lkml - Kernel Mailing List , Andrew Morton , lethal@linux-sh.org, kkojima@rr.iij4u.or.jp In-Reply-To: References: Content-Type: text/plain Date: Mon, 29 Nov 2004 09:42:20 +1100 Message-Id: <1101681740.25347.21.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.0.2 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2004-11-03 at 00:10 -0800, vlobanov wrote: > Hi, > > I was looking over the /include/linux/module.h file, and the > EXPORT_SYMBOL_NOVERS macro caught my eye. To quote the source: > > /* We don't mangle the actual symbol anymore, so no need for > * special casing EXPORT_SYMBOL_NOVERS. FIXME: Deprecated */ > #define EXPORT_SYMBOL_NOVERS(sym) EXPORT_SYMBOL(sym) > > A quick grep through the tree brought up no usage cases for this macro. > Is there any reason to keep it around, instead of cutting it out, as the > FIXME comment seems to suggest? Yep, it's time. Rusty. Name: Remove EXPORT_SYMBOL_NOVERS Status: Trivial Signed-off-by: Rusty Russell Vadim Lobanov points out that EXPORT_SYMBOL_NOVERS is no longer used; in fact, SH still uses it, but once we fix that, the kernel is clean. Remove it. Index: linux-2.6.10-rc2-bk11-Module/arch/sh/kernel/sh_ksyms.c =================================================================== --- linux-2.6.10-rc2-bk11-Module.orig/arch/sh/kernel/sh_ksyms.c 2004-11-16 15:29:12.000000000 +1100 +++ linux-2.6.10-rc2-bk11-Module/arch/sh/kernel/sh_ksyms.c 2004-11-29 09:38:48.007889896 +1100 @@ -89,7 +89,7 @@ EXPORT_SYMBOL(__div64_32); -#define DECLARE_EXPORT(name) extern void name(void);EXPORT_SYMBOL_NOVERS(name) +#define DECLARE_EXPORT(name) extern void name(void);EXPORT_SYMBOL(name) /* These symbols are generated by the compiler itself */ DECLARE_EXPORT(__udivsi3); @@ -100,7 +100,7 @@ DECLARE_EXPORT(__lshrdi3); DECLARE_EXPORT(__movstr); -EXPORT_SYMBOL_NOVERS(strcpy); +EXPORT_SYMBOL(strcpy); #ifdef CONFIG_CPU_SH4 DECLARE_EXPORT(__movstr_i4_even); Index: linux-2.6.10-rc2-bk11-Module/Makefile =================================================================== --- linux-2.6.10-rc2-bk11-Module.orig/Makefile 2004-11-29 07:48:40.000000000 +1100 +++ linux-2.6.10-rc2-bk11-Module/Makefile 2004-11-29 09:39:06.146132464 +1100 @@ -1166,7 +1166,7 @@ quiet_cmd_tags = MAKE $@ define cmd_tags rm -f $@; \ - CTAGSF=`ctags --version | grep -i exuberant >/dev/null && echo "-I __initdata,__exitdata,EXPORT_SYMBOL,EXPORT_SYMBOL_NOVERS"`; \ + CTAGSF=`ctags --version | grep -i exuberant >/dev/null && echo "-I __initdata,__exitdata,EXPORT_SYMBOL,EXPORT_SYMBOL_GPL"`; \ $(all-sources) | xargs ctags $$CTAGSF -a endef Index: linux-2.6.10-rc2-bk11-Module/include/linux/module.h =================================================================== --- linux-2.6.10-rc2-bk11-Module.orig/include/linux/module.h 2004-11-29 07:48:57.000000000 +1100 +++ linux-2.6.10-rc2-bk11-Module/include/linux/module.h 2004-11-29 09:39:31.970206608 +1100 @@ -206,10 +206,6 @@ #endif -/* We don't mangle the actual symbol anymore, so no need for - * special casing EXPORT_SYMBOL_NOVERS. FIXME: Deprecated */ -#define EXPORT_SYMBOL_NOVERS(sym) EXPORT_SYMBOL(sym) - struct module_ref { local_t count; @@ -449,7 +445,6 @@ #else /* !CONFIG_MODULES... */ #define EXPORT_SYMBOL(sym) #define EXPORT_SYMBOL_GPL(sym) -#define EXPORT_SYMBOL_NOVERS(sym) /* Given an address, look for it in the exception tables. */ static inline const struct exception_table_entry * -- A bad analogy is like a leaky screwdriver -- Richard Braakman