[Intel-gfx] [PATCH 3/5] drm/i915: check gpu_write_list in move_to_flushing

Daniel Vetter daniel.vetter at ffwll.ch
Tue Apr 19 22:46:02 CEST 2011


The corresponding WARN_ON with opposite sign already exists in
move_to_inactive, hence add it here for symmetry.

I've actually hit this while hunting down bugs in various
pipelined fencing patches.

Signed-off-by: Daniel Vetter <daniel.vetter at ffwll.ch>
---
 drivers/gpu/drm/i915/i915_gem.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index 5c900d3..f658f4f 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -1749,6 +1749,7 @@ i915_gem_object_move_to_flushing(struct drm_i915_gem_object *obj)
 	drm_i915_private_t *dev_priv = dev->dev_private;
 
 	WARN_ON(!obj->active);
+	WARN_ON(list_empty(&obj->gpu_write_list));
 	list_move_tail(&obj->mm_list, &dev_priv->mm.flushing_list);
 
 	i915_gem_object_move_off_active(obj);
-- 
1.7.4.1




More information about the Intel-gfx mailing list