[lkml]   [1999]   [May]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [RFC] Unifying kernel initialization
>On Tue, May 04, 1999 at 08:42:18PM +0200, Andi Kleen wrote:
>> >macro REGISTER_INIT_FUNC(function,priority),
>> >which would add the nessesary info to the
>> >object file. Then, the kernel would need only
>> >to loop over this list and all the kernel would
>> >be initialized in order.
>> I 100% agree. It could be easily implemented using a special
>> ELF section. Afaik there are already plans to do it in 2.3.
>> BTW, the ELF section trick could be used for sysctls too,
>> like FreeBSD does. This would remove another ugly initialization
>> call.=20
>Let me throw in another idea:
>I would like to register the module upon initialization by init/main.c just
>as modules are registered by their name and reported by /proc/modules. This
>would allow for something like /proc/components to report all statically
>linked kernel parts.=20
>Upon insertion of a module by insmod, we would check both lists, whether the
>module is already there and preventing it from being loaded twice (maybe
>modules where it is allowed can set a flag to prevent this).
>This would also solve some issues with modules being inserted in spite of
>static code being compiled into the kernel.=20
>[Try it with scsi_mod, but sync and remount ro before.]

There are several modules that need the capacibility to be loaded more
than one time to create multiple instances of itself, e.g. the shaper
and dummy.o


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:51    [from the cache]
©2003-2014 Jasper Spaans. hosted at Digital Ocean