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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Zw92r9UUBexrm1Oa@fedora>
Date: Wed, 16 Oct 2024 08:17:51 +0000
From: Hangbin Liu <liuhangbin@...il.com>
To: Daniel Borkmann <daniel@...earbox.net>
Cc: netdev@...r.kernel.org, "David S. Miller" <davem@...emloft.net>,
	Eric Dumazet <edumazet@...gle.com>,
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
	Alexei Starovoitov <ast@...nel.org>,
	Jesper Dangaard Brouer <hawk@...nel.org>,
	John Fastabend <john.fastabend@...il.com>,
	Jiri Pirko <jiri@...nulli.us>,
	Sebastian Andrzej Siewior <bigeasy@...utronix.de>,
	Lorenzo Bianconi <lorenzo@...nel.org>,
	Andrii Nakryiko <andriin@...com>, Jussi Maki <joamaki@...il.com>,
	Jay Vosburgh <jv@...sburgh.net>,
	Andy Gospodarek <andy@...yhouse.net>,
	Jonathan Corbet <corbet@....net>,
	Andrew Lunn <andrew+netdev@...n.ch>, linux-doc@...r.kernel.org,
	linux-kernel@...r.kernel.org, bpf@...r.kernel.org,
	Nikolay Aleksandrov <razor@...ckwall.org>
Subject: Re: [PATCH net-next 1/3] bonding: return detailed error when loading
 native XDP fails

On Wed, Oct 16, 2024 at 09:59:01AM +0200, Daniel Borkmann wrote:
> > diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
> > index b1bffd8e9a95..f0f76b6ac8be 100644
> > --- a/drivers/net/bonding/bond_main.c
> > +++ b/drivers/net/bonding/bond_main.c
> > @@ -5676,8 +5676,11 @@ static int bond_xdp_set(struct net_device *dev, struct bpf_prog *prog,
> >   	ASSERT_RTNL();
> > -	if (!bond_xdp_check(bond))
> > +	if (!bond_xdp_check(bond)) {
> > +		BOND_NL_ERR(dev, extack,
> > +			    "No native XDP support for the current bonding mode");
> >   		return -EOPNOTSUPP;
> > +	}
> >   	old_prog = bond->xdp_prog;
> >   	bond->xdp_prog = prog;
> 
> LGTM, but independent of these I was more thinking whether something like this
> could do the trick (only compile tested). That way you also get the fallback
> without changing anything in the core XDP code.

Yes, I also thought about do fallback on bonding. But Nikolay suggested
just use extack msg[1], and Jakub think this is report by QE rather than
a real user. So I think we can use extack first, and convert to auto
fallback on bonding if a real user complains. What do you think?

[1] https://lore.kernel.org/netdev/8088f2a7-3ab1-4a1e-996d-c15703da13cc@blackwall.org/
[2] https://lore.kernel.org/netdev/20241015085121.5f22e96f@kernel.org/

Thanks
Hangbin

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ