summaryrefslogtreecommitdiffstats
path: root/net/ipv4/devinet.c
diff options
context:
space:
mode:
authorEric W. Biederman2007-09-27 07:09:25 +0200
committerDavid S. Miller2007-10-11 01:52:48 +0200
commit5967789dbc8aafdba5813fa8e8cfce3c90516f83 (patch)
tree0ea20278a6210297812cb8b3ed962e38d98ce3b8 /net/ipv4/devinet.c
parent[NET]: Dynamically allocate the per cpu counters for the loopback device. (diff)
downloadkernel-qcow2-linux-5967789dbc8aafdba5813fa8e8cfce3c90516f83.tar.gz
kernel-qcow2-linux-5967789dbc8aafdba5813fa8e8cfce3c90516f83.tar.xz
kernel-qcow2-linux-5967789dbc8aafdba5813fa8e8cfce3c90516f83.zip
[IPV4]: Remove unnecessary test for the loopback device from inetdev_destroy
Currently we never call unregister_netdev for the loopback device so it is impossible for us to reach inetdev_destroy with the loopback device. So the test in inetdev_destroy is unnecessary. Further when testing with my network namespace patches removing unregistering the loopback device and calling inetdev_destroy works fine so there appears to be no reason for avoiding unregistering the loopback device. Signed-off-by: Eric W. Biederman <ebiederm@xmission.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/devinet.c')
-rw-r--r--net/ipv4/devinet.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/net/ipv4/devinet.c b/net/ipv4/devinet.c
index affea9b121fc..e7f2b022316e 100644
--- a/net/ipv4/devinet.c
+++ b/net/ipv4/devinet.c
@@ -203,8 +203,6 @@ static void inetdev_destroy(struct in_device *in_dev)
ASSERT_RTNL();
dev = in_dev->dev;
- if (dev == loopback_dev)
- return;
in_dev->dead = 1;