dma-mapping.h 705 字节
Newer Older
L
Linus Torvalds 已提交
1 2 3
#ifndef __ASM_SH_DMA_MAPPING_H
#define __ASM_SH_DMA_MAPPING_H

4 5
extern struct dma_map_ops *dma_ops;
extern void no_iommu_init(void);
L
Linus Torvalds 已提交
6

7 8 9 10 11
static inline struct dma_map_ops *get_dma_ops(struct device *dev)
{
	return dma_ops;
}

12 13
#define DMA_ERROR_CODE 0

14 15
void dma_cache_sync(struct device *dev, void *vaddr, size_t size,
		    enum dma_data_direction dir);
L
Linus Torvalds 已提交
16

17 18
/* arch/sh/mm/consistent.c */
extern void *dma_generic_alloc_coherent(struct device *dev, size_t size,
19
					dma_addr_t *dma_addr, gfp_t flag,
20
					unsigned long attrs);
21
extern void dma_generic_free_coherent(struct device *dev, size_t size,
22
				      void *vaddr, dma_addr_t dma_handle,
23
				      unsigned long attrs);
24

L
Linus Torvalds 已提交
25
#endif /* __ASM_SH_DMA_MAPPING_H */