summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_dma.c
diff options
context:
space:
mode:
authorBen Widawsky2013-10-05 06:22:49 +0200
committerDaniel Vetter2013-10-10 12:47:07 +0200
commit78511f2a6fc6960c8917d9655fffb687822a0225 (patch)
tree73ec601c014e4b47381ef8f3bd7b6d84a5c1a1c9 /drivers/gpu/drm/i915/i915_dma.c
parentdrm/i915: rip out gen2 reset code (diff)
downloadkernel-qcow2-linux-78511f2a6fc6960c8917d9655fffb687822a0225.tar.gz
kernel-qcow2-linux-78511f2a6fc6960c8917d9655fffb687822a0225.tar.xz
kernel-qcow2-linux-78511f2a6fc6960c8917d9655fffb687822a0225.zip
drm/i915: Prevent using uninitialized MMIO funcs
For upcoming patches which will have GEN specific MMIO functions, we'll need to initialize the uncore data structure earlier than we do today. If we do not do this, the following will be problematic: intel_uncore_sanitize intel_disable_gt_powersave gen6_disable_rps I915_WRITE(GEN6_RC_CONTROL, 0); <--- MMIO intel_uncore_init // initializes MMIO By initializing the function pointers first, we should be safe. Signed-off-by: Ben Widawsky <ben@bwidawsk.net> Reviewed-by: Damien Lespiau <damien.lespiau@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_dma.c')
-rw-r--r--drivers/gpu/drm/i915/i915_dma.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c
index b3873c945d1b..ff2083e805ee 100644
--- a/drivers/gpu/drm/i915/i915_dma.c
+++ b/drivers/gpu/drm/i915/i915_dma.c
@@ -1614,8 +1614,8 @@ int i915_driver_load(struct drm_device *dev, unsigned long flags)
intel_irq_init(dev);
intel_pm_init(dev);
- intel_uncore_sanitize(dev);
intel_uncore_init(dev);
+ intel_uncore_sanitize(dev);
/* Try to make sure MCHBAR is enabled before poking at it */
intel_setup_mchbar(dev);