amd-xgbe-phy: Use the phy_driver flags field
authorLendacky, Thomas <Thomas.Lendacky@amd.com>
Fri, 20 Mar 2015 16:49:53 +0000 (11:49 -0500)
committerDavid S. Miller <davem@davemloft.net>
Fri, 20 Mar 2015 20:33:56 +0000 (16:33 -0400)
Remove the setting of the transceiver type when retrieving the device
settings using ethtool and instead set the transceiver type in the
phy_driver structure flags field. Change the transceiver type to be
internal, also.

Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c
drivers/net/phy/amd-xgbe-phy.c

index ebf489351555b19411d055a12c9812c08f73dd1c..43e5571fe858e5ee87b273ff6fdf73c7708e70b5 100644 (file)
@@ -291,7 +291,6 @@ static int xgbe_get_settings(struct net_device *netdev,
                return -ENODEV;
 
        ret = phy_ethtool_gset(pdata->phydev, cmd);
-       cmd->transceiver = XCVR_EXTERNAL;
 
        DBGPR("<--xgbe_get_settings\n");
 
index acb444928c76f8408e7375481767631576364520..4b95caf08aa9a3ad7a43ba8eff390d3e1dc727d8 100644 (file)
@@ -1816,6 +1816,7 @@ static struct phy_driver amd_xgbe_phy_driver[] = {
                .phy_id_mask            = XGBE_PHY_MASK,
                .name                   = "AMD XGBE PHY",
                .features               = 0,
+               .flags                  = PHY_IS_INTERNAL,
                .probe                  = amd_xgbe_phy_probe,
                .remove                 = amd_xgbe_phy_remove,
                .soft_reset             = amd_xgbe_phy_soft_reset,