Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 013ba864 authored by Maxime Chevallier's avatar Maxime Chevallier Committed by David S. Miller
Browse files

net: phy: marvell10g: Let genphy_c45_pma_read_abilities set Aneg bit



The genphy_c45_pma_read_abilities helper now sets the Autoneg ability
in phydev->supported according to what the AN MMD reports.

We therefore don't need to manually do that in mv3310_get_features().

Signed-off-by: default avatarMaxime Chevallier <maxime.chevallier@bootlin.com>
Suggested-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 87750d17
Loading
Loading
Loading
Loading
+0 −10
Original line number Diff line number Diff line
@@ -268,16 +268,6 @@ static int mv3310_get_features(struct phy_device *phydev)
{
	int ret, val;

	if (phydev->c45_ids.devices_in_package & MDIO_DEVS_AN) {
		val = phy_read_mmd(phydev, MDIO_MMD_AN, MDIO_STAT1);
		if (val < 0)
			return val;

		if (val & MDIO_AN_STAT1_ABLE)
			linkmode_set_bit(ETHTOOL_LINK_MODE_Autoneg_BIT,
					 phydev->supported);
	}

	ret = genphy_c45_pma_read_abilities(phydev);
	if (ret)
		return ret;