Lines Matching refs:vma
37 mark_free(struct i915_vma *vma, struct list_head *unwind)
39 if (vma->pin_count)
42 if (WARN_ON(!list_empty(&vma->exec_list)))
45 list_add(&vma->exec_list, unwind);
46 return drm_mm_scan_add_block(&vma->node);
63 * This function is used by the object/vma binding code.
75 struct i915_vma *vma;
114 list_for_each_entry(vma, &vm->inactive_list, mm_list) {
115 if (mark_free(vma, &unwind_list))
123 list_for_each_entry(vma, &vm->active_list, mm_list) {
124 if (mark_free(vma, &unwind_list))
131 vma = list_first_entry(&unwind_list,
134 ret = drm_mm_scan_remove_block(&vma->node);
137 list_del_init(&vma->exec_list);
168 vma = list_first_entry(&unwind_list,
171 if (drm_mm_scan_remove_block(&vma->node)) {
172 list_move(&vma->exec_list, &eviction_list);
173 drm_gem_object_reference(&vma->obj->base);
176 list_del_init(&vma->exec_list);
182 vma = list_first_entry(&eviction_list,
186 obj = &vma->obj->base;
187 list_del_init(&vma->exec_list);
189 ret = i915_vma_unbind(vma);
214 struct i915_vma *vma, *next;
227 list_for_each_entry_safe(vma, next, &vm->inactive_list, mm_list)
228 if (vma->pin_count == 0)
229 WARN_ON(i915_vma_unbind(vma));