* xx_initcall ( ) in kernel
@ 2011-07-13 10:42 sumeet linux
2011-07-13 11:09 ` nilesh
0 siblings, 1 reply; 3+ messages in thread
From: sumeet linux @ 2011-07-13 10:42 UTC (permalink / raw)
To: kernelnewbies
Dear friends,
I want to know the basics xx_initcall ( ) in linux kernel. How this function
works ?
Observed in kernel code, many places late_initcall ( ), early_initcall ( ),
arch_initcall ( ), core_initcall ( ) gets called.
When did all these functions gets call during kernel initialization ?
I am more interested in what is the sequence of these functions gets called
one after another.
Thank you.
Regards,
Sumeet
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20110713/84ce10f6/attachment.html
^ permalink raw reply [flat|nested] 3+ messages in thread
* xx_initcall ( ) in kernel
2011-07-13 10:42 xx_initcall ( ) in kernel sumeet linux
@ 2011-07-13 11:09 ` nilesh
2011-08-08 16:09 ` subin gangadharan
0 siblings, 1 reply; 3+ messages in thread
From: nilesh @ 2011-07-13 11:09 UTC (permalink / raw)
To: kernelnewbies
Hi Sumeet,
On Wednesday 13 July 2011 04:12 PM, sumeet linux wrote:
> Dear friends,
>
> I want to know the basics xx_initcall ( ) in linux kernel. How this function
> works ?
> Observed in kernel code, many places late_initcall ( ), early_initcall ( ),
> arch_initcall ( ), core_initcall ( ) gets called.
> When did all these functions gets call during kernel initialization ?
> I am more interested in what is the sequence of these functions gets called
> one after another.
I could get a nice link explaining about *_initcall(). Refer:
http://book.opensourceproject.org.cn/embedded/embeddedprime/opensource/0136130550/ch05lev1sec4.html
*_initcall() are macros which set the function pointers for subsystem
initialization (typedef int (*initcall_t)(void) : typedef of all such
function pointers).
Also if we look at the source code, the functions are called in below
sequence:
http://lxr.linux.no/#linux+v2.6.39/init/main.c#L695
do_basic_setup(void) -> do_initcalls(void) -> do_one_initcall(*fn);
do_one_initcall(*fn) - calls each function. And do_basic_setup() is
called inside the initialization sequence (kernel_init()).
>
> Thank you.
>
> Regards,
> Sumeet
>
--
Thanks,
Nilesh
^ permalink raw reply [flat|nested] 3+ messages in thread
* xx_initcall ( ) in kernel
2011-07-13 11:09 ` nilesh
@ 2011-08-08 16:09 ` subin gangadharan
0 siblings, 0 replies; 3+ messages in thread
From: subin gangadharan @ 2011-08-08 16:09 UTC (permalink / raw)
To: kernelnewbies
On Wed, Jul 13, 2011 at 4:09 AM, nilesh <nilesh.tayade@netscout.com> wrote:
> Hi Sumeet,
>
> On Wednesday 13 July 2011 04:12 PM, sumeet linux wrote:
> > Dear friends,
> >
> > I want to know the basics xx_initcall ( ) in linux kernel. How this
> function
> > works ?
> > Observed in kernel code, many places late_initcall ( ), early_initcall (
> ),
> > arch_initcall ( ), core_initcall ( ) gets called.
> > When did all these functions gets call during kernel initialization ?
> > I am more interested in what is the sequence of these functions gets
> called
> > one after another.
> I could get a nice link explaining about *_initcall(). Refer:
>
> http://book.opensourceproject.org.cn/embedded/embeddedprime/opensource/0136130550/ch05lev1sec4.html
>
> *_initcall() are macros which set the function pointers for subsystem
> initialization (typedef int (*initcall_t)(void) : typedef of all such
> function pointers).
> Also if we look at the source code, the functions are called in below
> sequence:
> http://lxr.linux.no/#linux+v2.6.39/init/main.c#L695
>
> do_basic_setup(void) -> do_initcalls(void) -> do_one_initcall(*fn);
> do_one_initcall(*fn) - calls each function. And do_basic_setup() is
> called inside the initialization sequence (kernel_init()).
>
> >
> > Thank you.
> >
> > Regards,
> > Sumeet
> >
>
> --
> Thanks,
> Nilesh
>
> _______________________________________________
> Kernelnewbies mailing list
> Kernelnewbies at kernelnewbies.org
> http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
>
Hi,
I hope this will help you to get a basic understanding of init call.
http://www.embedded-bits.co.uk/2008/init-call-mechanism/
--
With Regards
Subin Gangadharan
Everything should be made as simple as possible,but not simpler.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.kernelnewbies.org/pipermail/kernelnewbies/attachments/20110808/439e0978/attachment.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-08-08 16:09 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-13 10:42 xx_initcall ( ) in kernel sumeet linux
2011-07-13 11:09 ` nilesh
2011-08-08 16:09 ` subin gangadharan
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.