mirror of
https://github.com/torvalds/linux.git
synced 2026-06-07 14:04:54 +02:00
media: mtk-jpeg: Remove cancel worker in mtk_jpeg_remove to avoid the crash of multi-core JPEG devices
[ Upstream commitd8212c5c87] This patch reverts commitc677d7ae83("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:c677d7ae83("media: mtk-jpeg: Fix use after free bug due to uncanceled work") Signed-off-by: Zheng Wang <zyytlz.wz@163.com> Signed-off-by: Dmitry Osipenko <dmitry.osipenko@collabora.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
2cf0005d31
commit
2cb808af77
|
|
@ -1403,7 +1403,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);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user