From: Rusty Russell <rusty@rustcorp.com.au>
To: Andy Lutomirski <luto@amacapital.net>, linux-kernel@vger.kernel.org
Cc: Andy Lutomirski <luto@amacapital.net>
Subject: Re: [RFC PATCH] Allow optional module parameters
Date: Fri, 15 Mar 2013 15:33:32 +1030 [thread overview]
Message-ID: <87ehfhtftn.fsf@rustcorp.com.au> (raw)
In-Reply-To: <b6b1676fd5bcd6b0ef47b0e0a1c26b1c05684135.1363291511.git.luto@amacapital.net>
Andy Lutomirski <luto@amacapital.net> writes:
> Current parameter behavior is odd. Boot parameters that have values
> and don't match anything become environment variables, with no
> warning. Boot parameters without values that don't match anything
> go into argv_init. Everything goes into /proc/cmdline.
>
> The init_module and finit_module syscalls, however, are strict:
> parameters that don't match result in -ENOENT.
>
> kmod (and hence modprobe), when loading a module called foo, look in
> /proc/cmdline for foo.x or foo.x=y, strip off the foo., and pass the
> rest to init_module.
>
> The upshot is that booting with module.nonexistent_parameter=1 is
> okay if module is built in or missing entirely but prevents module
> from loading if it's an actual module. Similarly, option module
> nonexistent_parameter=1 in /etc/modprobe.d prevents the module from
> loading the parameter goes away. This means that removing module
> parameters unnecessarily breaks things.
Err, yes. Don't remove module parameters, they're part of the API. Do
you have a particular example?
> With this patch, module parameters can be made explicitly optional.
> This approach is IMO silly, but it's unlikely to break anything,
> since I doubt that anyone needs init parameters or init environment
> variables that end in a tilde.
It's silly for the removal problem: that should be handled in the
kernel. How would the poor user know that the option is going away?
So how about we add a module_param_obsolete(name) macro?
If a parameter were introduced, and the user wanted to specify it *if*
it was supported, that might justify this approach rather than using
complex install commands. But I don't believe that's common, is it?
Thanks,
Rusty.
next prev parent reply other threads:[~2013-03-15 5:04 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-14 20:07 Andy Lutomirski
2013-03-15 5:03 ` Rusty Russell [this message]
2013-03-15 18:18 ` Andy Lutomirski
2013-03-18 2:24 ` Rusty Russell
2013-03-18 17:42 ` Andy Lutomirski
2013-03-19 2:32 ` Rusty Russell
2013-03-19 19:40 ` Ben Hutchings
2013-03-20 2:31 ` Rusty Russell
2013-03-20 0:26 ` Lucas De Marchi
2013-03-20 0:32 ` Andy Lutomirski
2013-03-20 0:36 ` Andy Lutomirski
2013-03-20 3:45 ` Rusty Russell
2013-07-01 6:50 ` Rusty Russell
2013-07-01 16:33 ` Jonathan Masters
2013-07-03 0:28 ` Rusty Russell
2013-07-03 21:03 ` Michal Marek
2013-07-03 21:17 ` Andy Lutomirski
2013-07-03 21:23 ` Michal Marek
2013-07-03 21:30 ` Yann E. MORIN
2013-07-03 21:31 ` Lucas De Marchi
2013-07-03 21:36 ` Andy Lutomirski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87ehfhtftn.fsf@rustcorp.com.au \
--to=rusty@rustcorp.com.au \
--cc=linux-kernel@vger.kernel.org \
--cc=luto@amacapital.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome