aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_gem_evict.c
diff options
context:
space:
mode:
authorBen Widawsky <ben@bwidawsk.net>2013-07-16 19:50:06 -0400
committerDaniel Vetter <daniel.vetter@ffwll.ch>2013-07-17 16:23:43 -0400
commit93bd8649dba3155d1a0ba2a902d9c49f1c75a1da (patch)
tree50d29aad6fd49dcbab1e3c0d4ff40d9bc6c4b9b2 /drivers/gpu/drm/i915/i915_gem_evict.c
parent853ba5d2231619e1c7f7de1269e135174ec8e3cb (diff)
drm/i915: Put the mm in the parent address space
Every address space should support object allocation. It therefore makes sense to have the allocator be part of the "superclass" which GGTT and PPGTT will derive. Since our maximum address space size is only 2GB we're not yet able to avoid doing allocation/eviction; but we'd hope one day this becomes almost irrelvant. v2: Rebased Signed-off-by: Ben Widawsky <ben@bwidawsk.net> Reviewed-by: Imre Deak <imre.deak@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_gem_evict.c')
-rw-r--r--drivers/gpu/drm/i915/i915_gem_evict.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem_evict.c b/drivers/gpu/drm/i915/i915_gem_evict.c
index 5f8afc48bb7e..f1c9ab096b00 100644
--- a/drivers/gpu/drm/i915/i915_gem_evict.c
+++ b/drivers/gpu/drm/i915/i915_gem_evict.c
@@ -78,12 +78,12 @@ i915_gem_evict_something(struct drm_device *dev, int min_size,
78 78
79 INIT_LIST_HEAD(&unwind_list); 79 INIT_LIST_HEAD(&unwind_list);
80 if (mappable) 80 if (mappable)
81 drm_mm_init_scan_with_range(&dev_priv->mm.gtt_space, 81 drm_mm_init_scan_with_range(&dev_priv->gtt.base.mm, min_size,
82 min_size, alignment, cache_level, 82 alignment, cache_level, 0,
83 0, dev_priv->gtt.mappable_end); 83 dev_priv->gtt.mappable_end);
84 else 84 else
85 drm_mm_init_scan(&dev_priv->mm.gtt_space, 85 drm_mm_init_scan(&dev_priv->gtt.base.mm, min_size, alignment,
86 min_size, alignment, cache_level); 86 cache_level);
87 87
88 /* First see if there is a large enough contiguous idle region... */ 88 /* First see if there is a large enough contiguous idle region... */
89 list_for_each_entry(obj, &dev_priv->mm.inactive_list, mm_list) { 89 list_for_each_entry(obj, &dev_priv->mm.inactive_list, mm_list) {