diff options
author | Xiaodong Xu <stid.smth@gmail.com> | 2012-09-22 00:09:32 +0000 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-10-13 05:38:44 +0900 |
commit | e043257dde697ded17ed99f280cdb7643fdc007a (patch) | |
tree | bd0160da8f1998f08ddf12b2f862ae3a6d1d7521 /drivers/net | |
parent | 8d16c6268b7c3af2ce4f58de903588489e037fcf (diff) | |
download | linux-3.10-e043257dde697ded17ed99f280cdb7643fdc007a.tar.gz linux-3.10-e043257dde697ded17ed99f280cdb7643fdc007a.tar.bz2 linux-3.10-e043257dde697ded17ed99f280cdb7643fdc007a.zip |
pppoe: drop PPPOX_ZOMBIEs in pppoe_release
[ Upstream commit 2b018d57ff18e5405823e5cb59651a5b4d946d7b ]
When PPPOE is running over a virtual ethernet interface (e.g., a
bonding interface) and the user tries to delete the interface in case
the PPPOE state is ZOMBIE, the kernel will loop forever while
unregistering net_device for the reference count is not decreased to
zero which should have been done with dev_put().
Signed-off-by: Xiaodong Xu <stid.smth@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/ppp/pppoe.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ppp/pppoe.c b/drivers/net/ppp/pppoe.c index 2fa1a9b6f49..2e0d8762bb5 100644 --- a/drivers/net/ppp/pppoe.c +++ b/drivers/net/ppp/pppoe.c @@ -576,7 +576,7 @@ static int pppoe_release(struct socket *sock) po = pppox_sk(sk); - if (sk->sk_state & (PPPOX_CONNECTED | PPPOX_BOUND)) { + if (sk->sk_state & (PPPOX_CONNECTED | PPPOX_BOUND | PPPOX_ZOMBIE)) { dev_put(po->pppoe_dev); po->pppoe_dev = NULL; } |