Re: [PATCH] devexit fixes in i82092.c

Keith Owens (kaos@ocs.com.au)
Sat, 16 Mar 2002 20:50:22 +1100


On Sat, 16 Mar 2002 00:13:21 -0800 (PST),
Linus Torvalds <torvalds@transmeta.com> wrote:
>On Sat, 16 Mar 2002, Keith Owens wrote:
>>
>> Does that mean that we also get rid of the initcall methods? If
>> shutdown follows a device tree then startup should also use that tree.
>
>You cannot _build_ the tree without the initcall methods - it's populating
>the tree that the initcalls mostly do, after all.

Confusion of names. I read 'device tree' and thought you were talking
about an initialization tree that was built from PCI and USB data,
independent of kernel link order. If your 'device tree' is just the
existing initcall list derived from $(obj-y) then I agree that we
should bot have separate shutdown functions. module_exit should be
retained for objects that are built into the kernel and the shutdown
code should run the module_exit functions in reverse order to
initialization.

The question of separating register and probe is independent of the
above. It is definitely a good idea to separate register and probe, if
only to avoid all the existing races on module unload (using
__this_module and mod_inc_count everywhere in mainline code is not a
perfect solution).

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