Skip to content

Commit 9d2afba

Browse files
Eugenia Emantayevdavem330
authored andcommitted
net/mlx4_en: Fix panic during reboot
Fix a kernel panic that occurs as a result of an asynchronous event handled in roce_gid_mgmt: mlx4_en_get_drvinfo is called and accesses freed resources. This happens in a shutdown flow only, since pci device is destroyed while netdevice is still alive. Fixes: c27a02c ("mlx4_en: Add driver for Mellanox ConnectX 10GbE NIC") Signed-off-by: Eugenia Emantayev <[email protected]> Signed-off-by: Tariq Toukan <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 8d59de8 commit 9d2afba

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/net/ethernet/mellanox/mlx4/en_netdev.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2201,6 +2201,7 @@ void mlx4_en_destroy_netdev(struct net_device *dev)
22012201

22022202
if (!shutdown)
22032203
free_netdev(dev);
2204+
dev->ethtool_ops = NULL;
22042205
}
22052206

22062207
static int mlx4_en_change_mtu(struct net_device *dev, int new_mtu)

0 commit comments

Comments
 (0)