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

Commit a3f89d26 authored by Florian Fainelli's avatar Florian Fainelli Committed by Greg Kroah-Hartman
Browse files

net: phy: Keep reporting transceiver type



commit ceb628134a75564d7bfa8e4ef902e6e588339e11 upstream.

With commit 2d55173e ("phy: add generic function to support
ksetting support"), we lost the ability to report the transceiver type
like we used to. Now that we have added back the transceiver type to
ethtool_link_settings, we can report it back like we used to and have no
loss of information.

Fixes: 3f1ac7a7 ("net: ethtool: add new ETHTOOL_xLINKSETTINGS API")
Fixes: 2d55173e ("phy: add generic function to support ksetting support")
Signed-off-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e9cd6721
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -463,7 +463,8 @@ int phy_ethtool_ksettings_get(struct phy_device *phydev,
		cmd->base.port = PORT_BNC;
	else
		cmd->base.port = PORT_MII;

	cmd->base.transceiver = phy_is_internal(phydev) ?
				XCVR_INTERNAL : XCVR_EXTERNAL;
	cmd->base.phy_address = phydev->mdio.addr;
	cmd->base.autoneg = phydev->autoneg;
	cmd->base.eth_tp_mdix_ctrl = phydev->mdix;