diff options
author | Sebastian Andrzej Siewior <[email protected]> | 2024-10-02 14:58:37 +0200 |
---|---|---|
committer | Jakub Kicinski <[email protected]> | 2024-10-03 15:42:00 -0700 |
commit | 55e802468e1d38dec8e25a2fdb6078d45b647e8c (patch) | |
tree | 5d20bf8d3a9f311bdd625ce3afbe990f33204662 /tools/perf/scripts/python | |
parent | a842e443ca8184f2dc82ab307b43a8b38defd6a5 (diff) |
sfc: Don't invoke xdp_do_flush() from netpoll.
Yury reported a crash in the sfc driver originated from
netpoll_send_udp(). The netconsole sends a message and then netpoll
invokes the driver's NAPI function with a budget of zero. It is
dedicated to allow driver to free TX resources, that it may have used
while sending the packet.
In the netpoll case the driver invokes xdp_do_flush() unconditionally,
leading to crash because bpf_net_context was never assigned.
Invoke xdp_do_flush() only if budget is not zero.
Fixes: 401cb7dae8130 ("net: Reference bpf_redirect_info via task_struct on PREEMPT_RT.")
Reported-by: Yury Vostrikov <[email protected]>
Closes: https://lore.kernel.org/[email protected]
Signed-off-by: Sebastian Andrzej Siewior <[email protected]>
Reviewed-by: Edward Cree <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions