Code base of 2.6.18
>
> 1) But where do i look to find how the kernel loads(ie. calls the fn exported
> by module_init(XXXX)) for modules compiled into the kernel.
linux/init.h:
#ifndef MODULE
...
#define module_init(x) __initcall(x);
#define __initcall(fn) device_initcall(fn)
#define device_initcall(fn) __define_initcall("6",fn)
#define __define_initcall(level,fn) \
static initcall_t __initcall_##fn __attribute_used__ \
__attribute__((__section__(".initcall" level ".init"))) = fn
...
#endif
So as you can see call to module_init is actually an initcall.
initcalls are processed in do_initcalls function in init/main.c
static void __init do_basic_setup(void)
{
....
do_initcalls();
}
>
> thanks !
Amol
>
>
>
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-embedded" in
> the body of a message to [EMAIL PROTECTED]
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
--
To unsubscribe from this list: send the line "unsubscribe linux-embedded" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html