drm/atomic: Call ww_acquire_done after check phase is complete
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Thu, 6 Aug 2015 13:06:40 +0000 (15:06 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 11 Aug 2015 10:04:18 +0000 (12:04 +0200)
commit992cbf19b32900efa17850b9fa0031fd623edd4d
tree78e8f5380d7c771f211cfd6d066a47253ad77f17
parent460e8e2cf464dee6f8a3fc1b81340d818d1ad9e4
drm/atomic: Call ww_acquire_done after check phase is complete

We want to make sure that no one tries to acquire more locks and
states, and ww mutexes provide debug facilities for that. So use them.

v2: Only call acquire_done when ->atomic_check was successful to avoid
falling over an -EDEADLK (spotted by Maarten).

Cc: Rob Clark <robdclark@gmail.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
drivers/gpu/drm/drm_atomic.c