[FS#1322] DSA driver doesn't work as expected in 4.14. Fails to register mdio switches

LEDE Bugs lede-bugs at lists.infradead.org
Fri Feb 2 11:49:30 PST 2018


A new Flyspray task has been opened.  Details are below. 

User who did this - Vivek (npcomplete) 

Attached to Project - OpenWrt/LEDE Project
Summary - DSA driver doesn't work as expected in 4.14. Fails to register mdio switches
Task Type - Bug Report
Category - Kernel
Status - Unconfirmed
Assigned To - 
Operating System - All
Severity - High
Priority - Very Low
Reported Version - Trunk
Due in Version - Undecided
Due Date - Undecided
Details - Supply the following if possible:
 - EA9500
 - OpenWrt trunk as of 2018-Feb-02

I have an uncommitted device tree for this device which worked fine with 4.9 see [1]
But, it doesn't work with 4.14. I tried to do some testing around this.

This device has two switches - srab and an other connected via mdio. When I have both
switches defined, both switches gets detected. However, they *both* fail to register 
with dsa framework.

When I remove the mdio switch from the tree, the srab switch is detected and registered.



[    1.781017] libphy: iProc MDIO bus: probed
[    1.785164] iproc-mdio 18003000.mdio: Broadcom iProc MDIO bus at 0xc88af000
[    1.792388] libphy: mdio_mux: probed
[    1.796096] libphy: mdio_mux: probed
[    1.800221] libphy: Fixed MDIO Bus: probed


Then later where I expect it to register with dsa:


[    3.202389] Registering SWP/SWPB emulation handler
[    3.331885] b53_common: found switch: BCM53125, rev 4
[    3.337004] bcm53xx 1.200:00: failed to register switch: -517
[    3.342965] b53_common: found switch: BCM53012, rev 0


Here is how 4.9 kernel behaves for the same tree:


[    1.821879] libphy: iProc MDIO bus: probed
[    1.826054] iproc-mdio 18003000.mdio: Broadcom iProc MDIO bus at 0xc88af000
[    1.833238] libphy: mdio_mux: probed
[    1.836828] mdio-mux-mmioreg 1800c1c0.mdio_mii_mux: Version 1.0
[    1.842857] libphy: mdio_mux: probed
[    1.846458] mdio_bus 1.0:10: mdio_device_register
[    1.851261] libphy: mdio_mux: probed
[    1.854869] mdio_bus 1.200:00: mdio_device_register
[    1.859799] mdio-mux-mmioreg 18003000.mdio_ext_mux: Version 1.0
[    1.866280] libphy: Fixed MDIO Bus: probed
[    1.870398] libphy: mdio_driver_register: bcm53xx
[    2.001933] b53_common: found switch: BCM53125, rev 4
[    2.007036] bcm53xx 1.200:00: failed to register switch: -517
[    2.013045] b53_common: found switch: BCM53012, rev 0



[    3.301933] b53_common: found switch: BCM53125, rev 4
[    3.307044] bcm53xx 1.200:00: failed to register switch: -517
[    3.312954] b53_common: found switch: BCM53012, rev 0
[    3.318039] DSA: switch 0 0 parsed
[    3.321446] DSA: tree 0 parsed
[    3.522060] libphy: dsa slave smi: probed
[    3.526902] Generic PHY fixed-0:03: attached PHY driver [Generic PHY] (mii_bus:phy_addr=fixed-0:03, irq=-1)
[    3.571922] Generic PHY dsa-0.0:01: attached PHY driver [Generic PHY] (mii_bus:phy_addr=dsa-0.0:01, irq=-1)
[    3.621918] Generic PHY dsa-0.0:02: attached PHY driver [Generic PHY] (mii_bus:phy_addr=dsa-0.0:02, irq=-1)
[    3.671919] Generic PHY dsa-0.0:03: attached PHY driver [Generic PHY] (mii_bus:phy_addr=dsa-0.0:03, irq=-1)
[    3.721919] Generic PHY dsa-0.0:04: attached PHY driver [Generic PHY] (mii_bus:phy_addr=dsa-0.0:04, irq=-1)
[    3.861926] b53_common: found switch: BCM53125, rev 4
[    3.867023] DSA: switch 1 0 parsed
[    3.870425] DSA: tree 1 parsed
[    8.772059] libphy: dsa slave smi: probed
[    8.811922] Generic PHY dsa-1.0:00: attached PHY driver [Generic PHY] (mii_bus:phy_addr=dsa-1.0:00, irq=-1)
[    8.861920] Generic PHY dsa-1.0:01: attached PHY driver [Generic PHY] (mii_bus:phy_addr=dsa-1.0:01, irq=-1)
[    8.911920] Generic PHY dsa-1.0:02: attached PHY driver [Generic PHY] (mii_bus:phy_addr=dsa-1.0:02, irq=-1)
[    8.961922] Generic PHY dsa-1.0:03: attached PHY driver [Generic PHY] (mii_bus:phy_addr=dsa-1.0:03, irq=-1)
[    9.011920] Generic PHY dsa-1.0:04: attached PHY driver [Generic PHY] (mii_bus:phy_addr=dsa-1.0:04, irq=-1)


 [1] https://forum.lede-project.org/t/build-for-linksys-ea9500/1817

More information can be found at the following URL:
https://bugs.lede-project.org/index.php?do=details&task_id=1322



More information about the lede-bugs mailing list