This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: What is RedBoot_INIT_TAB,
- To: "Narayana, Venkat A." <NarayVA at nsc-msg01 dot network dot com>
- Subject: Re: [ECOS] What is RedBoot_INIT_TAB,
- From: Jonathan Larmour <jlarmour at redhat dot com>
- Date: Thu, 21 Jun 2001 20:02:18 +0100
- Cc: 'Gary Thomas' <gthomas at cambridge dot redhat dot com>,"'ecos-discuss at sources dot redhat dot com'" <ecos-discuss at sources dot redhat dot com>
- Organization: Red Hat UK Ltd.
- References: <A7E1C26945C8D211ADBF0008C709661A02A48849@nsc-msg02.network.com>
"Narayana, Venkat A." wrote:
>
> Hi Gary,
>
> > >
> > > for (init_entry = __RedBoot_INIT_TAB__; init_entry !=
> > > &__RedBoot_INIT_TAB_END__; init_entry++) {
> > > (*init_entry->fun)();
> > > }
> > >
> > > I found that RedBoot_INIT_TAB is defined, in
> >
> > This table is filled in using the RedBoot_init() macro. E.g.
> > this is used
> > by the network initialization code in the file
> > "redboot/current/src/net/net_io.c"
> >
> > Depending on your configuration, you may or not have any
> > entries in the table.
>
> RedBoot_init macro, defines 'struct init_tab_entry' variable in
> 'ecos.table' section. Pls correct me here...my understanding is that
> RedBoot_init(net_init, RedBoot_INIT_LAST) expands into
> "struct init_tab_entry _init_tab_9999net_init", where this struct
> has 1 member, which is a function ptr.
> I am going thru the redboot/src/net files, but i am unable to find
> any place, from where _init_tab_9999net_init->net_init is called.
> i.e, who calls net_init and from where?
It gets put in a special section (courtesy of the HAL table magic), which
is iterated through on line 226 of redboot's main.c.
Jifl
--
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine
Come to the Red Hat TechWorld open source conference in Brussels!
Keynotes, techie talks and exhibitions http://www.redhat-techworld.com/