aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-arm/dma-mapping.h
diff options
context:
space:
mode:
authorJens Axboe <jens.axboe@oracle.com>2007-10-23 06:37:59 -0400
committerJens Axboe <jens.axboe@oracle.com>2007-10-23 06:37:59 -0400
commitdee9ba828fb5e72bef17450168774fb360dce983 (patch)
tree2c3cda9f337e6aee630ae1bcaec66964cd0c5ca9 /include/asm-arm/dma-mapping.h
parent4fcc47a053adc786cc1ab84f3b8909eeb5c37963 (diff)
arm: sg fallout
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'include/asm-arm/dma-mapping.h')
-rw-r--r--include/asm-arm/dma-mapping.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/include/asm-arm/dma-mapping.h b/include/asm-arm/dma-mapping.h
index 1eb8aac43228..e99406a7bece 100644
--- a/include/asm-arm/dma-mapping.h
+++ b/include/asm-arm/dma-mapping.h
@@ -5,7 +5,7 @@
5 5
6#include <linux/mm.h> /* need struct page */ 6#include <linux/mm.h> /* need struct page */
7 7
8#include <asm/scatterlist.h> 8#include <linux/scatterlist.h>
9 9
10/* 10/*
11 * DMA-consistent mapping functions. These allocate/free a region of 11 * DMA-consistent mapping functions. These allocate/free a region of
@@ -274,8 +274,8 @@ dma_map_sg(struct device *dev, struct scatterlist *sg, int nents,
274 for (i = 0; i < nents; i++, sg++) { 274 for (i = 0; i < nents; i++, sg++) {
275 char *virt; 275 char *virt;
276 276
277 sg->dma_address = page_to_dma(dev, sg->page) + sg->offset; 277 sg->dma_address = page_to_dma(dev, sg_page(sg)) + sg->offset;
278 virt = page_address(sg->page) + sg->offset; 278 virt = sg_virt(sg);
279 279
280 if (!arch_is_coherent()) 280 if (!arch_is_coherent())
281 dma_cache_maint(virt, sg->length, dir); 281 dma_cache_maint(virt, sg->length, dir);
@@ -371,7 +371,7 @@ dma_sync_sg_for_cpu(struct device *dev, struct scatterlist *sg, int nents,
371 int i; 371 int i;
372 372
373 for (i = 0; i < nents; i++, sg++) { 373 for (i = 0; i < nents; i++, sg++) {
374 char *virt = page_address(sg->page) + sg->offset; 374 char *virt = sg_virt(sg);
375 if (!arch_is_coherent()) 375 if (!arch_is_coherent())
376 dma_cache_maint(virt, sg->length, dir); 376 dma_cache_maint(virt, sg->length, dir);
377 } 377 }
@@ -384,7 +384,7 @@ dma_sync_sg_for_device(struct device *dev, struct scatterlist *sg, int nents,
384 int i; 384 int i;
385 385
386 for (i = 0; i < nents; i++, sg++) { 386 for (i = 0; i < nents; i++, sg++) {
387 char *virt = page_address(sg->page) + sg->offset; 387 char *virt = sg_virt(sg);
388 if (!arch_is_coherent()) 388 if (!arch_is_coherent())
389 dma_cache_maint(virt, sg->length, dir); 389 dma_cache_maint(virt, sg->length, dir);
390 } 390 }