diff mbox

drm/i915: re-add dropped dma_mask configuration

Message ID 1358565499-1388-1-git-send-email-ben@bwidawsk.net (mailing list archive)
State New, archived
Headers show

Commit Message

Ben Widawsky Jan. 19, 2013, 3:18 a.m. UTC
I'm pretty sure without this, and with DMAR, things explode
spectacularly. I got to this patch via bisecting broken i-g-t on my
machine.

If I had wired ethernet, I would figure out exactly what's failing with
netconsole. To be honest, nothing particularly stands out to me looking
over the code as to why it should fail though.  If someone is more
inquisitive than I, I would be interested to know why we actually need
this bit of code. Not sure if things are broken without DMAR.

Daniel noticed this was accidentally dropped after I rebased my branch,
but figured it wasn't really needed. Seems it is.

Given that my patch:
commit 2ca466ae28f25e62090e4b57c90bcfee080a47a9
Author: Ben Widawsky <ben@bwidawsk.net>
Date:   Fri Jan 18 12:30:33 2013 -0800

    drm/i915: Needs_dmar, not

I'd suggest just squashing this into 2ca466ae28 since this was never
intentional anyway.

Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
---
 drivers/gpu/drm/i915/i915_gem_gtt.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

Daniel Vetter Jan. 19, 2013, 2:03 p.m. UTC | #1
On Fri, Jan 18, 2013 at 07:18:19PM -0800, Ben Widawsky wrote:
> I'm pretty sure without this, and with DMAR, things explode
> spectacularly. I got to this patch via bisecting broken i-g-t on my
> machine.
> 
> If I had wired ethernet, I would figure out exactly what's failing with
> netconsole. To be honest, nothing particularly stands out to me looking
> over the code as to why it should fail though.  If someone is more
> inquisitive than I, I would be interested to know why we actually need
> this bit of code. Not sure if things are broken without DMAR.
> 
> Daniel noticed this was accidentally dropped after I rebased my branch,
> but figured it wasn't really needed. Seems it is.
> 
> Given that my patch:
> commit 2ca466ae28f25e62090e4b57c90bcfee080a47a9
> Author: Ben Widawsky <ben@bwidawsk.net>
> Date:   Fri Jan 18 12:30:33 2013 -0800
> 
>     drm/i915: Needs_dmar, not
> 
> I'd suggest just squashing this into 2ca466ae28 since this was never
> intentional anyway.
> 
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
> Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
Queued for -next, thanks for the patch. I'll beat on things a beat and
then squash your patches around (and annoy our QA with an updated
-testing, since the old one's stale already).
-Daniel
diff mbox

Patch

diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.c b/drivers/gpu/drm/i915/i915_gem_gtt.c
index f8fb7e3..a0ba4a9 100644
--- a/drivers/gpu/drm/i915/i915_gem_gtt.c
+++ b/drivers/gpu/drm/i915/i915_gem_gtt.c
@@ -721,6 +721,9 @@  int i915_gem_gtt_init(struct drm_device *dev)
 		return 0;
 	}
 
+	if (!pci_set_dma_mask(dev->pdev, DMA_BIT_MASK(40)))
+		pci_set_consistent_dma_mask(dev->pdev, DMA_BIT_MASK(40));
+
 	dev_priv->mm.gtt = kzalloc(sizeof(*dev_priv->mm.gtt), GFP_KERNEL);
 	if (!dev_priv->mm.gtt)
 		return -ENOMEM;