mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-03-21 23:16:50 +08:00
drm/vmwgfx: Don't overwrite KMS surface dirty tracker
We were overwriting the surface's dirty tracker here causing a memory leak.
Reported-by: Mika Penttilä <mpenttil@redhat.com>
Closes: https://lore.kernel.org/dri-devel/8c53f3c6-c6de-46fe-a8ca-d98dd52b3abe@redhat.com/
Fixes: 965544150d ("drm/vmwgfx: Refactor cursor handling")
Signed-off-by: Ian Forbes <ian.forbes@broadcom.com>
Reviewed-by: Maaz Mombasawala <maaz.mombasawala@broadcom.com>
Signed-off-by: Zack Rusin <zack.rusin@broadcom.com>
Link: https://patch.msgid.link/20260302200330.66763-1-ian.forbes@broadcom.com
This commit is contained in:
@@ -771,7 +771,8 @@ err_out:
|
||||
ret = vmw_bo_dirty_add(bo);
|
||||
if (!ret && surface && surface->res.func->dirty_alloc) {
|
||||
surface->res.coherent = true;
|
||||
ret = surface->res.func->dirty_alloc(&surface->res);
|
||||
if (surface->res.dirty == NULL)
|
||||
ret = surface->res.func->dirty_alloc(&surface->res);
|
||||
}
|
||||
ttm_bo_unreserve(&bo->tbo);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user