diff options
author | David Daney <ddaney@caviumnetworks.com> | 2010-10-01 16:27:32 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2010-10-29 14:08:31 -0400 |
commit | 48e1fd5a81416a037f5a48120bf281102f2584e2 (patch) | |
tree | c5c4bd344f50493bb1d1c36d485300e9061c5aa2 /arch/mips/include/asm/device.h | |
parent | 43e4f7ae4b4a96b5e84f6e1592d2e9353138e88c (diff) |
MIPS: Convert DMA to use dma-mapping-common.h
Use asm-generic/dma-mapping-common.h to handle all DMA mapping operations
and establish a default get_dma_ops() that forwards all operations to the
existing code.
Augment dev_archdata to carry a pointer to the struct dma_map_ops, allowing
DMA operations to be overridden on a per device basis. Currently this is
never filled in, so the default dma_map_ops are used. A follow-on patch
sets this for Octeon PCI devices.
Also initialize the dma_debug system as it is now used if it is configured.
Includes fixes by Kevin Cernekee <cernekee@gmail.com>.
Signed-off-by: David Daney <ddaney@caviumnetworks.com>
Patchwork: http://patchwork.linux-mips.org/patch/1637/
Patchwork: http://patchwork.linux-mips.org/patch/1678/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/include/asm/device.h')
-rw-r--r-- | arch/mips/include/asm/device.h | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/arch/mips/include/asm/device.h b/arch/mips/include/asm/device.h index 06746c5e8099..c94fafba9e62 100644 --- a/arch/mips/include/asm/device.h +++ b/arch/mips/include/asm/device.h | |||
@@ -3,4 +3,17 @@ | |||
3 | * | 3 | * |
4 | * This file is released under the GPLv2 | 4 | * This file is released under the GPLv2 |
5 | */ | 5 | */ |
6 | #include <asm-generic/device.h> | 6 | #ifndef _ASM_MIPS_DEVICE_H |
7 | #define _ASM_MIPS_DEVICE_H | ||
8 | |||
9 | struct dma_map_ops; | ||
10 | |||
11 | struct dev_archdata { | ||
12 | /* DMA operations on that device */ | ||
13 | struct dma_map_ops *dma_ops; | ||
14 | }; | ||
15 | |||
16 | struct pdev_archdata { | ||
17 | }; | ||
18 | |||
19 | #endif /* _ASM_MIPS_DEVICE_H*/ | ||