loopback.c (bf61c8840efe60fd8f91446860b63338fb424158) | loopback.c (e05e90702b2638a39b5ae9d22740f3a1607c54a0) |
---|---|
1/* 2 * INET An implementation of the TCP/IP protocol suite for the LINUX 3 * operating system. INET is implemented using the BSD Socket 4 * interface as the means of communication with the user level. 5 * 6 * Pseudo-driver for the loopback interface. 7 * 8 * Version: @(#)loopback.c 1.0.4b 08/16/93 --- 132 unchanged lines hidden (view full) --- 141 if (!dev->lstats) 142 return -ENOMEM; 143 144 return 0; 145} 146 147static void loopback_dev_free(struct net_device *dev) 148{ | 1/* 2 * INET An implementation of the TCP/IP protocol suite for the LINUX 3 * operating system. INET is implemented using the BSD Socket 4 * interface as the means of communication with the user level. 5 * 6 * Pseudo-driver for the loopback interface. 7 * 8 * Version: @(#)loopback.c 1.0.4b 08/16/93 --- 132 unchanged lines hidden (view full) --- 141 if (!dev->lstats) 142 return -ENOMEM; 143 144 return 0; 145} 146 147static void loopback_dev_free(struct net_device *dev) 148{ |
149 dev_net(dev)->loopback_dev = NULL; |
|
149 free_percpu(dev->lstats); 150 free_netdev(dev); 151} 152 153static const struct net_device_ops loopback_ops = { 154 .ndo_init = loopback_dev_init, 155 .ndo_start_xmit= loopback_xmit, 156 .ndo_get_stats64 = loopback_get_stats64, --- 65 unchanged lines hidden --- | 150 free_percpu(dev->lstats); 151 free_netdev(dev); 152} 153 154static const struct net_device_ops loopback_ops = { 155 .ndo_init = loopback_dev_init, 156 .ndo_start_xmit= loopback_xmit, 157 .ndo_get_stats64 = loopback_get_stats64, --- 65 unchanged lines hidden --- |