net: bridge: multicast: use rcu to access port list from br_multicast_start_querier
commit7953e6a921ddcba5e3cb0c953e8eb07d9dbdfe2d
authorNikolay Aleksandrov <nikolay@cumulusnetworks.com>
Thu, 11 Apr 2019 12:08:25 +0000 (11 15:08 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 27 Apr 2019 07:34:40 +0000 (27 09:34 +0200)
tree51fcf0363a9018581e4955888e0fe0ee5758b6e5
parent809d689e650f8e386e53fef8bdb4c016405b78ff
net: bridge: multicast: use rcu to access port list from br_multicast_start_querier

[ Upstream commit c5b493ce192bd7a4e7bd073b5685aad121eeef82 ]

br_multicast_start_querier() walks over the port list but it can be
called from a timer with only multicast_lock held which doesn't protect
the port list, so use RCU to walk over it.

Fixes: c83b8fab06fc ("bridge: Restart queries when last querier expires")
Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/bridge/br_multicast.c