Skip to content

New DSA driver for VSC9953 Seville switch

Vladimir Oltean netdev 4 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest11 patches 1 replyIn review
  2. v313 patches 6 repliesSuperseded
  3. v213 patches 17 repliesSuperseded
Earlier versions · 1
VersionPostedPatchesRepliesStatus
v111 patches19 repliesSuperseded

Patches in v4 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/11net: mscc: ocelot: convert port registers to regmapdrivers/net/dsa/ocelot/felix.c drivers/net/dsa/ocelot/felix_vsc9959.c drivers/net/ethernet/mscc/ocelot.h +5 more+158 -990 replies
2/11soc: mscc: ocelot: add MII registers descriptiondrivers/net/dsa/ocelot/felix_vsc9959.c drivers/net/ethernet/mscc/ocelot_vsc7514.c include/soc/mscc/ocelot.h+7 -20 replies
3/11net: mscc: ocelot: convert QSYS_SWITCH_PORT_MODE and SYS_PORT_MODE to regfieldsdrivers/net/dsa/ocelot/felix.c drivers/net/dsa/ocelot/felix_vsc9959.c drivers/net/ethernet/mscc/ocelot.c +6 more+56 -600 replies
4/11net: dsa: felix: create a template for the DSA tags on xmitdrivers/net/dsa/ocelot/felix.c drivers/net/dsa/ocelot/felix.h drivers/net/dsa/ocelot/felix_vsc9959.c +2 more+44 -130 replies
5/11net: mscc: ocelot: split writes to pause frame enable bit and to thresholdsdrivers/net/ethernet/mscc/ocelot.c+12 -70 replies
6/11net: mscc: ocelot: disable flow control on NPI interfacedrivers/net/ethernet/mscc/ocelot.c+4 -00 replies
7/11net: mscc: ocelot: convert SYS_PAUSE_CFG register access to regfielddrivers/net/dsa/ocelot/felix_vsc9959.c drivers/net/ethernet/mscc/ocelot.c drivers/net/ethernet/mscc/ocelot_vsc7514.c +2 more+15 -180 replies
8/11net: mscc: ocelot: extend watermark encoding functiondrivers/net/dsa/ocelot/felix_vsc9959.c drivers/net/ethernet/mscc/ocelot.c drivers/net/ethernet/mscc/ocelot_vsc7514.c +1 more+29 -140 replies
9/11net: dsa: felix: move probing to felix_vsc9959.cdrivers/net/dsa/ocelot/felix.c drivers/net/dsa/ocelot/felix.h drivers/net/dsa/ocelot/felix_vsc9959.c+206 -1910 replies
10/11net: dsa: felix: introduce support for Seville VSC9953 switchdrivers/net/dsa/ocelot/Kconfig drivers/net/dsa/ocelot/Makefile drivers/net/dsa/ocelot/felix.c +3 more+1149 -160 replies
11/11docs: devicetree: add bindings for Seville DSA switch inside Felix driverDocumentation/devicetree/bindings/net/dsa/ocelot.txt+101 -40 replies

Reviews trailers per patch

10 of 11 patches have a Reviewed-by or Acked-by.

PatchFlorian Fainelli
1/11R-b
2/11R-b
3/11R-b
4/11R-b
5/11R-b
6/11R-b
7/11R-b
8/11R-b
9/11R-b
10/11R-b
11/11

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v4 thread

Cover letter [PATCH v4 net-next 00/11] New DSA driver for VSC9953 Seville switch

From: Vladimir Oltean <[email protected]>

Looking at the Felix and Ocelot drivers, Maxim asked if it would be possible to use them as a base for a new driver for the Seville switch inside NXP T1040. Turns out, it is! The result is that the mscc_felix driver was extended to probe on Seville.

The biggest challenge seems to be getting register read/write API generic enough to cover such wild bitfield variations between hardware generations.

Currently, both felix and seville are built under the same kernel config option (NET_DSA_MSCC_FELIX). This has both some advantages (no need to duplicate the Lynx PCS code from felix_vsc9959.c) and some disadvantages (Seville needs to depend on PCI and on ENETC_MDIO). This will be further refined as time progresses.

The driver has been completely reviewed. Previous submission was here, it wasn't accepted due to a conflict with Mark Brown's tree, very late in the release cycle:

https://patchwork.ozlabs.org/project/netdev/cover/[email protected]/

So this is more of a repost, with the only changes being related to rebasing on top of the cleanup I had to do in Ocelot.

Maxim Kochetkov (4):
soc: mscc: ocelot: add MII registers description
net: mscc: ocelot: convert SYS_PAUSE_CFG register access to regfield
net: mscc: ocelot: extend watermark encoding function
net: dsa: felix: introduce support for Seville VSC9953 switch

Vladimir Oltean (7):
net: mscc: ocelot: convert port registers to regmap
net: mscc: ocelot: convert QSYS_SWITCH_PORT_MODE and SYS_PORT_MODE to
regfields
net: dsa: felix: create a template for the DSA tags on xmit
net: mscc: ocelot: split writes to pause frame enable bit and to
thresholds
net: mscc: ocelot: disable flow control on NPI interface
net: dsa: felix: move probing to felix_vsc9959.c
docs: devicetree: add bindings for Seville DSA switch inside Felix
driver

 .../devicetree/bindings/net/dsa/ocelot.txt    |  105 +-
 drivers/net/dsa/ocelot/Kconfig                |   12 +-
 drivers/net/dsa/ocelot/Makefile               |    3 +-
 drivers/net/dsa/ocelot/felix.c                |  232 +---
 drivers/net/dsa/ocelot/felix.h                |   28 +-
 drivers/net/dsa/ocelot/felix_vsc9959.c        |  303 ++++-
 drivers/net/dsa/ocelot/seville_vsc9953.c      | 1104 +++++++++++++++++
 drivers/net/ethernet/mscc/ocelot.c            |   73 +-
 drivers/net/ethernet/mscc/ocelot.h            |    9 +-
 drivers/net/ethernet/mscc/ocelot_io.c         |   18 +-
 drivers/net/ethernet/mscc/ocelot_net.c        |    5 +-
 drivers/net/ethernet/mscc/ocelot_vsc7514.c    |   82 +-
 include/soc/mscc/ocelot.h                     |   68 +-
 include/soc/mscc/ocelot_dev.h                 |   78 --
 include/soc/mscc/ocelot_qsys.h                |   13 -
 include/soc/mscc/ocelot_sys.h                 |   23 -
 net/dsa/tag_ocelot.c                          |   21 +-
 17 files changed, 1767 insertions(+), 410 deletions(-)
 create mode 100644 drivers/net/dsa/ocelot/seville_vsc9953.c
Signature · 1 line
2.25.1