Skip to content

net: dsa: modular build fixes and improvements

Florian Fainelli netdev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest8 patches 3 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/8net: dsa: add missing netdevice.h includenet/dsa/dsa_priv.h+1 -00 replies
2/8net: dsa: make module builds worknet/dsa/Makefile net/dsa/dsa.c net/dsa/dsa_lib.c +1 more+74 -492 replies
3/8net: phy: fixed: allow setting no update_link callbackdrivers/net/phy/fixed_phy.c+1 -10 replies
4/8net: dsa: cleanup resources upon module removalnet/dsa/dsa.c net/dsa/dsa_priv.h net/dsa/slave.c+34 -01 reply
5/8net: dsa: allow switch drivers to cleanup their resourcesinclude/net/dsa.h net/dsa/dsa.c+3 -00 replies
6/8net: dsa: bcm_sf2: factor interrupt disabling in a functiondrivers/net/dsa/bcm_sf2.c+12 -120 replies
7/8net: dsa: bcm_sf2: cleanup resources in remove callbackdrivers/net/dsa/bcm_sf2.c+20 -00 replies
8/8net: dsa: free distributed switch tree pointer in dsa_removenet/dsa/dsa.c+1 -00 replies

Reviews trailers per patch

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

Read the v1 thread

Cover letter [PATCH net-next 0/8] net: dsa: modular build fixes and improvements

Hi David,

This patch series fixes some problems seen when using DSA as a module. There was a circular functional dependency which made it impossible to successfully load a DSA switch driver module, and impossible re-insert it afterwards. Some other problems appearing where the lack of resource cleanup, leading to various leaks and -EEXIST errors upon module re-insertion.

Thanks!

Florian Fainelli (8):
net: dsa: add missing netdevice.h include
net: dsa: make module builds work
net: phy: fixed: allow setting no update_link callback
net: dsa: cleanup resources upon module removal
net: dsa: allow switch drivers to cleanup their resources
net: dsa: bcm_sf2: factor interrupt disabling in a function
net: dsa: bcm_sf2: cleanup resources in remove callback
net: dsa: free distributed switch tree pointer in dsa_remove

 drivers/net/dsa/bcm_sf2.c   | 44 ++++++++++++++++++++--------
 drivers/net/phy/fixed_phy.c |  2 +-
 include/net/dsa.h           |  1 +
 net/dsa/Makefile            |  2 ++
 net/dsa/dsa.c               | 71 ++++++++++++++-------------------------------
 net/dsa/dsa_lib.c           | 68 +++++++++++++++++++++++++++++++++++++++++++
 net/dsa/dsa_priv.h          |  6 ++++
 net/dsa/slave.c             | 14 +++++++++
 8 files changed, 146 insertions(+), 62 deletions(-)
 create mode 100644 net/dsa/dsa_lib.c
Signature · 1 line
2.1.0