Skip to content

Commit 34f4273

Browse files
Sathesh B Edarakuba-moo
authored andcommitted
octeon_ep: Fix host hang issue during device reboot
When the host loses heartbeat messages from the device, the driver calls the device-specific ndo_stop function, which frees the resources. If the driver is unloaded in this scenario, it calls ndo_stop again, attempting to free resources that have already been freed, leading to a host hang issue. To resolve this, dev_close should be called instead of the device-specific stop function.dev_close internally calls ndo_stop to stop the network interface and performs additional cleanup tasks. During the driver unload process, if the device is already down, ndo_stop is not called. Fixes: 5cb96c2 ("octeon_ep: add heartbeat monitor") Signed-off-by: Sathesh B Edara <sedara@marvell.com> Reviewed-by: Simon Horman <horms@kernel.org> Link: https://patch.msgid.link/20250429114624.19104-1-sedara@marvell.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent a179aad commit 34f4273

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/marvell/octeon_ep/octep_main.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1223,7 +1223,7 @@ static void octep_hb_timeout_task(struct work_struct *work)
12231223
miss_cnt);
12241224
rtnl_lock();
12251225
if (netif_running(oct->netdev))
1226-
octep_stop(oct->netdev);
1226+
dev_close(oct->netdev);
12271227
rtnl_unlock();
12281228
}
12291229

0 commit comments

Comments
 (0)