linux/drivers/gpu/drm/vmwgfx
Zack Rusin a309c7194e drm/vmwgfx: Remove rcu locks from user resources
User resource lookups used rcu to avoid two extra atomics. Unfortunately
the rcu paths were buggy and it was easy to make the driver crash by
submitting command buffers from two different threads. Because the
lookups never show up in performance profiles replace them with a
regular spin lock which fixes the races in accesses to those shared
resources.

Fixes kernel oops'es in IGT's vmwgfx execution_buffer stress test and
seen crashes with apps using shared resources.

Fixes: e14c02e6b6 ("drm/vmwgfx: Look up objects without taking a reference")
Signed-off-by: Zack Rusin <zackr@vmware.com>
Reviewed-by: Martin Krastev <krastevm@vmware.com>
Reviewed-by: Maaz Mombasawala <mombasawalam@vmware.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20221207172907.959037-1-zack@kde.org
2023-01-09 21:15:36 -05:00
..
device_include drm/vmwgfx: cleanup comments 2022-08-04 11:30:46 -04:00
Kconfig drm/vmwgfx: Port the framebuffer code to drm fb helpers 2022-10-25 12:42:27 -04:00
Makefile drm/vmwgfx: Port the framebuffer code to drm fb helpers 2022-10-25 12:42:27 -04:00
ttm_object.c drm/vmwgfx: Remove rcu locks from user resources 2023-01-09 21:15:36 -05:00
ttm_object.h drm/vmwgfx: Remove rcu locks from user resources 2023-01-09 21:15:36 -05:00
vmw_surface_cache.h
vmwgfx_binding.c
vmwgfx_binding.h
vmwgfx_blit.c drm/ttm: rework on ttm_resource to use size_t type 2022-10-27 11:42:58 +02:00
vmwgfx_bo.c drm/vmwgfx: Remove rcu locks from user resources 2023-01-09 21:15:36 -05:00
vmwgfx_cmd.c drm/vmwgfx: Disable command buffers on svga3 without gbobjects 2022-03-21 10:10:36 -04:00
vmwgfx_cmdbuf.c
vmwgfx_cmdbuf_res.c drm/vmwgfx: Remove vmwgfx_hashtab 2022-10-25 12:42:25 -04:00
vmwgfx_context.c
vmwgfx_cotable.c drm/ttm: rework on ttm_resource to use size_t type 2022-10-27 11:42:58 +02:00
vmwgfx_devcaps.c
vmwgfx_devcaps.h
vmwgfx_drv.c drm/fb-helper: Move generic fbdev emulation into separate source file 2022-11-05 17:12:04 +01:00
vmwgfx_drv.h drm/vmwgfx: Remove rcu locks from user resources 2023-01-09 21:15:36 -05:00
vmwgfx_execbuf.c drm/vmwgfx: Remove rcu locks from user resources 2023-01-09 21:15:36 -05:00
vmwgfx_fence.c drm/vmwgfx: Fix fencing on SVGAv3 2022-03-11 13:29:34 -05:00
vmwgfx_fence.h drm/vmwgfx: remove vmw_wait_dma_fence 2022-02-02 16:15:37 +01:00
vmwgfx_gem.c
vmwgfx_gmr.c
vmwgfx_gmrid_manager.c drm/ttm: rework on ttm_resource to use size_t type 2022-10-27 11:42:58 +02:00
vmwgfx_ioctl.c drm/vmwgfx: Allow querying of the SVGA PCI id from the userspace 2022-03-11 13:29:35 -05:00
vmwgfx_irq.c drm/vmwgfx: Implement MSI/MSI-X support for IRQs 2022-03-11 13:29:37 -05:00
vmwgfx_kms.c drm/vmwgfx: Cleanup the cursor snooping code 2022-10-31 11:50:24 -04:00
vmwgfx_kms.h drm/vmwgfx: Port the framebuffer code to drm fb helpers 2022-10-25 12:42:27 -04:00
vmwgfx_ldu.c drm/vmwgfx: Remove explicit and broken vblank handling 2022-10-25 12:42:29 -04:00
vmwgfx_mksstat.h drm/vmwgfx: Add a mksstat counter for cotable resizes 2022-10-25 12:42:30 -04:00
vmwgfx_mob.c drm/vmwgfx: Remove unused compile options 2021-12-17 16:35:02 +01:00
vmwgfx_msg.c drm for 6.2: 2022-12-13 11:59:58 -08:00
vmwgfx_msg_arm64.h
vmwgfx_msg_x86.h
vmwgfx_overlay.c
vmwgfx_page_dirty.c drm/ttm: rework on ttm_resource to use size_t type 2022-10-27 11:42:58 +02:00
vmwgfx_prime.c
vmwgfx_reg.h
vmwgfx_resource.c drm/vmwgfx: Remove rcu locks from user resources 2023-01-09 21:15:36 -05:00
vmwgfx_resource_priv.h
vmwgfx_scrn.c drm for 6.2: 2022-12-13 11:59:58 -08:00
vmwgfx_shader.c
vmwgfx_simple_resource.c drm/vmwgfx: cleanup comments 2022-08-04 11:30:46 -04:00
vmwgfx_so.c
vmwgfx_so.h
vmwgfx_stdu.c drm/vmwgfx: Remove explicit and broken vblank handling 2022-10-25 12:42:29 -04:00
vmwgfx_streamoutput.c
vmwgfx_surface.c drm/vmwgfx: Cleanup the cursor snooping code 2022-10-31 11:50:24 -04:00
vmwgfx_system_manager.c drm/ttm: add back a reference to the bdev to the res manager 2022-01-26 15:29:24 +01:00
vmwgfx_ttm_buffer.c drm/ttm: Add a parameter to add extra pages into ttm_tt 2022-04-02 08:22:48 +05:30
vmwgfx_ttm_glue.c
vmwgfx_va.c
vmwgfx_validation.c drm/vmwgfx: Refactor resource validation hashtable to use linux/hashtable implementation. 2022-10-25 12:42:20 -04:00
vmwgfx_validation.h drm/vmwgfx: Refactor resource validation hashtable to use linux/hashtable implementation. 2022-10-25 12:42:20 -04:00