• Heiner Kallweit's avatar
    net: phy: check PMAPMD link status only in genphy_c45_read_link · c1164bb1
    Heiner Kallweit authored
    The current code reports a link as up if all devices (except a few
    blacklisted ones) report the link as up. This breaks Aquantia AQCS109
    for lower speeds because on this PHY the PCS link status reflects a
    10G link only. For Marvell there's a similar issue, therefore PHYXS
    device isn't checked.
    
    There may be more PHYs where depending on the mode the link status
    of only selected devices is relevant.
    
    For now it seems to be sufficient to check the link status of the
    PMAPMD device only. Leave the loop in the code to be prepared in
    case we have to add functionality to check more than one device,
    depending on the mode.
    
    Successfully tested on a board with an AQCS109.
    Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    c1164bb1
phy-c45.c 13.8 KB