diff options
author | FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> | 2010-05-26 23:44:18 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-27 18:12:52 +0200 |
commit | 5fd75a7850b5156aa93c9fb6404adb8f563b6e02 (patch) | |
tree | 1b5f21a907eb8182e2642c7dee73274d04d24a07 /include/asm-generic/dma-mapping-common.h | |
parent | swiotlb: remove unnecessary swiotlb_sync_single_range_* (diff) | |
download | linux-5fd75a7850b5156aa93c9fb6404adb8f563b6e02.tar.xz linux-5fd75a7850b5156aa93c9fb6404adb8f563b6e02.zip |
dma-mapping: remove unnecessary sync_single_range_* in dma_map_ops
sync_single_range_for_cpu and sync_single_range_for_device hooks are
unnecessary because sync_single_for_cpu and sync_single_for_device can
be used instead.
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Reviewed-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/asm-generic/dma-mapping-common.h')
-rw-r--r-- | include/asm-generic/dma-mapping-common.h | 20 |
1 files changed, 2 insertions, 18 deletions
diff --git a/include/asm-generic/dma-mapping-common.h b/include/asm-generic/dma-mapping-common.h index 69206957b72c..0c80bb38773f 100644 --- a/include/asm-generic/dma-mapping-common.h +++ b/include/asm-generic/dma-mapping-common.h @@ -123,15 +123,7 @@ static inline void dma_sync_single_range_for_cpu(struct device *dev, size_t size, enum dma_data_direction dir) { - struct dma_map_ops *ops = get_dma_ops(dev); - - BUG_ON(!valid_dma_direction(dir)); - if (ops->sync_single_range_for_cpu) { - ops->sync_single_range_for_cpu(dev, addr, offset, size, dir); - debug_dma_sync_single_range_for_cpu(dev, addr, offset, size, dir); - - } else - dma_sync_single_for_cpu(dev, addr + offset, size, dir); + dma_sync_single_for_cpu(dev, addr + offset, size, dir); } static inline void dma_sync_single_range_for_device(struct device *dev, @@ -140,15 +132,7 @@ static inline void dma_sync_single_range_for_device(struct device *dev, size_t size, enum dma_data_direction dir) { - struct dma_map_ops *ops = get_dma_ops(dev); - - BUG_ON(!valid_dma_direction(dir)); - if (ops->sync_single_range_for_device) { - ops->sync_single_range_for_device(dev, addr, offset, size, dir); - debug_dma_sync_single_range_for_device(dev, addr, offset, size, dir); - - } else - dma_sync_single_for_device(dev, addr + offset, size, dir); + dma_sync_single_for_device(dev, addr + offset, size, dir); } static inline void |