summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChuhong Yuan <hslester96@gmail.com>2019-11-13 07:37:59 +0100
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>2019-12-13 09:18:35 +0100
commit76669f2e7c5812e884f37b213b6fe8b369ca4333 (patch)
tree745bfab3446527ace46c40d1b81546bf7ee3fcb2
parent8ea1c5af489a76275bab36ad378452be18210c77 (diff)
media: platform: mtk-mdp: add missed destroy_workqueue in remove
The driver misses destroying wdt_wq when remove like what is done when probe fails. Add the missed calls like what is done to job_wq to fix it. Signed-off-by: Chuhong Yuan <hslester96@gmail.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
-rw-r--r--drivers/media/platform/mtk-mdp/mtk_mdp_core.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/media/platform/mtk-mdp/mtk_mdp_core.c b/drivers/media/platform/mtk-mdp/mtk_mdp_core.c
index c1e29a46ae69..aeaed2cf4458 100644
--- a/drivers/media/platform/mtk-mdp/mtk_mdp_core.c
+++ b/drivers/media/platform/mtk-mdp/mtk_mdp_core.c
@@ -229,6 +229,9 @@ static int mtk_mdp_remove(struct platform_device *pdev)
mtk_mdp_unregister_m2m_device(mdp);
v4l2_device_unregister(&mdp->v4l2_dev);
+ flush_workqueue(mdp->wdt_wq);
+ destroy_workqueue(mdp->wdt_wq);
+
flush_workqueue(mdp->job_wq);
destroy_workqueue(mdp->job_wq);