On Tue, 23 Oct 2012 13:35:18 +0300
Mika Kuoppala <mika.kuopp...@linux.intel.com> wrote:

> On Mon, 22 Oct 2012 18:34:11 -0700, Ben Widawsky <b...@bwidawsk.net> wrote:

> > +static void teardown_scratch_page(struct drm_device *dev)
> > +{
> > +   struct drm_i915_private *dev_priv = dev->dev_private;
> > +   set_pages_wb(dev_priv->mm.gtt->scratch_page, 1);
> > +   pci_unmap_page(dev->pdev, dev_priv->mm.gtt->scratch_page_dma,
> > +                  PAGE_SIZE, PCI_DMA_BIDIRECTIONAL);
> 
> #ifdef CONFIG_INTEL_IOMMU needed around pci_unmap_page?

It preserves the original behavior, which I believe is fine as is. The
iommu code should just do nothing. I am partial thuogh, since I am the
original reviewer on the patch that introduced that.

> 
> > +   put_page(dev_priv->mm.gtt->scratch_page);
> > +   __free_page(dev_priv->mm.gtt->scratch_page);
> > +}
> > +

-- 
Ben Widawsky, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

Reply via email to