Skip to content

*Add MTU change with stmmac interface running

Christian Marangi linux-arm-kernel lkml netdev 5 versions – Applied

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

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v5 Latest5 patches 4 repliesApplied 5/5
  2. v45 patches 2 repliesSuperseded
  3. v35 patches 1 replySuperseded
Earlier versions · 2
VersionPostedPatchesRepliesStatus
v25 patches0 repliesSuperseded
v1 RFC5 patches3 repliesSuperseded

Changes in v5 from the cover letter

- Fix double space for kdoc
- Fix missing kdoc for dma_conf in __init_dma_tx_desc_rings v4:
- Add additional stmmac_set_rx_mode after stmmac_open
- Disconnect phylink first on stmmac release

Patches in v5 All 5 applied

#Subject and filesSizeRepliesApplied
1/5net: ethernet: stmicro: stmmac: move queue reset to dedicated functionsdrivers/net/ethernet/stmicro/stmmac/stmmac_main.c+31 -280 repliesApplied
2/5net: ethernet: stmicro: stmmac: first disable all queues and disconnect in releasedrivers/net/ethernet/stmicro/stmmac/stmmac_main.c+2 -20 repliesApplied
3/5net: ethernet: stmicro: stmmac: move dma conf to dedicated structdrivers/net/ethernet/stmicro/stmmac/chain_mode.c drivers/net/ethernet/stmicro/stmmac/ring_mode.c drivers/net/ethernet/stmicro/stmmac/stmmac.h +4 more+172 -1630 repliesApplied
4/5net: ethernet: stmicro: stmmac: generate stmmac dma conf before opendrivers/net/ethernet/stmicro/stmmac/stmmac_main.c+289 -1734 repliesApplied
5/5net: ethernet: stmicro: stmmac: permit MTU change with interface updrivers/net/ethernet/stmicro/stmmac/stmmac_main.c+24 -60 repliesApplied

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v5 yet.

Read the v5 thread

Cover letter [net-next PATCH v5 0/5] *Add MTU change with stmmac interface running

This series is to permit MTU change while the interface is running. Major rework are needed to permit to allocate a new dma conf based on the new MTU before applying it. This is to make sure there is enough space to allocate all the DMA queue before releasing the stmmac driver.

This was tested with a simple way to stress the network while the interface is running.

2 ssh connection to the device:
- One generating simple traffic with while true; do free; done
- The other making the mtu change with a delay of 1 second

The connection is correctly stopped and recovered after the MTU is changed.

The first 2 patch of this series are minor fixup that fix problems presented while testing this. One fix a problem when we renable a queue while we are generating a new dma conf. The other is a corner case that was notice while stressing the driver and turning down the interface while there was some traffic.

(this is a follow-up of a simpler patch that wanted to add the same feature. It was suggested to first try to check if it was possible to apply the new configuration. Posting as RFC as it does major rework for the new concept of DMA conf)

v5:
- Fix double space for kdoc
- Fix missing kdoc for dma_conf in __init_dma_tx_desc_rings v4:
- Add additional stmmac_set_rx_mode after stmmac_open
- Disconnect phylink first on stmmac release
v3:
- Fix compilation error reported by kernel test bot (missing dma_confg changes to tc and selftest source)
v2:
- Put it out of RFC

Christian Marangi (5):
net: ethernet: stmicro: stmmac: move queue reset to dedicated
functions
net: ethernet: stmicro: stmmac: first disable all queues and
disconnect in release
net: ethernet: stmicro: stmmac: move dma conf to dedicated struct
net: ethernet: stmicro: stmmac: generate stmmac dma conf before open
net: ethernet: stmicro: stmmac: permit MTU change with interface up

 .../net/ethernet/stmicro/stmmac/chain_mode.c  |   6 +-
 .../net/ethernet/stmicro/stmmac/ring_mode.c   |   4 +-
 drivers/net/ethernet/stmicro/stmmac/stmmac.h  |  21 +-
 .../ethernet/stmicro/stmmac/stmmac_ethtool.c  |   4 +-
 .../net/ethernet/stmicro/stmmac/stmmac_main.c | 723 +++++++++++-------
 .../stmicro/stmmac/stmmac_selftests.c         |   8 +-
 .../net/ethernet/stmicro/stmmac/stmmac_tc.c   |   6 +-
 7 files changed, 459 insertions(+), 313 deletions(-)
Signature · 1 line
2.36.1