]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
dmaengine: fsl-edma: don't explicitly disable clocks in .remove()
authorJared Kangas <jkangas@redhat.com>
Tue, 13 Jan 2026 19:46:50 +0000 (11:46 -0800)
committerVinod Koul <vkoul@kernel.org>
Wed, 4 Feb 2026 16:58:07 +0000 (22:28 +0530)
The clocks in fsl_edma_engine::muxclk are allocated and enabled with
devm_clk_get_enabled(), which automatically cleans these resources up,
but these clocks are also manually disabled in fsl_edma_remove(). This
causes warnings on driver removal for each clock:

        edma_module already disabled
        WARNING: CPU: 0 PID: 418 at drivers/clk/clk.c:1200 clk_core_disable+0x198/0x1c8
        [...]
        Call trace:
         clk_core_disable+0x198/0x1c8 (P)
         clk_disable+0x34/0x58
         fsl_edma_remove+0x74/0xe8 [fsl_edma]
         [...]
        ---[ end trace 0000000000000000 ]---
        edma_module already unprepared
        WARNING: CPU: 0 PID: 418 at drivers/clk/clk.c:1059 clk_core_unprepare+0x1f8/0x220
        [...]
        Call trace:
         clk_core_unprepare+0x1f8/0x220 (P)
         clk_unprepare+0x34/0x58
         fsl_edma_remove+0x7c/0xe8 [fsl_edma]
         [...]
        ---[ end trace 0000000000000000 ]---

Fix these warnings by removing the unnecessary fsl_disable_clocks() call
in fsl_edma_remove().

Fixes: a9903de3aa16 ("dmaengine: fsl-edma: refactor using devm_clk_get_enabled")
Signed-off-by: Jared Kangas <jkangas@redhat.com>
Reviewed-by: Frank Li <Frank.Li@nxp.com>
Link: https://patch.msgid.link/20260113-fsl-edma-clock-removal-v1-1-2025b49e7bcc@redhat.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/dma/fsl-edma-main.c

index a753b7cbfa7a3369d17314bc5bc9139c9f8e5c27..dbcdd1e68319005dfab85a6c28b4e3f929f29132 100644 (file)
@@ -915,7 +915,6 @@ static void fsl_edma_remove(struct platform_device *pdev)
        of_dma_controller_free(np);
        dma_async_device_unregister(&fsl_edma->dma_dev);
        fsl_edma_cleanup_vchan(&fsl_edma->dma_dev);
-       fsl_disable_clocks(fsl_edma, fsl_edma->drvdata->dmamuxs);
 }
 
 static int fsl_edma_suspend_late(struct device *dev)