Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

net/ibmvnic: Fix RTNL deadlock during device reset

Commit a5681e20b541 ("net/ibmnvic: Fix deadlock problem
in reset") made the change to hold the RTNL lock during
driver reset but still calls netdev_notify_peers, which
results in a deadlock. Instead, use call_netdevice_notifiers,
which is functionally the same except that it does not
take the RTNL lock again.

Fixes: a5681e20b541 ("net/ibmnvic: Fix deadlock problem in reset")
Signed-off-by: Thomas Falcon <tlfalcon@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Thomas Falcon and committed by
David S. Miller
986103e7 e3f78718

+1 -1
+1 -1
drivers/net/ethernet/ibm/ibmvnic.c
··· 1859 1859 1860 1860 if (adapter->reset_reason != VNIC_RESET_FAILOVER && 1861 1861 adapter->reset_reason != VNIC_RESET_CHANGE_PARAM) 1862 - netdev_notify_peers(netdev); 1862 + call_netdevice_notifiers(NETDEV_NOTIFY_PEERS, netdev); 1863 1863 1864 1864 netif_carrier_on(netdev); 1865 1865