Skip to content

Commit 77e75fd

Browse files
rgenoudvinodkoul
authored andcommitted
dmaengine: at_hdmac: fix module unloading
of_dma_controller_free() was not called on module onloading. This lead to a soft lockup: watchdog: BUG: soft lockup - CPU#0 stuck for 23s! Modules linked in: at_hdmac [last unloaded: at_hdmac] when of_dma_request_slave_channel() tried to call ofdma->of_dma_xlate(). Cc: stable@vger.kernel.org Fixes: bbe89c8 ("at_hdmac: move to generic DMA binding") Acked-by: Ludovic Desroches <ludovic.desroches@microchip.com> Signed-off-by: Richard Genoud <richard.genoud@gmail.com> Signed-off-by: Vinod Koul <vkoul@kernel.org>
1 parent 98f5f93 commit 77e75fd

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

drivers/dma/at_hdmac.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2006,6 +2006,8 @@ static int at_dma_remove(struct platform_device *pdev)
20062006
struct resource *io;
20072007

20082008
at_dma_off(atdma);
2009+
if (pdev->dev.of_node)
2010+
of_dma_controller_free(pdev->dev.of_node);
20092011
dma_async_device_unregister(&atdma->dma_common);
20102012

20112013
dma_pool_destroy(atdma->memset_pool);

0 commit comments

Comments
 (0)