]> err.no Git - linux-2.6/commit
drm: fix driver deadlock with AIGLX and reclaim_buffers_locked
authorThomas Hellstrom <thomas-at-tungstengraphics-dot-com>
Fri, 23 Mar 2007 02:28:33 +0000 (13:28 +1100)
committerDave Airlie <airlied@linux.ie>
Fri, 23 Mar 2007 02:28:33 +0000 (13:28 +1100)
commit040ac32048d5efabd557c1e0a6ab8aec2c710c56
treeba714a33105695c7d57ff833dbd18875ddb82492
parent4b560fde06aeb342f3ff0bce924627ab722d251a
drm: fix driver deadlock with AIGLX and reclaim_buffers_locked

Bugzilla Bug #9457

Add refcounting of user waiters to the DRM hardware lock, so that we can use
DRM_LOCK_CONT flag more conservatively.

Also add a kernel waiter refcount that if nonzero transfers the lock for the
kernel context when it is released. This is useful when waiting for idle and can be used for very simple fence object driver implementations for the new memory manager

Signed-off-by: Dave Airlie <airlied@linux.ie>
drivers/char/drm/drmP.h
drivers/char/drm/drm_fops.c
drivers/char/drm/drm_irq.c
drivers/char/drm/drm_lock.c
drivers/char/drm/drm_stub.c
drivers/char/drm/sis_drv.c
drivers/char/drm/via_drv.c