summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm
diff options
context:
space:
mode:
authorBen Widawsky2015-01-22 18:01:25 +0100
committerDaniel Vetter2015-02-13 23:28:12 +0100
commitc8c26622ae508f9f7e6be3e99b45ccae4d07efca (patch)
tree8f618082830693982b21698ddeb03dbca8e3c95c /drivers/gpu/drm
parentdrm/i915: Rename to GEN8_LEGACY_PDPES (diff)
downloadkernel-qcow2-linux-c8c26622ae508f9f7e6be3e99b45ccae4d07efca.tar.gz
kernel-qcow2-linux-c8c26622ae508f9f7e6be3e99b45ccae4d07efca.tar.xz
kernel-qcow2-linux-c8c26622ae508f9f7e6be3e99b45ccae4d07efca.zip
drm/i915: Setup less PPGTT on failed page_directory
The current code will both potentially print a WARN, and setup part of the PPGTT structure. Neither of these harm the current code, it is simply for clarity, and to perhaps prevent later bugs, or weird debug messages. Signed-off-by: Ben Widawsky <ben@bwidawsk.net> Signed-off-by: Michel Thierry <michel.thierry@intel.com> Reviewed-by: Mika Kuoppala <mika.kuoppala@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r--drivers/gpu/drm/i915/i915_gem_gtt.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
index 58d54bddfb98..b48b586dc287 100644
--- a/drivers/gpu/drm/i915/i915_gem_gtt.c
+++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
@@ -1032,11 +1032,14 @@ alloc:
goto alloc;
}
+ if (ret)
+ return ret;
+
if (ppgtt->node.start < dev_priv->gtt.mappable_end)
DRM_DEBUG("Forced to use aperture for PDEs\n");
ppgtt->num_pd_entries = GEN6_PPGTT_PD_ENTRIES;
- return ret;
+ return 0;
}
static int gen6_ppgtt_allocate_page_tables(struct i915_hw_ppgtt *ppgtt)