diff options
author | Nicolas Saenz Julienne <nsaenzjulienne@suse.de> | 2020-02-20 17:36:31 +0100 |
---|---|---|
committer | Matthias Brugger <mbrugger@suse.com> | 2020-05-12 10:59:11 +0200 |
commit | 57805f2270c4a47cbc221e0920c58654f7748f0b (patch) | |
tree | f55e889bdd9b0234cc7e7db7f0ec7b001d35a04c | |
parent | 2a38d2239d0bb4d128b00886bf097ab247a0b1a7 (diff) |
net: bcmgenet: Don't set ID_MODE_DIS when not using RGMII
As per Linux's driver, ID_MODE_DIS is only set when the PHY interface is
RGMII. Don't enable it for the rest of setups.
This has been seen to misconfigure RPi4's PHY when booting Linux.
Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: Matthias Brugger <mbrugger@suse.com>
-rw-r--r-- | drivers/net/bcmgenet.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/net/bcmgenet.c b/drivers/net/bcmgenet.c index 8f4848aec6..e971b556ac 100644 --- a/drivers/net/bcmgenet.c +++ b/drivers/net/bcmgenet.c @@ -448,7 +448,10 @@ static int bcmgenet_adjust_link(struct bcmgenet_eth_priv *priv) } clrsetbits_32(priv->mac_reg + EXT_RGMII_OOB_CTRL, OOB_DISABLE, - RGMII_LINK | RGMII_MODE_EN | ID_MODE_DIS); + RGMII_LINK | RGMII_MODE_EN); + + if (phy_dev->interface == PHY_INTERFACE_MODE_RGMII) + setbits_32(priv->mac_reg + EXT_RGMII_OOB_CTRL, ID_MODE_DIS); writel(speed << CMD_SPEED_SHIFT, (priv->mac_reg + UMAC_CMD)); |