Commit fc7a72ac authored by's avatar Committed by David S. Miller
Browse files

bonding: disable netpoll on enslave failure

slave_disable_netpoll() is not called upon enslave failure which would
lead to a memory leak. Call slave_disable_netpoll() after err_detach as
that's the first error path after enabling netpoll on that slave.
Signed-off-by: default avatarNikolay Aleksandrov <>
Signed-off-by: default avatarDavid S. Miller <>
parent 3c5913b5
...@@ -1920,6 +1920,7 @@ err_detach: ...@@ -1920,6 +1920,7 @@ err_detach:
write_unlock_bh(&bond->curr_slave_lock); write_unlock_bh(&bond->curr_slave_lock);
read_unlock(&bond->lock); read_unlock(&bond->lock);
} }
err_close: err_close:
slave_dev->priv_flags &= ~IFF_BONDING; slave_dev->priv_flags &= ~IFF_BONDING;
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