Skip to content

Commit 12f5908

Browse files
tmlindVinod Koul
authored andcommitted
dmaengine: cppi41: Fix list not empty warning on module removal
If musb controller is configured with USB peripherals and we have enumerated with a USB host, we can get warnings on removal of the modules: WARNING: CPU: 0 PID: 1269 at drivers/dma/cppi41.c:391 cppi41_dma_free_chan_resources Fix the issue by adding the missing pm_runtime_get to cppi41_dma_free_chan_resources to make sure the pending work list is cleared on removal. Fixes: fdea2d0 ("dmaengine: cppi41: Add basic PM runtime support") Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
1 parent f732c5b commit 12f5908

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

drivers/dma/cppi41.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1072,7 +1072,12 @@ static int cppi41_dma_probe(struct platform_device *pdev)
10721072
static int cppi41_dma_remove(struct platform_device *pdev)
10731073
{
10741074
struct cppi41_dd *cdd = platform_get_drvdata(pdev);
1075+
int error;
10751076

1077+
error = pm_runtime_get_sync(&pdev->dev);
1078+
if (error < 0)
1079+
dev_err(&pdev->dev, "%s could not pm_runtime_get: %i\n",
1080+
__func__, error);
10761081
of_dma_controller_free(pdev->dev.of_node);
10771082
dma_async_device_unregister(&cdd->ddev);
10781083

0 commit comments

Comments
 (0)