Bug 13721 - [TRIVIAL]DRM drivers don't use PCI DMA API.
Summary: [TRIVIAL]DRM drivers don't use PCI DMA API.
Status: RESOLVED CODE_FIX
Alias: None
Product: Drivers
Classification: Unclassified
Component: Video(DRI - Intel) (show other bugs)
Hardware: All Linux
: P1 normal
Assignee: intel-gfx-bugs@lists.freedesktop.org
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-07-06 12:14 UTC by David Woodhouse
Modified: 2013-11-20 15:28 UTC (History)
4 users (show)

See Also:
Kernel Version: 3.4
Subsystem:
Regression: No
Bisected commit-id:


Attachments

Description David Woodhouse 2009-07-06 12:14:35 UTC
When the system has an IOMMU, it prevents all DMA from the graphics devices. See http://bugzilla.kernel.org/show_bug.cgi?id=11821#c16 for an example.

For the Intel IOMMU we have a temporary workaround for this brokenness, CONFIG_DMAR_BROKEN_GFX_WA. This kind of workaround apparently isn't easy to do for the AMD IOMMU though, and isn't necessarily the right answer even if it _was_ feasible.

We need to fix the drivers. I plan to remove CONFIG_DMAR_BROKEN_GFX_WA in 2.6.32.
Comment 1 Alan 2012-06-12 10:26:41 UTC
Option still present and still refers to the 2.6.32 removal in Kconfig - would you perhaps mind fixing Kconfig Dave 8)
Comment 2 David Woodhouse 2013-11-20 13:39:15 UTC
I think the Intel graphics drivers (which are the only ones for which DMAR_BROKEN_GFX_WA is applicable) are fixed now. Shame we still don't do any QA on the hardware before we ship it though...
Comment 3 Alan 2013-11-20 14:55:13 UTC
Moving to DRI/intel to check what needs to happen and who needs to own it
Comment 4 Chris Wilson 2013-11-20 15:08:32 UTC
We migrated over to dma_map_sg() and pci_map_page() and rely on intel_iommu to dtrt for the variety of broken VT-d/gfx, with the occasional quirk in the driver for when the GPU itself hangs if its iommu mapping is changed whilst it is busy.
Comment 5 Daniel Vetter 2013-11-20 15:28:54 UTC
Also due to too much hw breakage we won't ever be able to remove the workaround, at least as a kernel cmdline option in the form of intel_iommu=igfx_off. Too valuable for debugging.

Note You need to log in before you can comment on or make changes to this bug.