Add E1000 PIC NIC driver from Yu Qiang
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3638 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
parent
d2737a383c
commit
56a4432633
|
@ -85,6 +85,7 @@ void up_initialize(void)
|
||||||
extern pidhash_t g_pidhash[];
|
extern pidhash_t g_pidhash[];
|
||||||
extern void up_register_bridges(void);
|
extern void up_register_bridges(void);
|
||||||
extern void vnet_initialize(void);
|
extern void vnet_initialize(void);
|
||||||
|
extern void e1000_mod_init(void);
|
||||||
|
|
||||||
// intialize the current_task to g_idletcb
|
// intialize the current_task to g_idletcb
|
||||||
current_task = g_pidhash[PIDHASH(0)].tcb;
|
current_task = g_pidhash[PIDHASH(0)].tcb;
|
||||||
|
@ -92,12 +93,19 @@ void up_initialize(void)
|
||||||
// setup console
|
// setup console
|
||||||
up_register_bridges();
|
up_register_bridges();
|
||||||
|
|
||||||
// setup net device
|
#ifdef CONFIG_NET_VNET
|
||||||
|
// setup vnet device
|
||||||
vnet_initialize();
|
vnet_initialize();
|
||||||
|
#endif
|
||||||
|
|
||||||
// setup COM device
|
// setup COM device
|
||||||
up_serialinit();
|
up_serialinit();
|
||||||
|
|
||||||
|
#ifdef CONFIG_NET_E1000
|
||||||
|
// setup e1000
|
||||||
|
e1000_mod_init();
|
||||||
|
#endif
|
||||||
|
|
||||||
// enable interrupt
|
// enable interrupt
|
||||||
sti();
|
sti();
|
||||||
}
|
}
|
||||||
|
|
|
@ -154,4 +154,19 @@ int rtos_sem_down(void *sem)
|
||||||
return sem_wait(sem);
|
return sem_wait(sem);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void rtos_stop_running(void)
|
||||||
|
{
|
||||||
|
extern void e1000_mod_exit(void);
|
||||||
|
|
||||||
|
cli();
|
||||||
|
|
||||||
|
#ifdef CONFIG_NET_E1000
|
||||||
|
e1000_mod_exit();
|
||||||
|
#endif
|
||||||
|
|
||||||
|
while(1) {
|
||||||
|
asm volatile("hlt");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue