aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/drm/ati_pcigart.c
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2008-03-28 17:23:07 -0400
committerDave Airlie <airlied@linux.ie>2008-03-29 17:57:57 -0400
commit6876b3bacaaa4c73fb8752b47c84b2b7fad5422a (patch)
treeb3f0a1795a3c0c66de99642ba0e1c233c872823c /drivers/char/drm/ati_pcigart.c
parent2b46278b6af0a4df43016f01a0741d8e0a76bfd4 (diff)
drm: fix for non-coherent DMA PowerPC
This patch fixes bits of the DRM so to make the radeon DRI work on non-cache coherent PCI DMA variants of the PowerPC processors. It moves the few places that needs change to wrappers to that other architectures with similar issues can easily add their own changes to those wrappers, at least until we have more useful generic kernel API. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: "David S. Miller" <davem@davemloft.net> Cc: "Luck, Tony" <tony.luck@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Dave Airlie <airlied@linux.ie>
Diffstat (limited to 'drivers/char/drm/ati_pcigart.c')
-rw-r--r--drivers/char/drm/ati_pcigart.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/char/drm/ati_pcigart.c b/drivers/char/drm/ati_pcigart.c
index 35d25d821c38..141f4dfa0a11 100644
--- a/drivers/char/drm/ati_pcigart.c
+++ b/drivers/char/drm/ati_pcigart.c
@@ -168,6 +168,12 @@ int drm_ati_pcigart_init(struct drm_device *dev, struct drm_ati_pcigart_info *ga
168 } 168 }
169 } 169 }
170 170
171 if (gart_info->gart_table_location == DRM_ATI_GART_MAIN)
172 dma_sync_single_for_device(&dev->pdev->dev,
173 bus_address,
174 max_pages * sizeof(u32),
175 PCI_DMA_TODEVICE);
176
171 ret = 1; 177 ret = 1;
172 178
173#if defined(__i386__) || defined(__x86_64__) 179#if defined(__i386__) || defined(__x86_64__)