Commit befedbb7 authored by Chris Wilson's avatar Chris Wilson

drm/i915: Use common LRU inactive vma bumping for unpin_from_display

Now that i915_gem_object_bump_inactive_ggtt() exists, also make use of
it for the LRU bumping from i915_gem_object_unpin_from_display()
Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
Link: http://patchwork.freedesktop.org/patch/msgid/20170119192659.31789-2-chris@chris-wilson.co.ukReviewed-by: default avatarJonas Lahtinen <joonas.lahtinen@linux.intel.com>
parent d65415df
...@@ -3556,8 +3556,7 @@ i915_gem_object_unpin_from_display_plane(struct i915_vma *vma) ...@@ -3556,8 +3556,7 @@ i915_gem_object_unpin_from_display_plane(struct i915_vma *vma)
vma->display_alignment = I915_GTT_MIN_ALIGNMENT; vma->display_alignment = I915_GTT_MIN_ALIGNMENT;
/* Bump the LRU to try and avoid premature eviction whilst flipping */ /* Bump the LRU to try and avoid premature eviction whilst flipping */
if (!i915_vma_is_active(vma)) i915_gem_object_bump_inactive_ggtt(vma->obj);
list_move_tail(&vma->vm_link, &vma->vm->inactive_list);
i915_vma_unpin(vma); i915_vma_unpin(vma);
} }
......
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