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] [thread-next>] [day] [month] [year] [list]
Date: Wed, 3 Jan 2024 17:42:18 +0100
From: Linus Walleij <linus.walleij@...aro.org>
To: Romain Gantois <romain.gantois@...tlin.com>
Cc: Alexandre Torgue <alexandre.torgue@...s.st.com>, Jose Abreu <joabreu@...opsys.com>, 
	"David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, 
	Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>, 
	Maxime Coquelin <mcoquelin.stm32@...il.com>, Miquel Raynal <miquel.raynal@...tlin.com>, 
	Maxime Chevallier <maxime.chevallier@...tlin.com>, Sylvain Girard <sylvain.girard@...com>, 
	Vladimir Oltean <olteanv@...il.com>, Andrew Lunn <andrew@...n.ch>, 
	Pascal EBERHARD <pascal.eberhard@...com>, Richard Tresidder <rtresidd@...ctromag.com.au>, 
	netdev@...r.kernel.org, linux-stm32@...md-mailman.stormreply.com, 
	linux-arm-kernel@...ts.infradead.org, stable@...r.kernel.org
Subject: Re: [PATCH net v2 1/1] net: stmmac: Prevent DSA tags from breaking
 COE on stmmac

On Wed, Jan 3, 2024 at 10:11 AM Romain Gantois
<romain.gantois@...tlin.com> wrote:
> On Tue, 2 Jan 2024, Linus Walleij wrote:
> ...
> > > +static inline bool stmmac_has_ip_ethertype(struct sk_buff *skb)
> > > +{
> > > +       __be16 proto = eth_header_parse_protocol(skb);
> >
> > I made a new function for this in my patch
> > https://lore.kernel.org/netdev/20231222-new-gemini-ethernet-regression-v4-2-a36e71b0f32b@linaro.org/
> >
> > I was careful to add if (!pskb_may_pull(skb, ETH_HLEN)) because Eric
> > was very specific about this, I suppose you could get fragment frames that
> > are smaller than an ethernet header.
>
> Okay nice, then I'll rewrite this series to use the new function once your
> changes make it in.

I just rewrote my patch to use eth_header_parse_protocol() instead.
I should not invent a new version of something that already exist.

> > Should we add an if (!pskb_may_pull(skb, ETH_HLEN)) to
> > eth_header_parse_protocol()?
>
> That does sound logical to me but I couldn't tell you what the impact on current
> callers would be. The net maintainers will probably have a better idea of this.

I can propose a separate patch for this with RFC.

Yours,
Linus Walleij

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ