Netdev List
 help / color / mirror / Atom feed
From: Nicolai Buchwitz <nb@tipi-net.de>
To: Maxime Chevallier <maxime.chevallier@bootlin.com>
Cc: "Andrew Lunn" <andrew+netdev@lunn.ch>,
	"Jakub Kicinski" <kuba@kernel.org>,
	davem@davemloft.net, "Eric Dumazet" <edumazet@google.com>,
	"Paolo Abeni" <pabeni@redhat.com>,
	"Simon Horman" <horms@kernel.org>,
	"Maxime Coquelin" <mcoquelin.stm32@gmail.com>,
	"Alexandre Torgue" <alexandre.torgue@foss.st.com>,
	"Russell King" <linux@armlinux.org.uk>,
	"Lorenzo Bianconi" <lorenzo.bianconi@oss.qualcomm.com>,
	"Ovidiu Panait" <ovidiu.panait.rb@renesas.com>,
	"Joseph Steel" <recv.jo@gmail.com>,
	"Muhammad Nazim Amirul Nazle Asmade"
	<muhammad.nazim.amirul.nazle.asmade@altera.com>,
	thomas.petazzoni@bootlin.com,
	"Alexis Lothoré" <alexis.lothore@bootlin.com>,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH net-next] net: stmmac: xgmac: Report the VLAN tag type from the descriptor
Date: Wed, 18 Nov 2026 21:09:42 +0100	[thread overview]
Message-ID: <a2518e0794b8b9c79a97cb6c768dded6@tipi-net.de> (raw)
In-Reply-To: <20261118162136.2782405-1-maxime.chevallier@bootlin.com>

Hi Maxime

On 18.11.2026 17:21, Maxime Chevallier wrote:
> Stmmac's double VLAN handling hasn't been working great for a while,
> it's been recently reworked for dwmac4 by Ovidiu Panait. In that work,
> it was found that the tag stripping hardcodes the 8021Q tag type for
> XGMAC while stripping the tag, while the IP actually reports the outer
> tag type in the descriptor.
> 
> The tag type can be one of 6 different values (note inner/outer is
> reversed in the macro names):
> 
>  - XGMAC_ET_LT_VLAN_STAG       single S-tag
>  - XGMAC_ET_LT_VLAN_CTAG       single C-tag
>  - XGMAC_ET_LT_DVLAN_CTAG_CTAG outer C-tag, inner C-tag
>  - XGMAC_ET_LT_DVLAN_STAG_STAG outer S-tag, inner S-tag
>  - XGMAC_ET_LT_DVLAN_CTAG_STAG outer S-tag, inner C-tag
>  - XGMAC_ET_LT_DVLAN_STAG_CTAG outer C-tag, inner S-tag
> 
> Report that tag type through a dedicated desc ops and report it to the
> stack.
> 
> We keep the 8021Q fallback when we don't have the ops, as we don't
> set NETIF_F_HW_VLAN_STAG_FILTER on the cores that don't support that.
> 
> This has been tested on AgileX5 with the vlan.py selftest.
> 
> Signed-off-by: Maxime Chevallier <maxime.chevallier@bootlin.com>

Isn't this a fix too? I mean xgmac advertises STAG_RX but still
reports S-tags as 802.1Q. Then again nobody seems to have hit it
so far, so net-next is probably fine.

Anyway:

Reviewed-by: Nicolai Buchwitz <nb@tipi-net.de>

Thanks,
Nicolai

      reply	other threads:[~2026-11-18 20:09 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-18 16:21 [PATCH net-next] net: stmmac: xgmac: Report the VLAN tag type from the descriptor Maxime Chevallier
2026-11-18 20:09 ` Nicolai Buchwitz [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a2518e0794b8b9c79a97cb6c768dded6@tipi-net.de \
    --to=nb@tipi-net.de \
    --cc=alexandre.torgue@foss.st.com \
    --cc=alexis.lothore@bootlin.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=lorenzo.bianconi@oss.qualcomm.com \
    --cc=maxime.chevallier@bootlin.com \
    --cc=mcoquelin.stm32@gmail.com \
    --cc=muhammad.nazim.amirul.nazle.asmade@altera.com \
    --cc=netdev@vger.kernel.org \
    --cc=ovidiu.panait.rb@renesas.com \
    --cc=pabeni@redhat.com \
    --cc=recv.jo@gmail.com \
    --cc=thomas.petazzoni@bootlin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox