Devicetree
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Christian Marangi" <ansuelsmth@gmail.com>
Cc: devicetree@vger.kernel.org, conor+dt@kernel.org, lee@kernel.org,
	mfd@lists.linux.dev, robh@kernel.org
Subject: Re: [PATCH net-next v19 06/10] net: dsa: tag_mtk: add Airoha variant usage of this TAG
Date: Wed, 29 Jul 2026 17:16:32 +0000	[thread overview]
Message-ID: <20260729171633.0D6B21F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260728154846.1828945-7-ansuelsmth@gmail.com>

Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] Introducing DSA_TAG_PROTO_AIROHA breaks DSA hardware offloading and tag processing in compatible Ethernet MAC drivers (Airoha and Mediatek).
--

--- Patch [6]: [PATCH net-next v19 06/10] net: dsa: tag_mtk: add Airoha variant usage of this TAG ---
commit 2b8fd23ca8ea6ac3597ff1360a2ad1a9a14fa563
Author: Christian Marangi <ansuelsmth@gmail.com>

net: dsa: tag_mtk: add Airoha variant usage of this TAG

This commit introduces a new DSA tag protocol variant for Airoha switches,
documenting differences from the Mediatek tag bitmap. It also adds a
dedicated config, makefile entry, and "airoha" name for external tools
like libpcap.

> diff --git a/include/net/dsa.h b/include/net/dsa.h
> index 8c16ef23cc102..9957443e2907f 100644
> --- a/include/net/dsa.h
> +++ b/include/net/dsa.h
> @@ -73,6 +74,7 @@ enum dsa_tag_protocol {
>  	DSA_TAG_PROTO_KSZ9893		= DSA_TAG_PROTO_KSZ9893_VALUE,
>  	DSA_TAG_PROTO_LAN9303		= DSA_TAG_PROTO_LAN9303_VALUE,
>  	DSA_TAG_PROTO_MTK		= DSA_TAG_PROTO_MTK_VALUE,
> +	DSA_TAG_PROTO_AIROHA		= DSA_TAG_PROTO_AIROHA_VALUE,

[Severity: High]
Will this new tag protocol break hardware offloading and tag processing in
the Ethernet MAC drivers?

Looking at airoha_get_dsa_tag() in drivers/net/ethernet/airoha/airoha_eth.c, 
the driver requires DSA_TAG_PROTO_MTK to extract the tag into the DMA 
descriptor:

	if (dev->dsa_ptr->tag_ops->proto != DSA_TAG_PROTO_MTK)
		return 0;

For DSA_TAG_PROTO_AIROHA, this fails and leaves the tag in the packet 
payload, which can break the PPE module that expects untagged packets.

Similarly, the Mediatek Ethernet driver checks strictly for DSA_TAG_PROTO_MTK
in mtk_uses_dsa() (mtk_eth_soc.c), __mtk_ppe_check_skb() (mtk_ppe.c), and
mtk_flow_get_dsa_port() (mtk_ppe_offload.c). Without DSA_TAG_PROTO_MTK,
hardware DSA untagging and PPE offloading will silently fail.

Do these host Ethernet drivers need to be updated to accept 
DSA_TAG_PROTO_AIROHA alongside DSA_TAG_PROTO_MTK?

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260728154846.1828945-1-ansuelsmth@gmail.com?part=6

  reply	other threads:[~2026-07-29 17:16 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-28 15:48 [PATCH net-next v19 00/10] net: dsa: Add Airoha AN8855 support Christian Marangi
2026-07-28 15:48 ` [PATCH net-next v19 01/10] dt-bindings: net: dsa: Document support for Airoha AN8855 DSA Switch Christian Marangi
2026-07-29  6:22   ` Krzysztof Kozlowski
2026-07-29 17:16   ` sashiko-bot
2026-07-28 15:48 ` [PATCH net-next v19 02/10] dt-bindings: net: Document support for AN8855 Switch Internal PHY Christian Marangi
2026-07-29 17:16   ` sashiko-bot
2026-07-28 15:48 ` [PATCH net-next v19 03/10] dt-bindings: mfd: Document support for Airoha AN8855 Switch SoC Christian Marangi
2026-07-29 17:16   ` sashiko-bot
2026-07-28 15:48 ` [PATCH net-next v19 04/10] mfd: an8855: Add support for Airoha AN8855 Switch MFD Christian Marangi
2026-07-29 17:16   ` sashiko-bot
2026-07-28 15:48 ` [PATCH net-next v19 05/10] net: phy: Add Airoha AN8855 Internal Switch Gigabit PHY Christian Marangi
2026-07-29 17:16   ` sashiko-bot
2026-07-28 15:48 ` [PATCH net-next v19 06/10] net: dsa: tag_mtk: add Airoha variant usage of this TAG Christian Marangi
2026-07-29 17:16   ` sashiko-bot [this message]
2026-07-28 15:48 ` [PATCH net-next v19 07/10] MAINTAINERS: add myself as maintainer for Airoha AN8855 Switch Christian Marangi
2026-07-28 15:48 ` [PATCH net-next v19 08/10] net: dsa: mt7530: move MDIO bus locking into regmap Christian Marangi
2026-07-29 17:16   ` sashiko-bot
2026-07-28 15:48 ` [PATCH net-next v19 09/10] net: dsa: mt7530: generalize and move common function to lib module Christian Marangi
2026-07-29 17:16   ` sashiko-bot
2026-07-28 15:48 ` [PATCH net-next v19 10/10] net: dsa: Add Airoha AN8855 5-Port Gigabit DSA Switch driver Christian Marangi
2026-07-29 17:16   ` sashiko-bot

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=20260729171633.0D6B21F000E9@smtp.kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=ansuelsmth@gmail.com \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=lee@kernel.org \
    --cc=mfd@lists.linux.dev \
    --cc=robh@kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /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