enable the support of the Intel's E1000 NIC
This commit is contained in:
parent
947d77c775
commit
31949d82d1
1 changed files with 10 additions and 4 deletions
|
@ -43,6 +43,7 @@
|
||||||
#include <netif/etharp.h>
|
#include <netif/etharp.h>
|
||||||
#endif
|
#endif
|
||||||
#include <net/rtl8139.h>
|
#include <net/rtl8139.h>
|
||||||
|
#include <net/e1000.h>
|
||||||
#include <net/rckemac.h>
|
#include <net/rckemac.h>
|
||||||
#include <net/mmnif.h>
|
#include <net/mmnif.h>
|
||||||
#ifdef CONFIG_ROCKCREEK
|
#ifdef CONFIG_ROCKCREEK
|
||||||
|
@ -161,10 +162,15 @@ static int init_netifs(void)
|
||||||
netif_add(&default_netif, &ipaddr, &netmask, &gw, NULL, rtl8139if_init, ethernet_input);
|
netif_add(&default_netif, &ipaddr, &netmask, &gw, NULL, rtl8139if_init, ethernet_input);
|
||||||
netif_set_default(&default_netif);
|
netif_set_default(&default_netif);
|
||||||
#else
|
#else
|
||||||
if ((err = netifapi_netif_add(&default_netif, &ipaddr, &netmask, &gw, NULL, rtl8139if_init, tcpip_input)) != ERR_OK) {
|
if ((err = netifapi_netif_add(&default_netif, &ipaddr, &netmask, &gw, NULL, rtl8139if_init, tcpip_input)) == ERR_OK)
|
||||||
kprintf("Unable to add the network interface: err = %d\n", err);
|
goto success;
|
||||||
return -ENODEV;
|
if ((err = netifapi_netif_add(&default_netif, &ipaddr, &netmask, &gw, NULL, e1000if_init, tcpip_input)) == ERR_OK)
|
||||||
}
|
goto success;
|
||||||
|
|
||||||
|
kprintf("Unable to add the network interface: err = %d\n", err);
|
||||||
|
return -ENODEV;
|
||||||
|
|
||||||
|
success:
|
||||||
netifapi_netif_set_default(&default_netif);
|
netifapi_netif_set_default(&default_netif);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue