net: phy: improve genphy_c45_read_link
authorHeiner Kallweit <hkallweit1@gmail.com>
Tue, 5 Feb 2019 19:41:37 +0000 (20:41 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 7 Feb 2019 03:46:49 +0000 (19:46 -0800)
commita6e11f6bbd29a92d1357c2f3033a70fb1b767432
treef0a684d83cb537dbfbd6106bf48c1d97339e2dd9
parent7d8e249f393a1aca30bde876e932401d2c78bc9f
net: phy: improve genphy_c45_read_link

Let's make genphy_c45_read_link behave the same as genphy_update_link
and set phydev->link in the function directly. This allows to simplify
the callers. In addition don't check further devices once we detect
that at least one device reports link as down.

v2:
- remove an unused variable

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/marvell10g.c
drivers/net/phy/phy-c45.c