• Heiner Kallweit's avatar
    net: phy: prepare phylib to deal with PHY's extending Clause 22 · f4069cd7
    Heiner Kallweit authored
    The integrated PHY in 2.5Gbps chip RTL8125 is the first (known to me)
    PHY that uses standard Clause 22 for all modes up to 1Gbps and adds
    2.5Gbps control using vendor-specific registers. To use phylib for
    the standard part little extensions are needed:
    - Move most of genphy_config_aneg to a new function
      __genphy_config_aneg that takes a parameter whether restarting
      auto-negotiation is needed (depending on whether content of
      vendor-specific advertisement register changed).
    - Don't clear phydev->lp_advertising in genphy_read_status so that
      we can set non-C22 mode flags before.
    
    Basically both changes mimic the behavior of the equivalent Clause 45
    functions.
    Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    f4069cd7
phy_device.c 63.3 KB