]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
net: stmmac: dwmac-sun8i: Balance internal PHY power
authorSamuel Holland <samuel@sholland.org>
Sun, 3 Jan 2021 11:17:43 +0000 (05:17 -0600)
committerDavid S. Miller <davem@davemloft.net>
Wed, 6 Jan 2021 00:32:08 +0000 (16:32 -0800)
commitb8239638853e3e37b287e4bd4d57b41f14c78550
tree69c3157871105eb3434fce67ebfb1efcf55110cc
parent529254216773acd5039c07aa18cf06fd1f9fccdd
net: stmmac: dwmac-sun8i: Balance internal PHY power

sun8i_dwmac_exit calls sun8i_dwmac_unpower_internal_phy, but
sun8i_dwmac_init did not call sun8i_dwmac_power_internal_phy. This
caused PHY power to remain off after a suspend/resume cycle. Fix this by
recording if PHY power should be restored, and if so, restoring it.

Fixes: 634db83b8265 ("net: stmmac: dwmac-sun8i: Handle integrated/external MDIOs")
Signed-off-by: Samuel Holland <samuel@sholland.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c