lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <48bb0155-cc1a-b72c-2d04-98d28adb467b@gmail.com>
Date: Wed, 2 Oct 2024 14:36:36 +0100
From: Edward Cree <ecree.xilinx@...il.com>
To: Sebastian Andrzej Siewior <bigeasy@...utronix.de>,
 netdev@...r.kernel.org, linux-net-drivers@....com, bpf@...r.kernel.org
Cc: "David S. Miller" <davem@...emloft.net>,
 Toke Høiland-Jørgensen <toke@...hat.com>,
 Alexei Starovoitov <ast@...nel.org>, Daniel Borkmann <daniel@...earbox.net>,
 Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>,
 Jesper Dangaard Brouer <hawk@...nel.org>,
 John Fastabend <john.fastabend@...il.com>,
 Martin Habets <habetsm.xilinx@...il.com>, Paolo Abeni <pabeni@...hat.com>,
 Thomas Gleixner <tglx@...utronix.de>, Yury Vostrikov <mon@...ormed.ru>
Subject: Re: [PATCH net] sfc: Don't invoke xdp_do_flush() from netpoll.

On 02/10/2024 13:58, Sebastian Andrzej Siewior wrote:
> 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 <mon@...ormed.ru>
> Closes: https://lore.kernel.org/5627f6d1-5491-4462-9d75-bc0612c26a22@app.fastmail.com
> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@...utronix.de>

Reviewed-by: Edward Cree <ecree.xilinx@...il.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ