diff options
author | Michael Brown | 2007-01-10 02:55:07 +0100 |
---|---|---|
committer | Michael Brown | 2007-01-10 02:55:07 +0100 |
commit | d24b80acf292266680d9b04836269734602ec054 (patch) | |
tree | 88d98a1ab29bd0dc0043e2f13ef1d17b74656084 /src/net/netdevice.c | |
parent | Add "name" field to network device, to facilitate netdev commands. (diff) | |
download | ipxe-d24b80acf292266680d9b04836269734602ec054.tar.gz ipxe-d24b80acf292266680d9b04836269734602ec054.tar.xz ipxe-d24b80acf292266680d9b04836269734602ec054.zip |
Added network interface management commands
Diffstat (limited to 'src/net/netdevice.c')
-rw-r--r-- | src/net/netdevice.c | 22 |
1 files changed, 1 insertions, 21 deletions
diff --git a/src/net/netdevice.c b/src/net/netdevice.c index f3b76a76..8c95afd6 100644 --- a/src/net/netdevice.c +++ b/src/net/netdevice.c @@ -40,7 +40,7 @@ static struct net_protocol net_protocols[0] __table_start ( net_protocols ); static struct net_protocol net_protocols_end[0] __table_end ( net_protocols ); /** List of network devices */ -static LIST_HEAD ( net_devices ); +struct list_head net_devices = LIST_HEAD_INIT ( net_devices ); /** * Transmit raw packet via network device @@ -310,26 +310,6 @@ struct net_device * find_netdev ( const char *name ) { } /** - * Iterate through network devices - * - * @ret netdev Network device, or NULL - * - * This returns the registered network devices in the order of - * registration. If no network devices are registered, it will return - * NULL. - */ -struct net_device * next_netdev ( void ) { - struct net_device *netdev; - - list_for_each_entry ( netdev, &net_devices, list ) { - list_del ( &netdev->list ); - list_add_tail ( &netdev->list, &net_devices ); - return netdev; - } - return NULL; -} - -/** * Transmit network-layer packet * * @v pkb Packet buffer |