Re: [PATCH v2 08/10] dmaengine: imx-sdma: make use of devm_add_action_or_reset to unregiser the dma_device
From: Peng Fan <hidden>
Date: 2025-09-12 02:51:29
Also in:
dmaengine, imx, lkml
From: Peng Fan <hidden>
Date: 2025-09-12 02:51:29
Also in:
dmaengine, imx, lkml
On Thu, Sep 11, 2025 at 11:56:49PM +0200, Marco Felsch wrote:
Make use of the devm_add_action_or_reset() to register a custom devm_ release hook. This is required to turn off the IRQs before calling dma_async_device_unregister(). Furthermore it removes the last goto error handling within probe() and trims the remove(). Make use of disable_irq() and let the devm-irq do the job to free the IRQ, because the only purpose of using devm_free_irq() was to disable the IRQ before calling dma_async_device_unregister(). Signed-off-by: Marco Felsch <redacted>
Reviewed-by: Peng Fan <peng.fan@nxp.com>