[PATCH 5/7] net: phy: dp83867: remove explicit setting of cfg2
Michael Tretter
m.tretter at pengutronix.de
Fri Mar 19 13:10:14 GMT 2021
From: Thomas Haemmerle <thomas.haemmerle at wolfvision.net>
Setting cfg2 is superfluous, because it just sets the default value.
Remove it.
Signed-off-by: Thomas Haemmerle <thomas.haemmerle at wolfvision.net>
Signed-off-by: Michael Tretter <m.tretter at pengutronix.de>
---
drivers/net/phy/dp83867.c | 11 +----------
1 file changed, 1 insertion(+), 10 deletions(-)
diff --git a/drivers/net/phy/dp83867.c b/drivers/net/phy/dp83867.c
index e796498c4a18..dd769b4d3e38 100644
--- a/drivers/net/phy/dp83867.c
+++ b/drivers/net/phy/dp83867.c
@@ -180,7 +180,7 @@ static int dp83867_config_init(struct phy_device *phydev)
{
struct dp83867_private *dp83867;
int ret;
- u16 val, delay, cfg2;
+ u16 val, delay;
if (!phydev->priv) {
dp83867 = kzalloc(sizeof(*dp83867), GFP_KERNEL);
@@ -254,15 +254,6 @@ static int dp83867_config_init(struct phy_device *phydev)
phy_write(phydev, MII_BMCR,
BMCR_ANENABLE | BMCR_FULLDPLX | BMCR_SPEED1000);
- cfg2 = phy_read(phydev, MII_DP83867_CFG2);
- cfg2 &= MII_DP83867_CFG2_MASK;
- cfg2 |= MII_DP83867_CFG2_SPEEDOPT_10EN |
- MII_DP83867_CFG2_SGMII_AUTONEGEN |
- MII_DP83867_CFG2_SPEEDOPT_ENH |
- MII_DP83867_CFG2_SPEEDOPT_CNT |
- MII_DP83867_CFG2_SPEEDOPT_INTLOW;
- phy_write(phydev, MII_DP83867_CFG2, cfg2);
-
phy_write_mmd_indirect(phydev, DP83867_RGMIICTL,
DP83867_DEVADDR, 0x0);
--
2.29.2
More information about the barebox
mailing list