* [PATCH] net: ethernet: arc: add the missed clk_disable_unprepare
@ 2019-11-01 12:17 Chuhong Yuan
2019-11-01 17:25 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Chuhong Yuan @ 2019-11-01 12:17 UTC (permalink / raw)
Cc: David S . Miller, Heiko Stuebner, netdev, linux-arm-kernel,
linux-rockchip, linux-kernel, Chuhong Yuan
The remove misses to disable and unprepare priv->macclk like what is done
when probe fails.
Add the missed call in remove.
Signed-off-by: Chuhong Yuan <hslester96@gmail.com>
---
drivers/net/ethernet/arc/emac_rockchip.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/ethernet/arc/emac_rockchip.c b/drivers/net/ethernet/arc/emac_rockchip.c
index 42d2e1b02c44..664d664e0925 100644
--- a/drivers/net/ethernet/arc/emac_rockchip.c
+++ b/drivers/net/ethernet/arc/emac_rockchip.c
@@ -256,6 +256,9 @@ static int emac_rockchip_remove(struct platform_device *pdev)
if (priv->regulator)
regulator_disable(priv->regulator);
+ if (priv->soc_data->need_div_macclk)
+ clk_disable_unprepare(priv->macclk);
+
free_netdev(ndev);
return err;
}
--
2.23.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] net: ethernet: arc: add the missed clk_disable_unprepare
2019-11-01 12:17 [PATCH] net: ethernet: arc: add the missed clk_disable_unprepare Chuhong Yuan
@ 2019-11-01 17:25 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2019-11-01 17:25 UTC (permalink / raw)
To: hslester96; +Cc: heiko, netdev, linux-arm-kernel, linux-rockchip, linux-kernel
From: Chuhong Yuan <hslester96@gmail.com>
Date: Fri, 1 Nov 2019 20:17:25 +0800
> The remove misses to disable and unprepare priv->macclk like what is done
> when probe fails.
> Add the missed call in remove.
>
> Signed-off-by: Chuhong Yuan <hslester96@gmail.com>
Applied, thank you.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-11-01 17:25 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-01 12:17 [PATCH] net: ethernet: arc: add the missed clk_disable_unprepare Chuhong Yuan
2019-11-01 17:25 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).