[PATCH 0/2] locking/rwsem: Add down_write_interruptible and use it
Zack Rusin
zackr at vmware.com
Mon Mar 8 20:54:54 UTC 2021
vmwgfx has really ugly implemention of an interruptible lock trying
to match rw sem semantics. By adding a small bit of code implementing
down_write_interruptible to rwsem which already supported
down_read_interruptible we can completely remove all of the custom
code from vmwgfx.
Cc: Peter Zijlstra <peterz at infradead.org>
Cc: Ingo Molnar <mingo at redhat.com>
Cc: Will Deacon <will at kernel.org>
Cc: Martin Krastev <krastevm at vmware.com>
Cc: Roland Scheidegger <sroland at vmware.com>
Cc: linux-kernel at vger.kernel.org
Cc: dri-devel at lists.freedesktop.org
Zack Rusin (2):
locking/rwsem: Add down_write_interruptible
drm/vmwgfx: Remove custom locking code
drivers/gpu/drm/vmwgfx/Makefile | 2 +-
drivers/gpu/drm/vmwgfx/ttm_lock.c | 194 ----------------
drivers/gpu/drm/vmwgfx/ttm_lock.h | 218 ------------------
drivers/gpu/drm/vmwgfx/vmwgfx_bo.c | 24 +-
drivers/gpu/drm/vmwgfx/vmwgfx_context.c | 4 +-
drivers/gpu/drm/vmwgfx/vmwgfx_drv.c | 57 +----
drivers/gpu/drm/vmwgfx/vmwgfx_drv.h | 32 ++-
drivers/gpu/drm/vmwgfx/vmwgfx_execbuf.c | 4 +-
drivers/gpu/drm/vmwgfx/vmwgfx_fb.c | 10 +-
drivers/gpu/drm/vmwgfx/vmwgfx_ioctl.c | 8 +-
drivers/gpu/drm/vmwgfx/vmwgfx_kms.c | 4 +-
drivers/gpu/drm/vmwgfx/vmwgfx_resource.c | 8 +-
drivers/gpu/drm/vmwgfx/vmwgfx_shader.c | 4 +-
.../gpu/drm/vmwgfx/vmwgfx_simple_resource.c | 4 +-
drivers/gpu/drm/vmwgfx/vmwgfx_surface.c | 16 +-
include/linux/rwsem.h | 1 +
kernel/locking/rwsem.c | 23 ++
17 files changed, 98 insertions(+), 515 deletions(-)
delete mode 100644 drivers/gpu/drm/vmwgfx/ttm_lock.c
delete mode 100644 drivers/gpu/drm/vmwgfx/ttm_lock.h
--
2.27.0
More information about the dri-devel
mailing list