diff options
author | Jose Abreu | 2019-06-28 09:29:13 +0200 |
---|---|---|
committer | David S. Miller | 2019-06-28 18:23:39 +0200 |
commit | 5b1117704d4c59f5dc8df033e418f02838d4a130 (patch) | |
tree | de3f7f11c5e02d895b635bab2bbf838b09cb1c95 /drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | |
parent | net: stmmac: dwxgmac: Enable EDMA by default (diff) | |
download | kernel-qcow2-linux-5b1117704d4c59f5dc8df033e418f02838d4a130.tar.gz kernel-qcow2-linux-5b1117704d4c59f5dc8df033e418f02838d4a130.tar.xz kernel-qcow2-linux-5b1117704d4c59f5dc8df033e418f02838d4a130.zip |
net: stmmac: Do not try to enable PHY EEE if MAC does not support it
Do not enable EEE feature in the PHY if MAC does not support it.
Signed-off-by: Jose Abreu <joabreu@synopsys.com>
Cc: Joao Pinto <jpinto@synopsys.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Cc: Alexandre Torgue <alexandre.torgue@st.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/stmicro/stmmac/stmmac_main.c')
-rw-r--r-- | drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c index 91f24b63ea16..0b1900bf4e9e 100644 --- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c +++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c @@ -896,7 +896,7 @@ static void stmmac_mac_link_up(struct phylink_config *config, struct stmmac_priv *priv = netdev_priv(to_net_dev(config->dev)); stmmac_mac_set(priv, priv->ioaddr, true); - if (phy) { + if (phy && priv->dma_cap.eee) { priv->eee_active = phy_init_eee(phy, 1) >= 0; priv->eee_enabled = stmmac_eee_init(priv); stmmac_set_eee_pls(priv, priv->hw, true); |