* drivers/base/core.c broken for non-CONFIG_HOTPLUG
@ 2007-07-20 7:01 Robert Schwebel
2007-07-20 7:10 ` Greg KH
2007-07-20 7:59 ` Andrew Morton
0 siblings, 2 replies; 5+ messages in thread
From: Robert Schwebel @ 2007-07-20 7:01 UTC (permalink / raw)
To: Kay Sievers; +Cc: Greg Kroah-Hartman, linux-kernel
Kay,
With commit 60a96a59569bab85571d0089682109bd3324e896, you broke
drivers/base/core.c for systems which have not enabled CONFIG_HOTPLUG.
You add and use
extern const char *kobject_actions[];
but the code in lib/kobject_uevent.c who actually brings in the code is
only compiled when CONFIG_HOTPLUG is enabled.
Please send a fix.
Robert
--
Dipl.-Ing. Robert Schwebel | http://www.pengutronix.de
Pengutronix - Linux Solutions for Science and Industry
Handelsregister: Amtsgericht Hildesheim, HRA 2686
Hannoversche Str. 2, 31134 Hildesheim, Germany
Phone: +49-5121-206917-0 | Fax: +49-5121-206917-9
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: drivers/base/core.c broken for non-CONFIG_HOTPLUG
2007-07-20 7:01 drivers/base/core.c broken for non-CONFIG_HOTPLUG Robert Schwebel
@ 2007-07-20 7:10 ` Greg KH
2007-07-20 7:59 ` Andrew Morton
1 sibling, 0 replies; 5+ messages in thread
From: Greg KH @ 2007-07-20 7:10 UTC (permalink / raw)
To: Robert Schwebel; +Cc: Kay Sievers, linux-kernel
On Fri, Jul 20, 2007 at 09:01:06AM +0200, Robert Schwebel wrote:
> Kay,
>
> With commit 60a96a59569bab85571d0089682109bd3324e896, you broke
> drivers/base/core.c for systems which have not enabled CONFIG_HOTPLUG.
>
> You add and use
>
> extern const char *kobject_actions[];
>
> but the code in lib/kobject_uevent.c who actually brings in the code is
> only compiled when CONFIG_HOTPLUG is enabled.
>
> Please send a fix.
Already known and reported, see lkml :)
Kay is at GUADEC right now and will provide a patch in a day or so,
unless I beat him to it...
thanks,
greg k-h
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: drivers/base/core.c broken for non-CONFIG_HOTPLUG
2007-07-20 7:01 drivers/base/core.c broken for non-CONFIG_HOTPLUG Robert Schwebel
2007-07-20 7:10 ` Greg KH
@ 2007-07-20 7:59 ` Andrew Morton
2007-07-20 12:06 ` Kay Sievers
1 sibling, 1 reply; 5+ messages in thread
From: Andrew Morton @ 2007-07-20 7:59 UTC (permalink / raw)
To: Robert Schwebel; +Cc: Kay Sievers, Greg Kroah-Hartman, linux-kernel
On Fri, 20 Jul 2007 09:01:06 +0200 Robert Schwebel <r.schwebel@pengutronix.de> wrote:
> You add and use
>
> extern const char *kobject_actions[];
Added it in a .c file, too. Even checkpatch.pl knows that
was wrong.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: drivers/base/core.c broken for non-CONFIG_HOTPLUG
2007-07-20 7:59 ` Andrew Morton
@ 2007-07-20 12:06 ` Kay Sievers
2007-07-20 16:30 ` Andrew Morton
0 siblings, 1 reply; 5+ messages in thread
From: Kay Sievers @ 2007-07-20 12:06 UTC (permalink / raw)
To: Andrew Morton; +Cc: Robert Schwebel, Greg Kroah-Hartman, linux-kernel
On Fri, 2007-07-20 at 00:59 -0700, Andrew Morton wrote:
> On Fri, 20 Jul 2007 09:01:06 +0200 Robert Schwebel <r.schwebel@pengutronix.de> wrote:
>
> > You add and use
> >
> > extern const char *kobject_actions[];
>
> Added it in a .c file, too. Even checkpatch.pl knows that
> was wrong.
The kernel is doing that all over the place for global symbols that are
not meant to be used out of a "private" context or where a "private"
header file of a subsystem doesn't exist.
I can change that, if this isn't the way to do it?
Thanks,
Kay
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: drivers/base/core.c broken for non-CONFIG_HOTPLUG
2007-07-20 12:06 ` Kay Sievers
@ 2007-07-20 16:30 ` Andrew Morton
0 siblings, 0 replies; 5+ messages in thread
From: Andrew Morton @ 2007-07-20 16:30 UTC (permalink / raw)
To: Kay Sievers; +Cc: Robert Schwebel, Greg Kroah-Hartman, linux-kernel
On Fri, 20 Jul 2007 14:06:19 +0200 Kay Sievers <kay.sievers@vrfy.org> wrote:
> On Fri, 2007-07-20 at 00:59 -0700, Andrew Morton wrote:
> > On Fri, 20 Jul 2007 09:01:06 +0200 Robert Schwebel <r.schwebel@pengutronix.de> wrote:
> >
> > > You add and use
> > >
> > > extern const char *kobject_actions[];
> >
> > Added it in a .c file, too. Even checkpatch.pl knows that
> > was wrong.
>
> The kernel is doing that all over the place for global symbols that are
> not meant to be used out of a "private" context or where a "private"
> header file of a subsystem doesn't exist.
Whatever the reason, it's still wrong, because the problem remains: lack of
typechecking between the definition and its users.
It's defensible in one situation: where the definition is in assembly
language. And even then the symbol can be declared in a header, if only
because a second user may be added.
> I can change that, if this isn't the way to do it?
Please. Let's find a reasonably-relevant header for it. If there isn't
one, let's add it; there are quite possibly other things which should be in
that header so choose with care, with that possibility in mind.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2007-07-20 16:30 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-20 7:01 drivers/base/core.c broken for non-CONFIG_HOTPLUG Robert Schwebel
2007-07-20 7:10 ` Greg KH
2007-07-20 7:59 ` Andrew Morton
2007-07-20 12:06 ` Kay Sievers
2007-07-20 16:30 ` Andrew Morton
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).