Netdev List
 help / color / mirror / Atom feed
* [PATCH net-next v7 0/4] net: dsa: mt7628 embedded switch initial support
@ 2026-08-13 19:02 Joris Vaisvila
  2026-08-13 19:02 ` [PATCH net-next v7 1/4] dt-bindings: net: dsa: add MT7628 ESW Joris Vaisvila
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Joris Vaisvila @ 2026-08-13 19:02 UTC (permalink / raw)
  To: netdev
  Cc: horms, pabeni, kuba, edumazet, davem, olteanv, Andrew Lunn,
	devicetree, Rob Herring, Krzysztof Kozlowski, Conor Dooley,
	Arınç ÜNAL, Landen Chao, DENG Qingfang, Sean Wang,
	Daniel Golle, Joris Vaisvila

This patch series adds initial support for the MediaTek MT7628 Embedded
Switch.

The driver implements the basic functionality required to operate the
switch using DSA. The hardware provides five internal Fast Ethernet user
ports and one Gigabit port connected internally to the CPU MAC.

Bridge offloading is not yet supported, but due to the CPU to switch
link being Gigabit and all the user ports being Fast Ethernet, software
bridging is a practical solution for the initial driver.

Tested on an MT7628NN-based board.

Changes since v6:
	- added depends on HAS_IOMEM && (SOC_MT7620 || COMPILE_TEST) and
	  select REGMAP_MMIO to NET_DSA_MT7628 kconfig entry
	- added comment about all ports being disabled by reset in
	  port_enable function
	- added depends on SOC_MT7620 || COMPILE_TEST to MEDIATEK_FE_SOC_PHY
	  kconfig entry
	- added genphy suspend and resume features to mtk-fe-soc driver
	- rebased on net-next
Link: https://lore.kernel.org/netdev/20260704105659.140970-1-joey@tinyisr.com/t/#u

Changes since v5: 
	- updated tag_mt7628 to kfree_skb() on error in receive path
	- removed Reviewed-by tags from tag_mt7628
	- removed mmio base pointer from mt7628_esw since it's only used to
	  initialize the regmap
	- rebased on net-next
Link: https://lore.kernel.org/netdev/20260613181845.111877-1-joey@tinyisr.com/t/#u

Changes since v4:
	mt7628 dsa driver:
		- updated mdiobus allocation to use ds->dev instead of esw->dev,
		  matching other DSA drivers (no functional change)
	mt7628 phy driver:
		- replaced phy_write() with phy_modify() when setting PHY init
		  bit (no functional change)
	mt7628 dt binding:
		- moved unevaluatedProperties after required block
		- removed blank line between compatible and reg in example
Link: https://lore.kernel.org/netdev/20260608192948.289745-1-joey@tinyisr.com/t/#u

Changes since v3:
	- rebased on latest net-next
	mt7628 dsa driver:
		- simplified vlan_add hardware vlan slot search
		- fixed vlan_del not removing vid from port pvid
		- separated mii_read/mii_write error handling from return
		  value parsing. Updated RD_DONE/WT_DONE bit checking
		  with clearer logic and a comment.
		- moved NET_DSA_MT7628 after NET_DSA_MT7530 in Kconfig
		- added missing reset return value checks in probe
		- fixed mt7628_switch_ops missing const specifier
		- removed mdio node parsing from of, as there is nothing
		  to configure
	mt7628 dt binding:
		- updated description to be more clear about port count
		- dropped optional mdio subnode. the switch does not
		  expose an external MDIO bus and all integrated PHY
		  access is handled by the driver.
		- removed unused switch0 label in example
Link: https://lore.kernel.org/netdev/20260428185510.261521-1-joey@tinyisr.com/t/#u

Changes since v2:
	- fix binding issues found in review
	- fix ignored dsa_tag_8021q_register return value
	- add switch teardown to clean up tag_8021q
	- fix ordering issue where mdio probe fail would leak tag_8021q
Link: https://lore.kernel.org/netdev/20260330184017.766200-1-joey@tinyisr.com/t/#u

Changes since v1:
	- changed port 6 phy-mode to internal
	- cleaned up tag_mt7628 rcv function and mask defines
	- fixed sorting error in drivers/net/dsa/ Kconfig and Makefile
	- fixed sorting error in net/dsa/ Kconfig and Makefile
	- fixed mt7628_mii_read/write return values on error
Link: https://lore.kernel.org/netdev/20260326204413.3317584-1-joey@tinyisr.com/t/#u

Thanks,
Joris

Joris Vaisvila (4):
  dt-bindings: net: dsa: add MT7628 ESW
  net: phy: mediatek: add phy driver for MT7628 built-in Fast Ethernet
    PHYs
  net: dsa: initial MT7628 tagging driver
  net: dsa: initial support for MT7628 embedded switch

 .../bindings/net/dsa/mediatek,mt7628-esw.yaml |  96 +++
 drivers/net/dsa/Kconfig                       |  10 +
 drivers/net/dsa/Makefile                      |   1 +
 drivers/net/dsa/mt7628.c                      | 652 ++++++++++++++++++
 drivers/net/phy/mediatek/Kconfig              |  11 +-
 drivers/net/phy/mediatek/Makefile             |   1 +
 drivers/net/phy/mediatek/mtk-fe-soc.c         |  52 ++
 include/net/dsa.h                             |   2 +
 net/dsa/Kconfig                               |   6 +
 net/dsa/Makefile                              |   1 +
 net/dsa/tag_mt7628.c                          |  93 +++
 11 files changed, 924 insertions(+), 1 deletion(-)
 create mode 100644 Documentation/devicetree/bindings/net/dsa/mediatek,mt7628-esw.yaml
 create mode 100644 drivers/net/dsa/mt7628.c
 create mode 100644 drivers/net/phy/mediatek/mtk-fe-soc.c
 create mode 100644 net/dsa/tag_mt7628.c

-- 
2.55.0


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-08-13 19:04 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-13 19:02 [PATCH net-next v7 0/4] net: dsa: mt7628 embedded switch initial support Joris Vaisvila
2026-08-13 19:02 ` [PATCH net-next v7 1/4] dt-bindings: net: dsa: add MT7628 ESW Joris Vaisvila
2026-08-13 19:02 ` [PATCH net-next v7 2/4] net: phy: mediatek: add phy driver for MT7628 built-in Fast Ethernet PHYs Joris Vaisvila
2026-08-13 19:02 ` [PATCH net-next v7 3/4] net: dsa: initial MT7628 tagging driver Joris Vaisvila
2026-08-13 19:02 ` [PATCH net-next v7 4/4] net: dsa: initial support for MT7628 embedded switch Joris Vaisvila

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox