From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757350AbZBSHcf (ORCPT ); Thu, 19 Feb 2009 02:32:35 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755277AbZBSHcN (ORCPT ); Thu, 19 Feb 2009 02:32:13 -0500 Received: from ns2.suse.de ([195.135.220.15]:38578 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753086AbZBSHcM (ORCPT ); Thu, 19 Feb 2009 02:32:12 -0500 Date: Thu, 19 Feb 2009 08:32:09 +0100 Message-ID: From: Takashi Iwai To: Randy Dunlap Cc: Ingo Molnar , Stephen Rothwell , linux-next@vger.kernel.org, LKML , Rusty Russell Subject: Re: [PATCH v2] module: fix build for CONFIG_SYSFS=n In-Reply-To: <499C54E8.7060004@oracle.com> References: <20090218191640.0b023029.sfr@canb.auug.org.au> <499C4D35.9000104@oracle.com> <20090218180932.GC19995@elte.hu> <499C54E8.7060004@oracle.com> User-Agent: Wanderlust/2.12.0 (Your Wildest Dreams) SEMI/1.14.6 (Maruoka) FLIM/1.14.7 (=?ISO-8859-4?Q?Sanj=F2?=) APEL/10.6 Emacs/22.3 (x86_64-suse-linux-gnu) MULE/5.0 (SAKAKI) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org At Wed, 18 Feb 2009 10:35:20 -0800, Randy Dunlap wrote: > > > Is destroy_params() dependent on SYSFS? If yes then it would be > > Yes. > > > far cleaner if there was a NOP destroy_params() inline for the > > !SYSFS case. > > > > > From: Randy Dunlap > > Fix this build error when CONFIG_SYSFS=n: > > kernel/built-in.o: In function `free_module': > module.c:(.text+0x4f8a2): undefined reference to `destroy_params' > > Signed-off-by: Randy Dunlap > cc: Rusty Russell > --- > kernel/params.c | 6 ++++++ > 1 file changed, 6 insertions(+) > > --- linux-next-20090218.orig/kernel/params.c > +++ linux-next-20090218/kernel/params.c > @@ -761,6 +761,12 @@ static int __init param_sysfs_init(void) > } > subsys_initcall(param_sysfs_init); > > +#else /* !CONFIG_SYSFS */ > + > +inline void destroy_params(const struct kernel_param *params, unsigned num) > +{ > +} Just wondering whether any need to be (external) inline at this place, supposing it just to be called from other files. If inlining, isn't it better in include/linux/moduleparam.h? thanks, Takashi