This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: Re: Re: how to build a driver to a single library
- From: Andrew Lunn <andrew at lunn dot ch>
- To: Tianjun-zdk <Tianjun at zcom dot unimis dot com>
- Cc: "ecos-discuss at sources dot redhat dot com" <ecos-discuss at sources dot redhat dot com>
- Date: Tue, 19 Jul 2005 11:55:57 +0200
- Subject: Re: Re: Re: [ECOS] how to build a driver to a single library
- References: <NETWEB05z5Z0TPXj7dM0000d402@netweb05.net.unimis>
On Tue, Jul 19, 2005 at 03:29:49PM +0800, Tianjun-zdk wrote:
> Hi, Andrew Lunn
>
> I have do that following your advice.
> but it seems the driver is nerver be loaded to run.
>
> i do these in my ethernet driver:
>
> NETDEVTAB_ENTRY (if_dtest_netdev,
> "if_dtest",
> if_dtest_init,
> &if_dtest_sc);
>
> extern cyg_netdevtab_entry_t *if_dtest_netdev_ex = &if_dtest_netdev;
No, that it not what i said. If you don't use if_dtest_netdev_ex in
your program the linker will throw it away. If it throws it away it
will also throw away if_dtest_netdev.
Try
extern cyg_netdevtab_entry_t if_dtest_netdev;
if_dtest_netdev = if_dtest_netdev;
Andrew
--
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss