Skip to content

Commit 17cbfcd

Browse files
Abhishek Chauhankuba-moo
authored andcommitted
net: phy: aquantia: AQR115c fix up PMA capabilities
AQR115c reports incorrect PMA capabilities which includes 10G/5G and also incorrectly disables capabilities like autoneg and 10Mbps support. AQR115c as per the Marvell databook supports speeds up to 2.5Gbps with autonegotiation. Fixes: 0ebc581 ("net: phy: aquantia: add support for aqr115c") Link: https://lore.kernel.org/all/[email protected]/T/ Signed-off-by: Abhishek Chauhan <[email protected]> Reviewed-by: Russell King (Oracle) <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 55e8024 commit 17cbfcd

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

drivers/net/phy/aquantia/aquantia_main.c

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -731,6 +731,19 @@ static int aqr113c_fill_interface_modes(struct phy_device *phydev)
731731
return aqr107_fill_interface_modes(phydev);
732732
}
733733

734+
static int aqr115c_get_features(struct phy_device *phydev)
735+
{
736+
unsigned long *supported = phydev->supported;
737+
738+
/* PHY supports speeds up to 2.5G with autoneg. PMA capabilities
739+
* are not useful.
740+
*/
741+
linkmode_or(supported, supported, phy_gbit_features);
742+
linkmode_set_bit(ETHTOOL_LINK_MODE_2500baseT_Full_BIT, supported);
743+
744+
return 0;
745+
}
746+
734747
static int aqr113c_config_init(struct phy_device *phydev)
735748
{
736749
int ret;
@@ -1046,6 +1059,7 @@ static struct phy_driver aqr_driver[] = {
10461059
.get_sset_count = aqr107_get_sset_count,
10471060
.get_strings = aqr107_get_strings,
10481061
.get_stats = aqr107_get_stats,
1062+
.get_features = aqr115c_get_features,
10491063
.link_change_notify = aqr107_link_change_notify,
10501064
.led_brightness_set = aqr_phy_led_brightness_set,
10511065
.led_hw_is_supported = aqr_phy_led_hw_is_supported,

0 commit comments

Comments
 (0)