]> git.baikalelectronics.ru Git - kernel.git/commit
drm/shmem-helper: Remove errant put in error path
authorRob Clark <robdclark@chromium.org>
Wed, 30 Nov 2022 18:57:47 +0000 (10:57 -0800)
committerJavier Martinez Canillas <javierm@redhat.com>
Sun, 4 Dec 2022 17:56:52 +0000 (18:56 +0100)
commit24013314be6ee4ee456114a671e9fa3461323de8
tree1f97a7f8c3724b0c76202bcdb2569205f8ace9a2
parentd3d6b1bf85aefe0ebc0624574b3bb62f0693914c
drm/shmem-helper: Remove errant put in error path

drm_gem_shmem_mmap() doesn't own this reference, resulting in the GEM
object getting prematurely freed leading to a later use-after-free.

Link: https://syzkaller.appspot.com/bug?extid=c8ae65286134dd1b800d
Reported-by: syzbot+c8ae65286134dd1b800d@syzkaller.appspotmail.com
Fixes: 2194a63a818d ("drm: Add library for shmem backed GEM objects")
Cc: stable@vger.kernel.org
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20221130185748.357410-2-robdclark@gmail.com
drivers/gpu/drm/drm_gem_shmem_helper.c