Skip to content
Commit 43f561e8 authored by Sui Jingfeng's avatar Sui Jingfeng Committed by Greg Kroah-Hartman
Browse files

drm/mediatek: Fix potential memory leak if vmap() fail



[ Upstream commit 379091e0 ]

Also return -ENOMEM if such a failure happens, the implement should take
responsibility for the error handling.

Fixes: 3df64d7b ("drm/mediatek: Implement gem prime vmap/vunmap function")
Reviewed-by: default avatarMatthias Brugger <matthias.bgg@gmail.com>
Reviewed-by: default avatarAlexandre Mergnat <amergnat@baylibre.com>
Signed-off-by: default avatarSui Jingfeng <suijingfeng@loongson.cn>
Reviewed-by: default avatarCK Hu <ck.hu@mediatek.com>
Reviewed-by: default avatarAngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://patchwork.kernel.org/project/dri-devel/patch/20230706134000.130098-1-suijingfeng@loongson.cn/


Signed-off-by: default avatarChun-Kuang Hu <chunkuang.hu@kernel.org>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 26551554
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment