Browse Source

dmaengine: qcom_hidma: kill the tasklets upon exit

drivers should ensure that tasklets are killed, so that they can't be
run after driver remove is executed

Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Acked-by: Sinan Kaya <okaya@codeaurora.org>
Vinod Koul 9 years ago
parent
commit
bd16934a56
1 changed files with 1 additions and 0 deletions
  1. 1 0
      drivers/dma/qcom/hidma.c

+ 1 - 0
drivers/dma/qcom/hidma.c

@@ -708,6 +708,7 @@ static int hidma_remove(struct platform_device *pdev)
 	pm_runtime_get_sync(dmadev->ddev.dev);
 	pm_runtime_get_sync(dmadev->ddev.dev);
 	dma_async_device_unregister(&dmadev->ddev);
 	dma_async_device_unregister(&dmadev->ddev);
 	devm_free_irq(dmadev->ddev.dev, dmadev->irq, dmadev->lldev);
 	devm_free_irq(dmadev->ddev.dev, dmadev->irq, dmadev->lldev);
+	tasklet_kill(&dmadev->task);
 	hidma_debug_uninit(dmadev);
 	hidma_debug_uninit(dmadev);
 	hidma_ll_uninit(dmadev->lldev);
 	hidma_ll_uninit(dmadev->lldev);
 	hidma_free(dmadev);
 	hidma_free(dmadev);