diff options
author | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2008-03-05 19:25:03 +1000 |
---|---|---|
committer | Dave Airlie <airlied@linux.ie> | 2008-03-05 19:25:03 +1000 |
commit | a875821f7b19a1bcee238cef5c3b507d2869542d (patch) | |
tree | df6e4664a29e549775ad57d44fea13da55692171 /linux-core/ati_pcigart.c | |
parent | d5c0101252e9f48ef1b59f48c05fea7007df97f0 (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>
Diffstat (limited to 'linux-core/ati_pcigart.c')
-rw-r--r-- | linux-core/ati_pcigart.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/linux-core/ati_pcigart.c b/linux-core/ati_pcigart.c index 68029635..93519e5f 100644 --- a/linux-core/ati_pcigart.c +++ b/linux-core/ati_pcigart.c @@ -224,6 +224,12 @@ int drm_ati_pcigart_init(struct drm_device *dev, struct drm_ati_pcigart_info *ga } } + if (gart_info->gart_table_location == DRM_ATI_GART_MAIN) + dma_sync_single_for_device(&dev->pdev->dev, + bus_address, + max_pages * sizeof(u32), + PCI_DMA_TODEVICE); + ret = 1; #if defined(__i386__) || defined(__x86_64__) |