]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
drm/qxl: fix memory leak in release list handling
authorDave Airlie <airlied@redhat.com>
Thu, 28 Nov 2013 05:39:03 +0000 (05:39 +0000)
committerDave Airlie <airlied@redhat.com>
Thu, 28 Nov 2013 22:36:15 +0000 (08:36 +1000)
wow no idea how I got this far without seeing this,
leaking the entries in the list makes kmalloc-64 slab grow.

References: https://bugzilla.kernel.org/show_bug.cgi?id=65121
Cc: stable@vger.kernel.org
Reported-by: Matthew Stapleton <matthew4196@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/qxl/qxl_release.c

index 0109a9644cb29ef7a6e13ac76a90544effcefd20..821ab7b9409bb866c61d793c4e0ab9d63d73ec98 100644 (file)
@@ -92,6 +92,7 @@ qxl_release_free(struct qxl_device *qdev,
                                                - DRM_FILE_OFFSET);
                qxl_fence_remove_release(&bo->fence, release->id);
                qxl_bo_unref(&bo);
+               kfree(entry);
        }
        spin_lock(&qdev->release_idr_lock);
        idr_remove(&qdev->release_idr, release->id);