[U-Boot] [PATCH] net: mv88e61xx: fix autonegotiation on ports

phy_reset should be called before autoneg is setup
The only boards using MV88E61XX_SWITCH are: - alliedtelesis/SBx81LIFKW - alliedtelesis/SBx81LIFXCAT - gateworks/gw_ventana
Cc: Chris Packham chris.packham@alliedtelesis.co.nz Signed-off-by: Tim Harvey tharvey@gateworks.com --- drivers/net/phy/mv88e61xx.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/net/phy/mv88e61xx.c b/drivers/net/phy/mv88e61xx.c index ea54a15310..c1e2860329 100644 --- a/drivers/net/phy/mv88e61xx.c +++ b/drivers/net/phy/mv88e61xx.c @@ -945,14 +945,14 @@ static int mv88e61xx_phy_config(struct phy_device *phydev) continue; }
- res = genphy_config_aneg(phydev); + res = phy_reset(phydev); if (res < 0) { - printf("Error setting PHY %i autoneg\n", i); + printf("Error resetting PHY %i\n", i); continue; } - res = phy_reset(phydev); + res = genphy_config_aneg(phydev); if (res < 0) { - printf("Error resetting PHY %i\n", i); + printf("Error setting PHY %i autoneg\n", i); continue; }

Hi Tim,
On 5/02/19 9:57 AM, Tim Harvey wrote:
phy_reset should be called before autoneg is setup
The only boards using MV88E61XX_SWITCH are:
- alliedtelesis/SBx81LIFKW
- alliedtelesis/SBx81LIFXCAT
- gateworks/gw_ventana
Cc: Chris Packham chris.packham@alliedtelesis.co.nz Signed-off-by: Tim Harvey tharvey@gateworks.com
Makes sense to me
Reviewed-by: Chris Packham chris.packham@alliedtelesis.co.nz
drivers/net/phy/mv88e61xx.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/net/phy/mv88e61xx.c b/drivers/net/phy/mv88e61xx.c index ea54a15310..c1e2860329 100644 --- a/drivers/net/phy/mv88e61xx.c +++ b/drivers/net/phy/mv88e61xx.c @@ -945,14 +945,14 @@ static int mv88e61xx_phy_config(struct phy_device *phydev) continue; }
res = genphy_config_aneg(phydev);
res = phy_reset(phydev); if (res < 0) {
printf("Error setting PHY %i autoneg\n", i);
printf("Error resetting PHY %i\n", i); continue; }
res = phy_reset(phydev);
res = genphy_config_aneg(phydev); if (res < 0) {
printf("Error resetting PHY %i\n", i);
printf("Error setting PHY %i autoneg\n", i); continue; }

phy_reset should be called before autoneg is setup The only boards using MV88E61XX_SWITCH are:
- alliedtelesis/SBx81LIFKW
- alliedtelesis/SBx81LIFXCAT
- gateworks/gw_ventana
Cc: Chris Packham chris.packham@alliedtelesis.co.nz Signed-off-by: Tim Harvey tharvey@gateworks.com Reviewed-by: Chris Packham chris.packham@alliedtelesis.co.nz
Applied to u-boot-imx, master, thanks !
Best regards, Stefano Babic
participants (3)
-
Chris Packham
-
sbabic@denx.de
-
Tim Harvey