mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-24 05:08:49 +07:00
4f2c6ae5c6
When switchdev drivers process FDB notifications from the underlying
device they resolve the netdev to which the entry points to and notify
the bridge using the switchdev notifier.
However, since the RTNL mutex is not held there is nothing preventing
the netdev from disappearing in the middle, which will cause
br_switchdev_event() to dereference a non-existing netdev.
Make switchdev drivers hold the lock at the beginning of the
notification processing session and release it once it ends, after
notifying the bridge.
Also, remove switchdev_mutex and fdb_lock, as they are no longer needed
when RTNL mutex is held.
Fixes:
|
||
---|---|---|
.. | ||
cmd.h | ||
core_hwmon.c | ||
core.c | ||
core.h | ||
emad.h | ||
item.h | ||
Kconfig | ||
Makefile | ||
pci.c | ||
pci.h | ||
port.h | ||
reg.h | ||
spectrum_buffers.c | ||
spectrum_switchdev.c | ||
spectrum.c | ||
spectrum.h | ||
switchx2.c | ||
trap.h | ||
txheader.h |