Skip to content
Commit 92e584fe authored by Moni Shoua's avatar Moni Shoua Committed by David S. Miller
Browse files

net/bonding: Fix potential bad memory access during bonding events



When queuing work to send the NETDEV_BONDING_INFO netdev event, it's
possible that when the work is executed, the pointer to the slave
becomes invalid. This can happen if between queuing the event and the
execution of the work, the net-device was un-ensvaled and re-enslaved.

Fix that by queuing a work with the data of the slave instead of the
slave structure.

Fixes: 69e61133 ('net/bonding: Notify state change on slaves')
Reported-by: default avatarNikolay Aleksandrov <nikolay@redhat.com>
Signed-off-by: default avatarMoni Shoua <monis@mellanox.com>
Signed-off-by: default avatarOr Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 9dce285b
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