summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_gem.c
diff options
context:
space:
mode:
authorBen Widawsky <benjamin.widawsky@intel.com>2013-08-10 07:12:12 +0200
committerDaniel Vetter <daniel.vetter@ffwll.ch>2013-08-22 13:31:35 +0200
commit7ace7ef2f5d20632240196fa3e5d5c74cf2c1508 (patch)
tree5de3c93fb5ae3c27871d9f824f4b206bf36ae5e9 /drivers/gpu/drm/i915/i915_gem.c
parentdrm/i915: reserve I915_CACHING_DISPLAY and document cache modes (diff)
downloadlinux-7ace7ef2f5d20632240196fa3e5d5c74cf2c1508.tar.xz
linux-7ace7ef2f5d20632240196fa3e5d5c74cf2c1508.zip
drm/i915: WARN_ON failed map_and_fenceable
I just noticed in our code we don't really check the assertion, and given some of the code I am changing in this area, I feel a WARN is very nice to have. Signed-off-by: Ben Widawsky <ben@bwidawsk.net> [danvet: s/&/&&/ to fix typo on the check.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_gem.c')
-rw-r--r--drivers/gpu/drm/i915/i915_gem.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index 959dffba0f0e..e414adaaf11d 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -3211,6 +3211,8 @@ search_free:
if (i915_is_ggtt(vm))
obj->map_and_fenceable = mappable && fenceable;
+ WARN_ON(map_and_fenceable && !obj->map_and_fenceable);
+
trace_i915_vma_bind(vma, map_and_fenceable);
i915_gem_verify_gtt(dev);
return 0;