diff options
author | David S. Miller <davem@davemloft.net> | 2008-08-27 18:01:36 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-08-29 02:13:14 -0700 |
commit | 944c67dff7a88f0a775e5b604937f9e30d2de555 (patch) | |
tree | 38566c48f3f002c3f1f9d77da3d8b12543bee1c7 /arch/sparc/kernel/dma.h | |
parent | 260489fa8a9735c76073ace95f03ffaf10cca884 (diff) |
sparc32: Implement more generic dma_*() interfaces.
These dispatch to either PCI or SBUS routines based upon
the device bus type.
This will allow us to let SBUS drivers call these routines.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/kernel/dma.h')
-rw-r--r-- | arch/sparc/kernel/dma.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/arch/sparc/kernel/dma.h b/arch/sparc/kernel/dma.h new file mode 100644 index 00000000000..f8d8951adb5 --- /dev/null +++ b/arch/sparc/kernel/dma.h @@ -0,0 +1,14 @@ +void *sbus_alloc_consistent(struct device *dev, long len, u32 *dma_addrp); +void sbus_free_consistent(struct device *dev, long n, void *p, u32 ba); +dma_addr_t sbus_map_single(struct device *dev, void *va, + size_t len, int direction); +void sbus_unmap_single(struct device *dev, dma_addr_t ba, + size_t n, int direction); +int sbus_map_sg(struct device *dev, struct scatterlist *sg, + int n, int direction); +void sbus_unmap_sg(struct device *dev, struct scatterlist *sg, + int n, int direction); +void sbus_dma_sync_single_for_cpu(struct device *dev, dma_addr_t ba, + size_t size, int direction); +void sbus_dma_sync_single_for_device(struct device *dev, dma_addr_t ba, + size_t size, int direction); |