Messages in this thread | | | From | Rusty Russell <> | Subject | Re: linux-next: rr tree build failure | Date | Mon, 24 Nov 2008 14:38:36 +1030 |
| |
On Saturday 22 November 2008 17:11:32 Greg KH wrote: > On Sat, Nov 22, 2008 at 01:01:06PM +1030, Rusty Russell wrote: > > Fair enough. Patch below does this as moduleparam.h suggests. > > > > It still means that the paremeter appears in > > /sys/module/kernel/parameters/nousb OR > > /sys/module/usbcore/parameters/nousb. > > What's the "OR" part? What determines where it goes?
Whether usbcore is a module or not, of course.
> > +/* To disable USB, kernel command line is 'nousb' not 'usbcore.nousb' */ > > +#undef MODULE_PARAM_PREFIX > > +#define MODULE_PARAM_PREFIX > > +module_param(nousb, bool, 0444); > > That undef seems hacky beyond belief.
*Exactly*. And while you're not the first person to do this, you're the one one to use it for code which can be a module :(
> How would one know to do this?
The same way Pete found __module_param_call, by reading the header:
/* You can override this manually, but generally this should match the module name. */ #ifdef MODULE #define MODULE_PARAM_PREFIX /* empty */ #else #define MODULE_PARAM_PREFIX KBUILD_MODNAME "." #endif
Cheers, Rusty.
| |