Re: [2.6 PATCH/RFC] Firmware loader fixes - take 2

From: Dmitry Torokhov
Date: Sat Dec 27 2003 - 00:32:42 EST


Hi Marcel,

On Tuesday 23 December 2003 03:48 am, Marcel Holtmann wrote:
> Hi Dmitry,
[..SKIP..]
> > I am sorry but I have to disagree with you. Kernel should not call
> > user space until it has all infrastructure in place and is ready.
> > Anything else is just a sloppy practice.
>
> The firmware.agent script has 3 extra lines to check for the visibility
> of the "loading" file and if it is not present it will sleep one
> second. This is a actual good practice compared to adding much more
> code to the kernel and have an own way of running hotplug.
>

OK, so if I understand you correctly you are against bloating the kernel by
duplicating hotplug handler, not against the basic idea that kernel should
not call userspace unless its ready. Your wish is my command!

I changed the code a bit and split it into 2 patches for easier consumption.
The first patch takes care of resource deallocation issues, the second one
deals with hotplug. Firmware hotplug now uses the standard hotplug handler
(I had to make it public) and as you can see it costs 5 extra lines of C code
(not counting one blank line) in firmware_class.c, hardly a bloat.

Dmitry
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/