All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next] mtd: st_spi_fsm: add missing clk_disable_unprepare() stfsm_remove()
@ 2022-05-13 10:03 ` Yang Yingliang
  0 siblings, 0 replies; 8+ messages in thread
From: Yang Yingliang @ 2022-05-13 10:03 UTC (permalink / raw)
  To: linux-kernel, linux-mtd; +Cc: miquel.raynal, richard, vigneshr

Clock source is prepared and enabled by clk_prepare_enable()
in probe function, but no disable or unprepare in remove function.

Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
---
 drivers/mtd/devices/st_spi_fsm.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/mtd/devices/st_spi_fsm.c b/drivers/mtd/devices/st_spi_fsm.c
index 983999c020d6..d3377b10fc0f 100644
--- a/drivers/mtd/devices/st_spi_fsm.c
+++ b/drivers/mtd/devices/st_spi_fsm.c
@@ -2126,6 +2126,8 @@ static int stfsm_remove(struct platform_device *pdev)
 {
 	struct stfsm *fsm = platform_get_drvdata(pdev);
 
+	clk_disable_unprepare(fsm->clk);
+
 	return mtd_device_unregister(&fsm->mtd);
 }
 
-- 
2.25.1


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2022-05-16  7:51 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-05-13 10:03 [PATCH -next] mtd: st_spi_fsm: add missing clk_disable_unprepare() stfsm_remove() Yang Yingliang
2022-05-13 10:03 ` Yang Yingliang
2022-05-13 10:22 ` Miquel Raynal
2022-05-13 10:22   ` Miquel Raynal
2022-05-14  2:12   ` Yang Yingliang
2022-05-14  2:12     ` Yang Yingliang
2022-05-16  7:51     ` Miquel Raynal
2022-05-16  7:51       ` Miquel Raynal

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.