-
Notifications
You must be signed in to change notification settings - Fork 78
net: phy: as21xxx: stop probing foreign PHYs (root cause of the MxL862xx relay error flood) #207
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -493,7 +493,6 @@ int aeon_cl45_read(struct phy_device *phydev, int dev_addr, | |
| mutex_lock(&bus->mdio_lock); | ||
| ret = __mdiobus_c45_read(bus, phy_addr, dev_addr, phy_reg); | ||
| mutex_unlock(&bus->mdio_lock); | ||
| aeon_mdio_patch(phydev); | ||
|
|
||
| return ret; | ||
| } | ||
|
|
@@ -1481,7 +1480,17 @@ static int aeon_config_led(struct phy_device *phydev) | |
| static int aeon_gen1_match_phy_device(struct phy_device *phydev, | ||
|
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Great, this seems the rootcause of these phyad 30 errors on mxl bus which looked really strange. Thanks for it
Owner
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Looks like i catched the wrong line...meant the line with the read_pid before checking for aeonsemi phy |
||
| const struct phy_driver *phydrv) | ||
| { | ||
| u32 phy_id = aeon_gen1_read_pid(phydev); | ||
| u32 phy_id; | ||
|
|
||
| /* Skip PHYs that are not Aeonsemi. Probing every PHY on every bus | ||
| * sends vendor register accesses to foreign devices, which on a | ||
| * DSA switch relay bus become failing firmware mailbox commands. | ||
| */ | ||
| if (!phy_id_compare_vendor(phydev->c45_ids.device_ids[MDIO_MMD_PCS], | ||
| PHY_VENDOR_AEONSEMI)) | ||
| return genphy_match_phy_device(phydev, phydrv); | ||
|
|
||
| phy_id = aeon_gen1_read_pid(phydev); | ||
|
|
||
| if (phy_id != PHY_ID_AS21XXX) | ||
| return 0; | ||
|
|
@@ -1495,6 +1504,11 @@ static int aeon_gen1_match_phy_device(struct phy_device *phydev, | |
| static int aeon_gen2_match_phy_device(struct phy_device *phydev, | ||
| const struct phy_driver *phydrv) | ||
| { | ||
| /* Skip PHYs that are not Aeonsemi - see aeon_gen1_match_phy_device(). */ | ||
| if (!phy_id_compare_vendor(phydev->c45_ids.device_ids[MDIO_MMD_PCS], | ||
| PHY_VENDOR_AEONSEMI)) | ||
| return genphy_match_phy_device(phydev, phydrv); | ||
|
|
||
| /* AEONSEMI get pid. */ | ||
| phydev->phy_id = aeon_gen2_read_pid(phydev); | ||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.