Linux Kernel
3.7.1
|
#include <asm/uaccess.h>
#include <linux/bitops.h>
#include <linux/capability.h>
#include <linux/cpu.h>
#include <linux/types.h>
#include <linux/kernel.h>
#include <linux/hash.h>
#include <linux/slab.h>
#include <linux/sched.h>
#include <linux/mutex.h>
#include <linux/string.h>
#include <linux/mm.h>
#include <linux/socket.h>
#include <linux/sockios.h>
#include <linux/errno.h>
#include <linux/interrupt.h>
#include <linux/if_ether.h>
#include <linux/netdevice.h>
#include <linux/etherdevice.h>
#include <linux/ethtool.h>
#include <linux/notifier.h>
#include <linux/skbuff.h>
#include <net/net_namespace.h>
#include <net/sock.h>
#include <linux/rtnetlink.h>
#include <linux/proc_fs.h>
#include <linux/seq_file.h>
#include <linux/stat.h>
#include <net/dst.h>
#include <net/pkt_sched.h>
#include <net/checksum.h>
#include <net/xfrm.h>
#include <linux/highmem.h>
#include <linux/init.h>
#include <linux/kmod.h>
#include <linux/module.h>
#include <linux/netpoll.h>
#include <linux/rcupdate.h>
#include <linux/delay.h>
#include <net/wext.h>
#include <net/iw_handler.h>
#include <asm/current.h>
#include <linux/audit.h>
#include <linux/dmaengine.h>
#include <linux/err.h>
#include <linux/ctype.h>
#include <linux/if_arp.h>
#include <linux/if_vlan.h>
#include <linux/ip.h>
#include <net/ip.h>
#include <linux/ipv6.h>
#include <linux/in.h>
#include <linux/jhash.h>
#include <linux/random.h>
#include <trace/events/napi.h>
#include <trace/events/net.h>
#include <trace/events/skb.h>
#include <linux/pci.h>
#include <linux/inetdevice.h>
#include <linux/cpu_rmap.h>
#include <linux/net_tstamp.h>
#include <linux/static_key.h>
#include <net/flow_keys.h>
#include "net-sysfs.h"
Go to the source code of this file.
Data Structures | |
struct | dev_gso_cb |
Macros | |
#define | MAX_GRO_SKBS 8 |
#define | GRO_MAX_HEAD (MAX_HEADER + 128) |
#define | PTYPE_HASH_SIZE (16) |
#define | PTYPE_HASH_MASK (PTYPE_HASH_SIZE - 1) |
#define GRO_MAX_HEAD (MAX_HEADER + 128) |
#define net_timestamp_check | ( | COND, | |
SKB | |||
) |
#define PTYPE_HASH_MASK (PTYPE_HASH_SIZE - 1) |
int __dev_change_flags | ( | struct net_device * | dev, |
unsigned int | flags | ||
) |
|
read |
__dev_get_by_index - find a device by its ifindex : the applicable net namespace : index of device
Search for an interface by index. Returns NULL if the device is not found or a pointer to the device. The device has not had its reference counter increased so the caller must be careful about locking. The caller must hold either the RTNL semaphore or .
|
read |
void __dev_notify_flags | ( | struct net_device * | dev, |
unsigned int | old_flags | ||
) |
void __dev_remove_pack | ( | struct packet_type * | pt | ) |
__dev_remove_pack - remove packet handler : packet type declaration
Remove a protocol handler that was previously added to the kernel protocol handlers by dev_add_pack(). The passed &packet_type is removed from the kernel lists and can be freed or reused once this function returns.
The packet type might still be in use by receivers
and must not be freed until after all the CPU's have gone through a quiescent state.
void __dev_set_rx_mode | ( | struct net_device * | dev | ) |
void __napi_complete | ( | struct napi_struct * | n | ) |
void __napi_schedule | ( | struct napi_struct * | n | ) |
int __netdev_update_features | ( | struct net_device * | dev | ) |
__setup | ( | ) |
|
read |
int call_netdevice_notifiers | ( | unsigned long | val, |
struct net_device * | dev | ||
) |
call_netdevice_notifiers - call all network notifier blocks : value passed unmodified to notifier function : net_device pointer passed unmodified to notifier function
Call all network notifier blocks. Parameters and return value are as for raw_notifier_call_chain().
define_netdev_printk_level | ( | netdev_emerg | , |
KERN_EMERG | |||
) |
define_netdev_printk_level | ( | netdev_alert | , |
KERN_ALERT | |||
) |
define_netdev_printk_level | ( | netdev_crit | , |
KERN_CRIT | |||
) |
define_netdev_printk_level | ( | netdev_err | , |
KERN_ERR | |||
) |
define_netdev_printk_level | ( | netdev_warn | , |
KERN_WARNING | |||
) |
define_netdev_printk_level | ( | netdev_notice | , |
KERN_NOTICE | |||
) |
define_netdev_printk_level | ( | netdev_info | , |
KERN_INFO | |||
) |
DEFINE_PER_CPU_ALIGNED | ( | struct softnet_data | , |
softnet_data | |||
) |
DEFINE_RWLOCK | ( | dev_base_lock | ) |
void dev_add_pack | ( | struct packet_type * | pt | ) |
dev_add_pack - add packet handler : packet type declaration
Add a protocol handler to the networking stack. The passed &packet_type is linked into kernel lists and may not be freed until it has been removed from the kernel lists.
This call does not sleep therefore it can not guarantee all CPU's that are in middle of receiving packets will see the new packet type (until the next received packet).
int dev_alloc_name | ( | struct net_device * | dev, |
const char * | name | ||
) |
int dev_change_flags | ( | struct net_device * | dev, |
unsigned int | flags | ||
) |
int dev_change_name | ( | struct net_device * | dev, |
const char * | newname | ||
) |
dev_change_net_namespace - move device to different nethost namespace : device : network namespace : If not NULL name pattern to try if the current device name is already taken in the destination network namespace.
This function shuts down a device interface and moves it to a new network namespace. On success 0 is returned, on a failure a netagive errno code is returned.
Callers must hold the rtnl semaphore.
int dev_close | ( | struct net_device * | dev | ) |
void dev_disable_lro | ( | struct net_device * | dev | ) |
int dev_forward_skb | ( | struct net_device * | dev, |
struct sk_buff * | skb | ||
) |
dev_forward_skb - loopback an skb to another netif
: destination network device : buffer to forward
return values: NET_RX_SUCCESS (no congestion) NET_RX_DROP (packet was dropped, but freed)
dev_forward_skb can be used for injecting an skb from the start_xmit function of one device into the receive queue of another device.
The receiving device may be in another namespace, so we have to clear all information in the skb that could impact namespace isolation.
|
read |
dev_get_by_flags_rcu - find any device with given flags : the applicable net namespace : IFF_* values : bitmask of bits in if_flags to check
Search for any interface with the given flags. Returns NULL if a device is not found or a pointer to the device. Must be called inside rcu_read_lock(), and result refcount is unchanged.
|
read |
dev_get_by_index - find a device by its ifindex : the applicable net namespace : index of device
Search for an interface by index. Returns NULL if the device is not found or a pointer to the device. The device returned has had a reference added and the pointer is safe until the user calls dev_put to indicate they have finished with it.
|
read |
dev_get_by_index_rcu - find a device by its ifindex : the applicable net namespace : index of device
Search for an interface by index. Returns NULL if the device is not found or a pointer to the device. The device has not had its reference counter increased so the caller must be careful about locking. The caller must hold RCU lock.
unsigned int dev_get_flags | ( | const struct net_device * | dev | ) |
|
read |
dev_get_stats - get network device statistics : device to get statistics from : place to store stats
Get network statistics from device. Return . The device driver may provide its own method by setting dev->netdev_ops->get_stats64 or dev->netdev_ops->get_stats; otherwise the internal statistics structure is used.
|
read |
dev_getbyhwaddr_rcu - find a device by its hardware address : the applicable net namespace : media type of device : hardware address
Search for an interface by MAC address. Returns NULL if the device is not found or a pointer to the device. The caller must hold RCU or RTNL. The returned device has not had its ref count increased and the caller must therefore be careful about locking
|
read |
enum gro_result dev_gro_receive | ( | struct napi_struct * | napi, |
struct sk_buff * | skb | ||
) |
int dev_hard_start_xmit | ( | struct sk_buff * | skb, |
struct net_device * | dev, | ||
struct netdev_queue * | txq | ||
) |
|
read |
dev_ioctl - network device ioctl : the applicable net namespace : command to issue
Issue ioctl functions to devices. This is normally called by the user space syscall interfaces but can sometimes be useful for other purposes. The return value is the return from the syscall if positive or a negative errno code on error.
int dev_open | ( | struct net_device * | dev | ) |
dev_open - prepare an interface for use. : device to open
Takes a device from down to up state. The device's private open function is invoked and then the multicast lists are loaded. Finally the device is moved into the up state and a NETDEV_UP message is sent to the netdev notifier chain.
Calling this function on an active interface is a nop. On a failure a negative errno code is returned.
dev_queue_xmit - transmit a buffer : buffer to transmit
Queue a buffer for transmission to a network device. The caller must have set the device and priority and built the buffer before calling this function. The function can be called from an interrupt.
A negative errno code is returned on a failure. A success does not guarantee the frame will be transmitted as it may be dropped due to congestion or traffic shaping.
Regardless of the return value, the skb is consumed, so it is currently difficult to retry a send to this method. (You can bump the ref count before sending to hold a reference for retry if you are careful.)
When calling this method, interrupts MUST be enabled. This is because the BH enable code must have IRQs enabled so that it will not deadlock. –BLG
void dev_remove_pack | ( | struct packet_type * | pt | ) |
dev_remove_pack - remove packet handler : packet type declaration
Remove a protocol handler that was previously added to the kernel protocol handlers by dev_add_pack(). The passed &packet_type is removed from the kernel lists and can be freed or reused once this function returns.
This call sleeps to guarantee that no CPU is looking at the packet type after return.
int dev_set_allmulti | ( | struct net_device * | dev, |
int | inc | ||
) |
dev_set_allmulti - update allmulti count on a device : device : modifier
Add or remove reception of all multicast frames to a device. While the count in the device remains above zero the interface remains listening to all interfaces. Once it hits zero the device reverts back to normal filtering operation. A negative value is used to drop the counter when releasing a resource needing all multicasts. Return 0 if successful or a negative errno code on error.
void dev_set_group | ( | struct net_device * | dev, |
int | new_group | ||
) |
int dev_set_mac_address | ( | struct net_device * | dev, |
struct sockaddr * | sa | ||
) |
int dev_set_mtu | ( | struct net_device * | dev, |
int | new_mtu | ||
) |
int dev_set_promiscuity | ( | struct net_device * | dev, |
int | inc | ||
) |
dev_set_promiscuity - update promiscuity count on a device : device : modifier
Add or remove promiscuity from a device. While the count in the device remains above zero the interface remains promiscuous. Once it hits zero the device reverts back to normal filtering operation. A negative inc value is used to drop promiscuity on the device. Return 0 if successful or a negative errno code on error.
void dev_set_rx_mode | ( | struct net_device * | dev | ) |
EXPORT_PER_CPU_SYMBOL | ( | softnet_data | ) |
EXPORT_SYMBOL | ( | dev_base_lock | ) |
EXPORT_SYMBOL | ( | dev_add_pack | ) |
EXPORT_SYMBOL | ( | __dev_remove_pack | ) |
EXPORT_SYMBOL | ( | dev_remove_pack | ) |
EXPORT_SYMBOL | ( | netdev_boot_setup_check | ) |
EXPORT_SYMBOL | ( | __dev_get_by_name | ) |
EXPORT_SYMBOL | ( | dev_get_by_name_rcu | ) |
EXPORT_SYMBOL | ( | dev_get_by_name | ) |
EXPORT_SYMBOL | ( | __dev_get_by_index | ) |
EXPORT_SYMBOL | ( | dev_get_by_index_rcu | ) |
EXPORT_SYMBOL | ( | dev_get_by_index | ) |
EXPORT_SYMBOL | ( | dev_getbyhwaddr_rcu | ) |
EXPORT_SYMBOL | ( | __dev_getfirstbyhwtype | ) |
EXPORT_SYMBOL | ( | dev_getfirstbyhwtype | ) |
EXPORT_SYMBOL | ( | dev_get_by_flags_rcu | ) |
EXPORT_SYMBOL | ( | dev_valid_name | ) |
EXPORT_SYMBOL | ( | dev_alloc_name | ) |
EXPORT_SYMBOL | ( | netdev_features_change | ) |
EXPORT_SYMBOL | ( | netdev_state_change | ) |
EXPORT_SYMBOL | ( | netdev_notify_peers | ) |
EXPORT_SYMBOL | ( | dev_load | ) |
EXPORT_SYMBOL | ( | dev_open | ) |
EXPORT_SYMBOL | ( | dev_close | ) |
EXPORT_SYMBOL | ( | dev_disable_lro | ) |
EXPORT_SYMBOL | ( | register_netdevice_notifier | ) |
EXPORT_SYMBOL | ( | unregister_netdevice_notifier | ) |
EXPORT_SYMBOL | ( | call_netdevice_notifiers | ) |
EXPORT_SYMBOL | ( | net_enable_timestamp | ) |
EXPORT_SYMBOL | ( | net_disable_timestamp | ) |
EXPORT_SYMBOL | ( | netif_set_real_num_tx_queues | ) |
EXPORT_SYMBOL | ( | netif_get_num_default_rss_queues | ) |
EXPORT_SYMBOL | ( | __netif_schedule | ) |
EXPORT_SYMBOL | ( | dev_kfree_skb_irq | ) |
EXPORT_SYMBOL | ( | dev_kfree_skb_any | ) |
EXPORT_SYMBOL | ( | netif_device_detach | ) |
EXPORT_SYMBOL | ( | netif_device_attach | ) |
EXPORT_SYMBOL | ( | skb_checksum_help | ) |
EXPORT_SYMBOL | ( | skb_gso_segment | ) |
EXPORT_SYMBOL | ( | netif_skb_features | ) |
EXPORT_SYMBOL | ( | __skb_tx_hash | ) |
EXPORT_SYMBOL | ( | dev_loopback_xmit | ) |
EXPORT_SYMBOL | ( | dev_queue_xmit | ) |
EXPORT_SYMBOL | ( | netdev_max_backlog | ) |
EXPORT_SYMBOL | ( | __skb_get_rxhash | ) |
EXPORT_SYMBOL | ( | netif_rx | ) |
EXPORT_SYMBOL | ( | netif_rx_ni | ) |
EXPORT_SYMBOL | ( | netif_receive_skb | ) |
EXPORT_SYMBOL | ( | napi_gro_flush | ) |
EXPORT_SYMBOL | ( | dev_gro_receive | ) |
EXPORT_SYMBOL | ( | napi_skb_finish | ) |
EXPORT_SYMBOL | ( | napi_gro_receive | ) |
EXPORT_SYMBOL | ( | napi_get_frags | ) |
EXPORT_SYMBOL | ( | napi_frags_finish | ) |
EXPORT_SYMBOL | ( | napi_gro_frags | ) |
EXPORT_SYMBOL | ( | __napi_schedule | ) |
EXPORT_SYMBOL | ( | __napi_complete | ) |
EXPORT_SYMBOL | ( | napi_complete | ) |
EXPORT_SYMBOL | ( | netif_napi_add | ) |
EXPORT_SYMBOL | ( | netif_napi_del | ) |
EXPORT_SYMBOL | ( | register_gifconf | ) |
EXPORT_SYMBOL | ( | netdev_set_master | ) |
EXPORT_SYMBOL | ( | netdev_set_bond_master | ) |
EXPORT_SYMBOL | ( | dev_set_promiscuity | ) |
EXPORT_SYMBOL | ( | dev_set_allmulti | ) |
EXPORT_SYMBOL | ( | dev_get_flags | ) |
EXPORT_SYMBOL | ( | dev_change_flags | ) |
EXPORT_SYMBOL | ( | dev_set_mtu | ) |
EXPORT_SYMBOL | ( | dev_set_group | ) |
EXPORT_SYMBOL | ( | dev_set_mac_address | ) |
EXPORT_SYMBOL | ( | netdev_update_features | ) |
EXPORT_SYMBOL | ( | netdev_change_features | ) |
EXPORT_SYMBOL | ( | netif_stacked_transfer_operstate | ) |
EXPORT_SYMBOL | ( | register_netdevice | ) |
EXPORT_SYMBOL | ( | register_netdev | ) |
EXPORT_SYMBOL | ( | netdev_refcnt_read | ) |
EXPORT_SYMBOL | ( | netdev_stats_to_stats64 | ) |
EXPORT_SYMBOL | ( | dev_get_stats | ) |
EXPORT_SYMBOL | ( | alloc_netdev_mqs | ) |
EXPORT_SYMBOL | ( | free_netdev | ) |
EXPORT_SYMBOL | ( | synchronize_net | ) |
EXPORT_SYMBOL | ( | unregister_netdevice_queue | ) |
EXPORT_SYMBOL | ( | unregister_netdevice_many | ) |
EXPORT_SYMBOL | ( | unregister_netdev | ) |
EXPORT_SYMBOL | ( | netdev_increment_features | ) |
EXPORT_SYMBOL | ( | netdev_printk | ) |
EXPORT_SYMBOL_GPL | ( | dev_forward_skb | ) |
EXPORT_SYMBOL_GPL | ( | netdev_rx_handler_register | ) |
EXPORT_SYMBOL_GPL | ( | netdev_rx_handler_unregister | ) |
EXPORT_SYMBOL_GPL | ( | init_dummy_netdev | ) |
EXPORT_SYMBOL_GPL | ( | dev_change_net_namespace | ) |
void free_netdev | ( | struct net_device * | dev | ) |
int init_dummy_netdev | ( | struct net_device * | dev | ) |
init_dummy_netdev - init a dummy network device for NAPI : device to init
This takes a network device structure and initialize the minimum amount of fields so it can be used to schedule NAPI polls without registering a full blown interface. This is to be used by drivers that need to tie several hardware interfaces to a single NAPI poll scheduler due to HW limitations.
late_initcall_sync | ( | initialize_hashrnd | ) |
void napi_complete | ( | struct napi_struct * | n | ) |
gro_result_t napi_frags_finish | ( | struct napi_struct * | napi, |
struct sk_buff * | skb, | ||
gro_result_t | ret | ||
) |
|
read |
void napi_gro_flush | ( | struct napi_struct * | napi, |
bool | flush_old | ||
) |
gro_result_t napi_gro_frags | ( | struct napi_struct * | napi | ) |
gro_result_t napi_gro_receive | ( | struct napi_struct * | napi, |
struct sk_buff * | skb | ||
) |
gro_result_t napi_skb_finish | ( | gro_result_t | ret, |
struct sk_buff * | skb | ||
) |
int netdev_boot_setup_check | ( | struct net_device * | dev | ) |
void netdev_change_features | ( | struct net_device * | dev | ) |
netdev_change_features - recalculate device features : the device to check
Recalculate dev->features set and send notifications even if they have not changed. Should be called instead of netdev_update_features() if also dev->vlan_features might have changed to allow the changes to be propagated to stacked VLAN devices.
const char* netdev_drivername | ( | const struct net_device * | dev | ) |
void netdev_features_change | ( | struct net_device * | dev | ) |
netdev_features_t netdev_increment_features | ( | netdev_features_t | all, |
netdev_features_t | one, | ||
netdev_features_t | mask | ||
) |
netdev_increment_features - increment feature set by one : current feature set : new feature set : mask feature set
Computes a new feature set after adding a device with feature set to the master device with current feature set . Will not enable anything that is off in . Returns the new feature set.
void netdev_notify_peers | ( | struct net_device * | dev | ) |
netdev_notify_peers - notify network peers about existence of @dev @dev: network device
Generate traffic such that interested network peers are aware of , such as by generating a gratuitous ARP. This may be used when a device wants to inform the rest of the network about some sort of reconfiguration such as a failover event or virtual machine migration.
|
read |
int netdev_rx_handler_register | ( | struct net_device * | dev, |
rx_handler_func_t * | rx_handler, | ||
void * | rx_handler_data | ||
) |
netdev_rx_handler_register - register receive handler : device to register a handler for : receive handler to register : data pointer that is used by rx handler
Register a receive hander for a device. This handler will then be called from __netif_receive_skb. A negative errno code is returned on a failure.
The caller must hold the rtnl_mutex.
For a general description of rx_handler, see enum rx_handler_result.
void netdev_rx_handler_unregister | ( | struct net_device * | dev | ) |
int netdev_set_bond_master | ( | struct net_device * | slave, |
struct net_device * | master | ||
) |
netdev_set_bond_master - set up bonding master/slave pair : slave device : new master device
Changes the master device of the slave. Pass NULL to break the bonding. The caller must hold the RTNL semaphore. On a failure a negative errno code is returned. On success RTM_NEWLINK is sent to the routing socket and the function returns zero.
int netdev_set_master | ( | struct net_device * | slave, |
struct net_device * | master | ||
) |
netdev_set_master - set up master pointer : slave device : new master device
Changes the master device of the slave. Pass NULL to break the bonding. The caller must hold the RTNL semaphore. On a failure a negative errno code is returned. On success the reference counts are adjusted and the function returns zero.
void netdev_state_change | ( | struct net_device * | dev | ) |
void netdev_stats_to_stats64 | ( | struct rtnl_link_stats64 * | stats64, |
const struct net_device_stats * | netdev_stats | ||
) |
void netdev_update_features | ( | struct net_device * | dev | ) |
void netif_device_attach | ( | struct net_device * | dev | ) |
void netif_device_detach | ( | struct net_device * | dev | ) |
void netif_napi_add | ( | struct net_device * | dev, |
struct napi_struct * | napi, | ||
int(*)(struct napi_struct *, int) | poll, | ||
int | weight | ||
) |
netif_napi_add - initialize a napi context : network device : napi context : polling function : default weight
netif_napi_add() must be used to initialize a napi context prior to calling any of the other napi related functions.
void netif_napi_del | ( | struct napi_struct * | napi | ) |
netif_napi_del - remove a napi context : napi context
netif_napi_del() removes a napi context from the network device napi list
netif_receive_skb - process receive buffer from network : buffer to process
netif_receive_skb() is the main receive data processing function. It always succeeds. The buffer may be dropped during processing for congestion control or by the protocol layers.
This function may only be called from softirq context and interrupts should be enabled.
Return values (usually ignored): NET_RX_SUCCESS: no congestion NET_RX_DROP: packet was dropped
netif_rx - post buffer to the network code : buffer to post
This function receives a packet from a device driver and queues it for the upper (protocol) levels to process. It always succeeds. The buffer may be dropped during processing for congestion control or by the protocol layers.
return values: NET_RX_SUCCESS (no congestion) NET_RX_DROP (packet was dropped)
int netif_set_real_num_tx_queues | ( | struct net_device * | dev, |
unsigned int | txq | ||
) |
netdev_features_t netif_skb_features | ( | struct sk_buff * | skb | ) |
void netif_stacked_transfer_operstate | ( | const struct net_device * | rootdev, |
struct net_device * | dev | ||
) |
netif_stacked_transfer_operstate - transfer operstate : the root or lower level device to transfer state from : the device to transfer operstate to
Transfer operational state from root to device. This is normally called when a stacking relationship exists between the root device and the device(a leaf device).
int register_gifconf | ( | unsigned int | family, |
gifconf_func_t * | gifconf | ||
) |
int register_netdev | ( | struct net_device * | dev | ) |
register_netdev - register a network device : device to register
Take a completed network device structure and add it to the kernel interfaces. A NETDEV_REGISTER message is sent to the netdev notifier chain. 0 is returned on success. A negative errno code is returned on a failure to set up the device, or if the name is a duplicate.
This is a wrapper around register_netdevice that takes the rtnl semaphore and expands the device name if you passed a format string to alloc_netdev.
int register_netdevice | ( | struct net_device * | dev | ) |
register_netdevice - register a network device : device to register
Take a completed network device structure and add it to the kernel interfaces. A NETDEV_REGISTER message is sent to the netdev notifier chain. 0 is returned on success. A negative errno code is returned on a failure to set up the device, or if the name is a duplicate.
Callers must hold the rtnl semaphore. You may want register_netdev() instead of this.
BUGS: The locking appears insufficient to guarantee two parallel registers will not get the same name.
int register_netdevice_notifier | ( | struct notifier_block * | nb | ) |
register_netdevice_notifier - register a network notifier block : notifier
Register a notifier to be called when network device events occur. The notifier passed is linked into the kernel structures and must not be reused until it has been unregistered. A negative errno code is returned on a failure.
When registered all registration and up events are replayed to the new notifier to allow device to have a race free view of the network device list.
|
read |
skb_gso_segment - Perform segmentation on skb. : buffer to segment : features for the output path (see dev->features)
This function segments the given skb and returns a list of segments.
It may return NULL if the skb requires no segmentation. This is only possible when GSO is used for verifying header integrity.
subsys_initcall | ( | net_dev_init | ) |
void unregister_netdev | ( | struct net_device * | dev | ) |
int unregister_netdevice_notifier | ( | struct notifier_block * | nb | ) |
unregister_netdevice_notifier - unregister a network notifier block : notifier
Unregister a notifier previously registered by register_netdevice_notifier(). The notifier is unlinked into the kernel structures and may then be reused. A negative errno code is returned on a failure.
After unregistering unregister and down device events are synthesized for all devices on the device list to the removed notifier to remove the need for special case cleanup code.
void unregister_netdevice_queue | ( | struct net_device * | dev, |
struct list_head * | head | ||
) |
unregister_netdevice_queue - remove device from the kernel : device : list
This function shuts down a device interface and removes it from the kernel tables. If head not NULL, device is queued to be unregistered later.
Callers must hold the rtnl semaphore. You may want unregister_netdev() instead of this.