Commit 8080eac0 authored by Maciej Fijalkowski's avatar Maciej Fijalkowski Committed by Greg Kroah-Hartman

i40e: Relax i40e_xsk_wakeup's return value when PF is busy

[ Upstream commit c77e9f09 ]

Return -EAGAIN instead of -ENETDOWN to provide a slightly milder
information to user space so that an application will know to retry the
syscall when __I40E_CONFIG_BUSY bit is set on pf->state.

Fixes: b3873a5b ("net/i40e: Fix concurrency issues between config flow and XSK")
Signed-off-by: default avatarMaciej Fijalkowski <[email protected]>
Signed-off-by: default avatarDaniel Borkmann <[email protected]earbox.net>
Acked-by: default avatarBjörn Töpel <[email protected]>
Link: https://lore.kernel.org/bpf/[email protected]Signed-off-by: default avatarSasha Levin <[email protected]>
parent d5fd4496
......@@ -791,7 +791,7 @@ int i40e_xsk_wakeup(struct net_device *dev, u32 queue_id, u32 flags)
struct i40e_ring *ring;
if (test_bit(__I40E_CONFIG_BUSY, pf->state))
return -ENETDOWN;
return -EAGAIN;
if (test_bit(__I40E_VSI_DOWN, vsi->state))
return -ENETDOWN;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment