diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2017-01-05 10:59:40 -0500 |
---|---|---|
committer | Jani Nikula <jani.nikula@intel.com> | 2017-01-12 03:15:44 -0500 |
commit | e88893fea17996018b2d68a22e677ea04f3baadf (patch) | |
tree | 96e1bed627c2f4988e9724b5e094e6cbed87f737 | |
parent | 79b11b6437bd31b315f5fda72fe1a00baf98e804 (diff) |
drm/i915: Clear ret before unbinding in i915_gem_evict_something()
Missed when rebasing patches, I failed to set ret to zero before
starting the unbind loop (which depends upon ret being zero).
Reported-by: Matthew Auld <matthew.william.auld@gmail.com>
Fixes: 9332f3b1b99a ("drm/i915: Combine loops within i915_gem_evict_something")
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Matthew Auld <matthew.william.auld@gmail.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20170105155940.10033-1-chris@chris-wilson.co.uk
Reviewed-by: Matthew Auld <matthew.william.auld@gmail.com>
Cc: <stable@vger.kernel.org> # v4.9+
(cherry picked from commit 121dfbb2a2ef1c5f49e15c38ccc47ff0beb59446)
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
-rw-r--r-- | drivers/gpu/drm/i915/i915_gem_evict.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem_evict.c b/drivers/gpu/drm/i915/i915_gem_evict.c index bd08814b015c..d534a316a16e 100644 --- a/drivers/gpu/drm/i915/i915_gem_evict.c +++ b/drivers/gpu/drm/i915/i915_gem_evict.c | |||
@@ -199,6 +199,7 @@ found: | |||
199 | } | 199 | } |
200 | 200 | ||
201 | /* Unbinding will emit any required flushes */ | 201 | /* Unbinding will emit any required flushes */ |
202 | ret = 0; | ||
202 | while (!list_empty(&eviction_list)) { | 203 | while (!list_empty(&eviction_list)) { |
203 | vma = list_first_entry(&eviction_list, | 204 | vma = list_first_entry(&eviction_list, |
204 | struct i915_vma, | 205 | struct i915_vma, |