aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2010-11-03 05:27:53 -0400
committerChris Wilson <chris@chris-wilson.co.uk>2010-11-03 05:31:57 -0400
commit085ce2643713830cf772c12c1a16da9d0ba83f36 (patch)
tree58205f231f2bba1ecc648e0cc330fce840dfca7e /drivers
parent27153f72d04bcd83b3a66e219418a21d6269553b (diff)
drm/i915: Ensure that if we ever try to pin+fence it is mappable.
When merging Daniel's full-gtt patches I had a set of tweaks which I thought I had undone. I was half right... Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=31286 Reported-by: jinjin.wang@intel.com Reported-by: Alexey Fisher <bug-track@fisher-privat.net> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpu/drm/i915/i915_gem.c1
-rw-r--r--drivers/gpu/drm/i915/intel_display.c3
2 files changed, 3 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index 5bd86033a88e..12dae003c011 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -4151,6 +4151,7 @@ i915_gem_object_pin(struct drm_gem_object *obj, uint32_t alignment,
4151 int ret; 4151 int ret;
4152 4152
4153 BUG_ON(obj_priv->pin_count == DRM_I915_GEM_OBJECT_MAX_PIN_COUNT); 4153 BUG_ON(obj_priv->pin_count == DRM_I915_GEM_OBJECT_MAX_PIN_COUNT);
4154 BUG_ON(need_fence && !mappable);
4154 WARN_ON(i915_verify_lists(dev)); 4155 WARN_ON(i915_verify_lists(dev));
4155 4156
4156 if (obj_priv->gtt_space != NULL) { 4157 if (obj_priv->gtt_space != NULL) {
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index 33c178c8d6dd..a33d9a2c7429 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -1462,7 +1462,8 @@ intel_pin_and_fence_fb_obj(struct drm_device *dev,
1462 } 1462 }
1463 1463
1464 ret = i915_gem_object_pin(obj, alignment, 1464 ret = i915_gem_object_pin(obj, alignment,
1465 !pipelined, obj_priv->tiling_mode); 1465 !pipelined || obj_priv->tiling_mode,
1466 obj_priv->tiling_mode);
1466 if (ret) 1467 if (ret)
1467 return ret; 1468 return ret;
1468 1469