]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Move assert of page pin vs bind count into i915_vma_unbind
authorChris Wilson <chris@chris-wilson.co.uk>
Sat, 31 Dec 2016 11:20:09 +0000 (11:20 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Sat, 31 Dec 2016 11:41:45 +0000 (11:41 +0000)
commit8ce043b9b09426532636371d30d628326733eda8
tree33dd6332e7749a0dc20bfb79bf9fa890be5863e3
parent5aa0efc632927a63a9e71ae8c74f8efab64c7a8d
drm/i915: Move assert of page pin vs bind count into i915_vma_unbind

The read of the page pin count and the bind count are unordered,
presenting races in the assert and it firing off incorrectly. Prevent
this by restricting the assert to the vma bind/unbind routines where we
have local cpu ordering between the two.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/20161231112012.29263-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/i915_drv.h
drivers/gpu/drm/i915/i915_vma.c