Re: [PATCH v2 -mm 8/9] netconsole: Support multiple logging targets

Satyam Sharma
2007-07-11T06:34:29Z

Hi Joel,

On Tue, 10 Jul 2007, Joel Becker wrote:
> On Wed, Jul 11, 2007 at 03:47:09AM +0530, Satyam Sharma wrote:
> > Hmm, I put it in there because I expected that the user must have had
> > at least one target configured (added to target_list) if he's got the
> > module loaded/built-in (and netconsole registered), which is when this
> > function would be triggered anyway.
>
> Loading the module won't happen without a config,

That's no longer the case (doesn't need to be enforced actually) now
with being able to add logging targets _after_ the module has loaded
and initialized / registered itself. It's plausible a user may simply
want to load netconsole without any "netconsole=" option, and then
specify/add targets later -- this wasn't possible previously, of course.

> but there's no
> requirement that a built-in netconsole has a kernel command-line
> argument.

The above is applicable for the built-in case too, with
CONFIG_NETCONSOLE_DYNAMIC. So now built-in netconsole will initialize
(configfs subsystem, etc) and register itself (register_console) even
if no "netconsole=" was provided, again for the same reason.

And I now notice that CONFIG_NETCONSOLE=y in the defconfig's of
most arch's. So I think I did get the common case wrong there ...
ok, I'll get rid of the unlikely() in that case.

Satyam