Commit 8753d29f authored by Jiri Pirko's avatar Jiri Pirko Committed by David S. Miller

pppoe: remove unnecessary checks in pppoe_flush_dev

pernet memory is guaranteed to exist when notifiers are called.
Signed-off-by: default avatarJiri Pirko <jpirko@redhat.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 0a12761b
...@@ -290,12 +290,6 @@ static void pppoe_flush_dev(struct net_device *dev) ...@@ -290,12 +290,6 @@ static void pppoe_flush_dev(struct net_device *dev)
struct pppoe_net *pn; struct pppoe_net *pn;
int i; int i;
BUG_ON(dev == NULL);
pn = pppoe_pernet(dev_net(dev));
if (!pn) /* already freed */
return;
write_lock_bh(&pn->hash_lock); write_lock_bh(&pn->hash_lock);
for (i = 0; i < PPPOE_HASH_SIZE; i++) { for (i = 0; i < PPPOE_HASH_SIZE; i++) {
struct pppox_sock *po = pn->hash_table[i]; struct pppox_sock *po = pn->hash_table[i];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment