Skip to content

add enhancement into the existing reset flow

[email protected] linux-mediatek netdev 2 versions In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest6 of 7 patches 1 replyIn review
  2. v17 patches 0 repliesSuperseded

Changes in v2 from the cover letter

- fix the build error with module built causing undefined symbol for pinctrl_bind_pins, so using pinctrl_select_state instead accomplishes the pin mux setup during the reset process.

6 of 7 patches are in this archive. The cover letter announces 7.

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/7net: ethernet: mediatek: refactoring mtk_hw_init to be reuseddrivers/net/ethernet/mediatek/mtk_eth_soc.c+34 -280 replies
2/7net: ethernet: mediatek: add mtk_hw_deinit call as the opposite to mtk_hw_init calldrivers/net/ethernet/mediatek/mtk_eth_soc.c+11 -40 replies
4/7net: ethernet: mediatek: add controlling power domain the ethernet belongs todrivers/net/ethernet/mediatek/mtk_eth_soc.c+7 -00 replies
5/7net: ethernet: mediatek: add the whole ethernet reset into the reset processdrivers/net/ethernet/mediatek/mtk_eth_soc.c drivers/net/ethernet/mediatek/mtk_eth_soc.h+51 -80 replies
6/7net: ethernet: mediatek: add more resets for internal ethernet circuit blockdrivers/net/ethernet/mediatek/mtk_eth_soc.c drivers/net/ethernet/mediatek/mtk_eth_soc.h+20 -130 replies
7/7net: ethernet: mediatek: avoid race condition during the reset processdrivers/net/ethernet/mediatek/mtk_eth_soc.c drivers/net/ethernet/mediatek/mtk_eth_soc.h+38 -10 replies

Reviews trailers per patch

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

Read the v2 thread

Cover letter [PATCH net-next v2 0/7] add enhancement into the existing reset flow

From: Sean Wang <[email protected]>

Current driver only resets DMA used by descriptor rings which can't guarantee it can recover all various kinds of fatal errors, so the patch
1) tries to reset the underlying hardware resource from scratch on Mediatek SoC required for ethernet running.
2) refactors code in order to the reusability of existing code.
3) considers handling for race condition between the reset flow and callbacks registered into core driver called about hardware accessing.
4) introduces power domain usage to hardware setup which leads to have cleanly and completely restore to the state as the initial.

Changes since v1:
- fix the build error with module built causing undefined symbol for pinctrl_bind_pins, so using pinctrl_select_state instead accomplishes the pin mux setup during the reset process.

Sean Wang (7):
net: ethernet: mediatek: refactoring mtk_hw_init to be reused
net: ethernet: mediatek: add mtk_hw_deinit call as the opposite to
mtk_hw_init call
net: ethernet: mediatek: cleanup error path inside mtk_hw_init
net: ethernet: mediatek: add controlling power domain the ethernet
belongs to
net: ethernet: mediatek: add the whole ethernet reset into the reset
process
net: ethernet: mediatek: add more resets for internal ethernet circuit
block
net: ethernet: mediatek: avoid race condition during the reset process

 drivers/net/ethernet/mediatek/mtk_eth_soc.c | 226 +++++++++++++++++++++-------
 drivers/net/ethernet/mediatek/mtk_eth_soc.h |  15 +-
 2 files changed, 186 insertions(+), 55 deletions(-)
Signature · 1 line
1.9.1