This is an automatic generated email to let you know that the following patch 
were queued:

Subject: media: mtk-jpeg: Remove cancel worker in mtk_jpeg_remove to avoid the 
crash of multi-core JPEG devices
Author:  Zheng Wang <zyytlz...@163.com>
Date:    Mon Nov 6 15:48:09 2023 +0100

This patch reverts commit c677d7ae8314
("media: mtk-jpeg: Fix use after free bug due to uncanceled work").
The job_timeout_work is initialized only for
the single-core JPEG device so it will cause the crash for multi-core
JPEG devices.

Fix it by removing the cancel_delayed_work_sync function.

Fixes: c677d7ae8314 ("media: mtk-jpeg: Fix use after free bug due to uncanceled 
work")
Signed-off-by: Zheng Wang <zyytlz...@163.com>
Signed-off-by: Dmitry Osipenko <dmitry.osipe...@collabora.com>
Signed-off-by: Hans Verkuil <hverkuil-ci...@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mche...@kernel.org>

 drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c | 1 -
 1 file changed, 1 deletion(-)

---

diff --git a/drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c 
b/drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c
index 73a063b1569b..7c2e6a2f6c40 100644
--- a/drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c
+++ b/drivers/media/platform/mediatek/jpeg/mtk_jpeg_core.c
@@ -1402,7 +1402,6 @@ static void mtk_jpeg_remove(struct platform_device *pdev)
 {
        struct mtk_jpeg_dev *jpeg = platform_get_drvdata(pdev);
 
-       cancel_delayed_work_sync(&jpeg->job_timeout_work);
        pm_runtime_disable(&pdev->dev);
        video_unregister_device(jpeg->vdev);
        v4l2_m2m_release(jpeg->m2m_dev);

_______________________________________________
linuxtv-commits mailing list
linuxtv-commits@linuxtv.org
https://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits

Reply via email to