OSDN Git Service

drm/vgem: add missing mutex_destroy
authorMaíra Canal <mcanal@igalia.com>
Thu, 2 Feb 2023 12:55:17 +0000 (09:55 -0300)
committerMaíra Canal <mairacanal@riseup.net>
Fri, 10 Feb 2023 11:21:04 +0000 (08:21 -0300)
commit7c18189b14b33c1fbf76480b1bd217877c086e67
tree3e4d0b9935678218d4ed37498eb0dde6eb33b5dd
parent96a7b60f6ddb2bc966fac800c1dd18876a6e3c3f
drm/vgem: add missing mutex_destroy

vgem_fence_open() instantiates a mutex for a particular fence
instance, but never destroys it by calling mutex_destroy() in
vgem_fence_close().

So, add the missing mutex_destroy() to guarantee proper resource
destruction.

Fixes: 407779848445 ("drm/vgem: Attach sw fences to exported vGEM dma-buf (ioctl)")
Signed-off-by: Maíra Canal <mcanal@igalia.com>
Reviewed-by: Stanislaw Gruszka <stanislaw.gruszka@linux.intel.com>
Signed-off-by: Maíra Canal <mairacanal@riseup.net>
Link: https://patchwork.freedesktop.org/patch/msgid/20230202125517.427976-1-mcanal@igalia.com
drivers/gpu/drm/vgem/vgem_fence.c