drm/i915: use the complete gtt
At least the part that's currently enabled by the BIOS.
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index 7b06807..6d9971f 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -173,6 +173,7 @@
int i915_gem_do_init(struct drm_device *dev,
unsigned long start,
+ unsigned long mappable_end,
unsigned long end)
{
drm_i915_private_t *dev_priv = dev->dev_private;
@@ -187,7 +188,7 @@
end - start);
dev_priv->mm.gtt_total = end - start;
- dev_priv->mm.gtt_mappable_end = end;
+ dev_priv->mm.gtt_mappable_end = mappable_end;
return 0;
}
@@ -200,7 +201,7 @@
int ret;
mutex_lock(&dev->struct_mutex);
- ret = i915_gem_do_init(dev, args->gtt_start, args->gtt_end);
+ ret = i915_gem_do_init(dev, args->gtt_start, args->gtt_end, args->gtt_end);
mutex_unlock(&dev->struct_mutex);
return ret;