mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2025-01-22 05:44:31 +08:00
drm/i915: Rework drop caches for checkpatch
With an upcoming change to bind, to make checkpatch happy and keep the code clean, we need to rework this code a bit. This should have no functional impact. Signed-off-by: Ben Widawsky <ben@bwidawsk.net> [danvet: Add the newline Chris requested.] Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
This commit is contained in:
parent
fc8c067eee
commit
31a46c9c09
@ -1784,12 +1784,14 @@ i915_drop_caches_set(void *data, u64 val)
|
||||
|
||||
if (val & DROP_BOUND) {
|
||||
list_for_each_entry_safe(obj, next, &vm->inactive_list,
|
||||
mm_list)
|
||||
if (obj->pin_count == 0) {
|
||||
ret = i915_gem_object_unbind(obj);
|
||||
if (ret)
|
||||
goto unlock;
|
||||
}
|
||||
mm_list) {
|
||||
if (obj->pin_count)
|
||||
continue;
|
||||
|
||||
ret = i915_gem_object_unbind(obj);
|
||||
if (ret)
|
||||
goto unlock;
|
||||
}
|
||||
}
|
||||
|
||||
if (val & DROP_UNBOUND) {
|
||||
|
Loading…
Reference in New Issue
Block a user