]> git.baikalelectronics.ru Git - kernel.git/commit
stmmac: dwmac-mediatek: fix clock issue
authorBiao Huang <biao.huang@mediatek.com>
Thu, 14 Jul 2022 06:00:12 +0000 (14:00 +0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 15 Jul 2022 11:06:55 +0000 (12:06 +0100)
commit29371a72f72d715fd1ddd200071129c5bbed89ff
tree2ba95eaa0db4ae9e206d05ee176d84774d645e40
parente69302b939540232333afb630b90d104c452d7ad
stmmac: dwmac-mediatek: fix clock issue

The pm_runtime takes care of the clock handling in current
stmmac drivers, and dwmac-mediatek implement the
mediatek_dwmac_clks_config() as the callback for pm_runtime.

Then, stripping duplicated clocks handling in old init()/exit()
to fix clock issue in suspend/resume test.

As to clocks in probe/remove, vendor need symmetric handling to
ensure clocks balance.

Test pass, including suspend/resume and ko insertion/remove.

Fixes: b75543f5c6da ("stmmac: dwmac-mediatek: add platform level clocks management")
Signed-off-by: Biao Huang <biao.huang@mediatek.com>
Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/stmicro/stmmac/dwmac-mediatek.c