drm/i915: Remove the conflicting BUG_ON()
authorChris Wilson <chris@chris-wilson.co.uk>
Sun, 15 Aug 2010 09:52:34 +0000 (10:52 +0100)
committerEric Anholt <eric@anholt.net>
Sun, 22 Aug 2010 06:21:13 +0000 (23:21 -0700)
We now attempt to free "active" objects following a GPU hang as either
the GPU will be reset or the hang is permenant. In either case, the GPU
writes will not be flushed to main memory and it should be safe to
return that memory back to the system.

The BUG_ON(active) is thus overkill and can erroneously fire after a
EIO.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Eric Anholt <eric@anholt.net>
drivers/gpu/drm/i915/i915_gem.c

index b4b25e17d4e9b40dacab1fbc880657d90241caca..994e9f2d688b383ca32895ae16176630784cdcd0 100644 (file)
@@ -1979,8 +1979,6 @@ i915_gem_object_unbind(struct drm_gem_object *obj)
         * cause memory corruption through use-after-free.
         */
 
-       BUG_ON(obj_priv->active);
-
        /* release the fence reg _after_ flushing */
        if (obj_priv->fence_reg != I915_FENCE_REG_NONE)
                i915_gem_clear_fence_reg(obj);