WSL2-Linux-Kernel/drivers/gpu/drm/virtio
Jiri Slaby b513b0d456 drm/virtio: fix OOB in virtio_gpu_object_create
After commit f651c8b055 ("drm/virtio: factor out the sg_table from
virtio_gpu_object"), virtio_gpu_create_object allocates too small space
to fit everything in. It is because it allocates struct
virtio_gpu_object, but should allocate a newly added struct
virtio_gpu_object_shmem which has 2 more members.

So fix that by using correct type in virtio_gpu_create_object.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Link: http://patchwork.freedesktop.org/patch/msgid/20200319100421.16267-1-jslaby@suse.cz
Fixes: f651c8b055 ("drm/virtio: factor out the sg_table from virtio_gpu_object")
Cc: Gurchetan Singh <gurchetansingh@chromium.org>
Cc: Gerd Hoffmann <kraxel@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
(cherry picked from commit 0666a8d7f6)
2020-04-06 15:10:37 +02:00
..
Kconfig drm/virtio: switch from ttm to gem shmem helpers 2019-09-04 06:54:11 +02:00
Makefile drm/virtio: switch from ttm to gem shmem helpers 2019-09-04 06:54:11 +02:00
virtgpu_debugfs.c drm/virtio: fix ring free check 2020-02-07 09:33:55 +01:00
virtgpu_display.c drm/virtio: batch plane updates (pageflip) 2020-02-17 14:50:49 +01:00
virtgpu_drv.c drm/virtio: add drm_driver.release callback. 2020-02-12 10:24:08 +01:00
virtgpu_drv.h drm/virtio: add case for shmem objects in virtio_gpu_cleanup_object(..) 2020-03-09 10:44:34 +01:00
virtgpu_fence.c drm/virtio: move to_virtio_fence inside virtgpu_fence 2019-12-19 07:13:46 +01:00
virtgpu_gem.c drm/virtio: move remaining virtio_gpu_notify calls 2020-02-17 14:50:50 +01:00
virtgpu_ioctl.c drm/virtio: enqueue virtio_gpu_create_context after the first 3D ioctl 2020-02-25 09:48:42 +01:00
virtgpu_kms.c drm/virtio: enqueue virtio_gpu_create_context after the first 3D ioctl 2020-02-25 09:48:42 +01:00
virtgpu_object.c drm/virtio: fix OOB in virtio_gpu_object_create 2020-04-06 15:10:37 +02:00
virtgpu_plane.c drm/virtio: batch plane updates (pageflip) 2020-02-17 14:50:49 +01:00
virtgpu_prime.c drm/virtio: switch from ttm to gem shmem helpers 2019-09-04 06:54:11 +02:00
virtgpu_trace.h drm/virtio: add trace events for commands 2019-05-06 10:52:58 +02:00
virtgpu_trace_points.c drm/virtio: add trace events for commands 2019-05-06 10:52:58 +02:00
virtgpu_vq.c drm/virtio: factor out the sg_table from virtio_gpu_object 2020-03-09 10:44:34 +01:00