Commit 30154650 authored by Chris Wilson's avatar Chris Wilson Committed by Daniel Vetter

drm/i915: Remove obj->pin_mappable

The obj->pin_mappable flag only exists for debug purposes and is a
hindrance that is mistreated with rotated GGTT views. For debug
purposes, it suffices to mark objects with pin_display as being of note.
Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
parent 2def4ad9
...@@ -160,9 +160,9 @@ describe_obj(struct seq_file *m, struct drm_i915_gem_object *obj) ...@@ -160,9 +160,9 @@ describe_obj(struct seq_file *m, struct drm_i915_gem_object *obj)
} }
if (obj->stolen) if (obj->stolen)
seq_printf(m, " (stolen: %08llx)", obj->stolen->start); seq_printf(m, " (stolen: %08llx)", obj->stolen->start);
if (obj->pin_mappable || obj->fault_mappable) { if (obj->pin_display || obj->fault_mappable) {
char s[3], *t = s; char s[3], *t = s;
if (obj->pin_mappable) if (obj->pin_display)
*t++ = 'p'; *t++ = 'p';
if (obj->fault_mappable) if (obj->fault_mappable)
*t++ = 'f'; *t++ = 'f';
...@@ -458,7 +458,7 @@ static int i915_gem_object_info(struct seq_file *m, void* data) ...@@ -458,7 +458,7 @@ static int i915_gem_object_info(struct seq_file *m, void* data)
size += i915_gem_obj_ggtt_size(obj); size += i915_gem_obj_ggtt_size(obj);
++count; ++count;
} }
if (obj->pin_mappable) { if (obj->pin_display) {
mappable_size += i915_gem_obj_ggtt_size(obj); mappable_size += i915_gem_obj_ggtt_size(obj);
++mappable_count; ++mappable_count;
} }
......
...@@ -1963,7 +1963,6 @@ struct drm_i915_gem_object { ...@@ -1963,7 +1963,6 @@ struct drm_i915_gem_object {
* accurate mappable working set. * accurate mappable working set.
*/ */
unsigned int fault_mappable:1; unsigned int fault_mappable:1;
unsigned int pin_mappable:1;
unsigned int pin_display:1; unsigned int pin_display:1;
/* /*
......
...@@ -4255,9 +4255,6 @@ i915_gem_object_do_pin(struct drm_i915_gem_object *obj, ...@@ -4255,9 +4255,6 @@ i915_gem_object_do_pin(struct drm_i915_gem_object *obj,
WARN_ON(flags & PIN_MAPPABLE && !obj->map_and_fenceable); WARN_ON(flags & PIN_MAPPABLE && !obj->map_and_fenceable);
vma->pin_count++; vma->pin_count++;
if (flags & PIN_MAPPABLE)
obj->pin_mappable |= true;
return 0; return 0;
} }
...@@ -4295,8 +4292,7 @@ i915_gem_object_ggtt_unpin_view(struct drm_i915_gem_object *obj, ...@@ -4295,8 +4292,7 @@ i915_gem_object_ggtt_unpin_view(struct drm_i915_gem_object *obj,
WARN_ON(vma->pin_count == 0); WARN_ON(vma->pin_count == 0);
WARN_ON(!i915_gem_obj_ggtt_bound_view(obj, view)); WARN_ON(!i915_gem_obj_ggtt_bound_view(obj, view));
if (--vma->pin_count == 0 && view->type == I915_GGTT_VIEW_NORMAL) --vma->pin_count;
obj->pin_mappable = false;
} }
bool bool
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment