Skip to content

Get rid of the switchdev transactional model

Vladimir Oltean netdev 3 versions – Applied

Status from this message: This series was applied to netdev/net-next.git (refs/heads/master):

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest11 patches 6 repliesApplied 11/11
  2. v311 patches 8 repliesSuperseded
  3. v210 patches 9 repliesSuperseded

Changes in v4 from the cover letter

- Fixed build error in dsa_loop and build warning in hellcreek driver.
- Scheduling the mlxsw SPAN work item regardless of the VLAN add return code, as per Ido's and Petr's request.

Patches in v4 All 11 applied

#Subject and filesSizeRepliesApplied
1/11net: switchdev: remove vid_begin -> vid_end range from VLAN objectsdrivers/net/dsa/b53/b53_common.c drivers/net/dsa/bcm_sf2_cfp.c drivers/net/dsa/dsa_loop.c +19 more+324 -5723 repliesApplied
2/11net: dsa: mv88e6xxx: deny vid 0 on the CPU port and DSA links toodrivers/net/dsa/mv88e6xxx/chip.c+3 -61 replyApplied
3/11net: switchdev: remove the transaction structure from port object notifiersdrivers/net/ethernet/marvell/prestera/prestera_switchdev.c drivers/net/ethernet/mellanox/mlxsw/spectrum_switchdev.c drivers/net/ethernet/mscc/ocelot_net.c +9 more+98 -2080 repliesApplied
4/11net: switchdev: delete switchdev_port_obj_add_nownet/switchdev/switchdev.c+5 -120 repliesApplied
5/11net: switchdev: remove the transaction structure from port attributesdrivers/net/dsa/b53/b53_common.c drivers/net/dsa/b53/b53_priv.h drivers/net/dsa/dsa_loop.c +30 more+162 -4241 replyApplied
6/11net: dsa: remove the transactional logic from ageing time notifiersnet/dsa/dsa_priv.h net/dsa/port.c net/dsa/switch.c+7 -150 repliesApplied
7/11net: dsa: remove the transactional logic from MDB entriesdrivers/net/dsa/b53/b53_common.c drivers/net/dsa/b53/b53_priv.h drivers/net/dsa/bcm_sf2.c +10 more+49 -970 repliesApplied
8/11net: dsa: remove the transactional logic from VLAN objectsdrivers/net/dsa/b53/b53_common.c drivers/net/dsa/b53/b53_priv.h drivers/net/dsa/bcm_sf2.c +18 more+133 -1730 repliesApplied
9/11net: dsa: remove obsolete comments about switchdev transactionsnet/dsa/slave.c net/dsa/switch.c+0 -90 repliesApplied
10/11mlxsw: spectrum_switchdev: remove transactional logic for VLAN objectsdrivers/net/ethernet/mellanox/mlxsw/spectrum_switchdev.c+4 -331 replyApplied
11/11net: switchdev: delete the transaction objectinclude/net/switchdev.h+0 -140 repliesApplied

Reviews trailers per patch

All 11 patches have a Reviewed-by or Acked-by.

PatchIdo SchimmelFlorian FainelliLinus WalleijJiri PirkoKurt KanzenbachGrygorii Strashko
1/11R-b R-b R-b R-b
2/11R-b
3/11R-b R-b A-b A-b
4/11R-b R-b A-b A-b
5/11R-b R-b A-b R-b A-b R-b
6/11R-b A-b A-b
7/11R-b A-b R-b A-b R-b
8/11R-b A-b A-b
9/11R-b A-b A-b
10/11R-b R-b A-b A-b
11/11R-b R-b A-b A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 6 reviewers.

Read the v4 thread

Cover letter [PATCH v4 net-next 00/11] Get rid of the switchdev transactional model

From: Vladimir Oltean <[email protected]>

Changes in v4:
- Fixed build error in dsa_loop and build warning in hellcreek driver.
- Scheduling the mlxsw SPAN work item regardless of the VLAN add return code, as per Ido's and Petr's request.

Changes in v3:
- Resolved a build warning in mv88e6xxx and tested that it actually works properly, which resulted in an extra patch (02/11).
- Addressed Ido's minor feedback in commit 10/11 relating to a comment.

Changes in v2:
- Got rid of the vid_begin -> vid_end range too from the switchdev API.
- Actually propagating errors from DSA MDB and VLAN notifiers.

This series comes after the late realization that the prepare/commit separation imposed by switchdev does not help literally anybody:
https://patchwork.kernel.org/project/netdevbpf/patch/[email protected]/

We should kill it before it inflicts even more damage to the error handling logic in drivers.

Also remove the unused VLAN ranges feature from the switchdev VLAN objects, which simplifies all drivers by quite a bit.

Vladimir Oltean (11):
net: switchdev: remove vid_begin -> vid_end range from VLAN objects
net: dsa: mv88e6xxx: deny vid 0 on the CPU port and DSA links too
net: switchdev: remove the transaction structure from port object
notifiers
net: switchdev: delete switchdev_port_obj_add_now
net: switchdev: remove the transaction structure from port attributes
net: dsa: remove the transactional logic from ageing time notifiers
net: dsa: remove the transactional logic from MDB entries
net: dsa: remove the transactional logic from VLAN objects
net: dsa: remove obsolete comments about switchdev transactions
mlxsw: spectrum_switchdev: remove transactional logic for VLAN objects
net: switchdev: delete the transaction object

 drivers/net/dsa/b53/b53_common.c              |  96 +++++-----
 drivers/net/dsa/b53/b53_priv.h                |  15 +-
 drivers/net/dsa/bcm_sf2.c                     |   2 -
 drivers/net/dsa/bcm_sf2_cfp.c                 |  10 +-
 drivers/net/dsa/dsa_loop.c                    |  73 +++-----
 drivers/net/dsa/hirschmann/hellcreek.c        |  40 ++---
 drivers/net/dsa/lan9303-core.c                |  12 +-
 drivers/net/dsa/lantiq_gswip.c                | 100 ++++-------
 drivers/net/dsa/microchip/ksz8795.c           |  76 ++++----
 drivers/net/dsa/microchip/ksz9477.c           |  96 +++++-----
 drivers/net/dsa/microchip/ksz_common.c        |  25 +--
 drivers/net/dsa/microchip/ksz_common.h        |   8 +-
 drivers/net/dsa/mt7530.c                      |  52 ++----
 drivers/net/dsa/mv88e6xxx/chip.c              | 155 ++++++++--------
 drivers/net/dsa/ocelot/felix.c                |  69 ++------
 drivers/net/dsa/qca8k.c                       |  37 ++--
 drivers/net/dsa/realtek-smi-core.h            |   9 +-
 drivers/net/dsa/rtl8366.c                     | 152 +++++++---------
 drivers/net/dsa/rtl8366rb.c                   |   1 -
 drivers/net/dsa/sja1105/sja1105.h             |   3 +-
 drivers/net/dsa/sja1105/sja1105_devlink.c     |   9 +-
 drivers/net/dsa/sja1105/sja1105_main.c        |  97 ++++------
 .../marvell/prestera/prestera_switchdev.c     |  62 ++-----
 .../mellanox/mlxsw/spectrum_switchdev.c       | 165 +++++-------------
 drivers/net/ethernet/mscc/ocelot.c            |  32 ++--
 drivers/net/ethernet/mscc/ocelot_net.c        |  69 ++------
 drivers/net/ethernet/rocker/rocker.h          |   6 +-
 drivers/net/ethernet/rocker/rocker_main.c     |  61 ++-----
 drivers/net/ethernet/rocker/rocker_ofdpa.c    |  43 ++---
 drivers/net/ethernet/ti/cpsw_switchdev.c      |  70 ++------
 drivers/staging/fsl-dpaa2/ethsw/ethsw.c       | 115 +++++-------
 include/net/dsa.h                             |  11 +-
 include/net/switchdev.h                       |  27 +--
 include/soc/mscc/ocelot.h                     |   3 +-
 net/bridge/br_switchdev.c                     |   6 +-
 net/dsa/dsa_priv.h                            |  27 +--
 net/dsa/port.c                                | 103 +++++------
 net/dsa/slave.c                               |  79 +++------
 net/dsa/switch.c                              |  89 ++--------
 net/switchdev/switchdev.c                     | 101 ++---------
 40 files changed, 714 insertions(+), 1492 deletions(-)
Signature · 1 line
2.25.1