diff options
Diffstat (limited to 'include/linux/swiotlb.h')
-rw-r--r-- | include/linux/swiotlb.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/include/linux/swiotlb.h b/include/linux/swiotlb.h index 24ed817082ee..5b1f2a00491c 100644 --- a/include/linux/swiotlb.h +++ b/include/linux/swiotlb.h | |||
@@ -66,6 +66,12 @@ extern void swiotlb_tbl_sync_single(struct device *hwdev, | |||
66 | enum dma_sync_target target); | 66 | enum dma_sync_target target); |
67 | 67 | ||
68 | /* Accessory functions. */ | 68 | /* Accessory functions. */ |
69 | |||
70 | void *swiotlb_alloc(struct device *hwdev, size_t size, dma_addr_t *dma_handle, | ||
71 | gfp_t flags, unsigned long attrs); | ||
72 | void swiotlb_free(struct device *dev, size_t size, void *vaddr, | ||
73 | dma_addr_t dma_addr, unsigned long attrs); | ||
74 | |||
69 | extern void | 75 | extern void |
70 | *swiotlb_alloc_coherent(struct device *hwdev, size_t size, | 76 | *swiotlb_alloc_coherent(struct device *hwdev, size_t size, |
71 | dma_addr_t *dma_handle, gfp_t flags); | 77 | dma_addr_t *dma_handle, gfp_t flags); |
@@ -115,10 +121,10 @@ extern int | |||
115 | swiotlb_dma_supported(struct device *hwdev, u64 mask); | 121 | swiotlb_dma_supported(struct device *hwdev, u64 mask); |
116 | 122 | ||
117 | #ifdef CONFIG_SWIOTLB | 123 | #ifdef CONFIG_SWIOTLB |
118 | extern void __init swiotlb_free(void); | 124 | extern void __init swiotlb_exit(void); |
119 | unsigned int swiotlb_max_segment(void); | 125 | unsigned int swiotlb_max_segment(void); |
120 | #else | 126 | #else |
121 | static inline void swiotlb_free(void) { } | 127 | static inline void swiotlb_exit(void) { } |
122 | static inline unsigned int swiotlb_max_segment(void) { return 0; } | 128 | static inline unsigned int swiotlb_max_segment(void) { return 0; } |
123 | #endif | 129 | #endif |
124 | 130 | ||
@@ -126,4 +132,6 @@ extern void swiotlb_print_info(void); | |||
126 | extern int is_swiotlb_buffer(phys_addr_t paddr); | 132 | extern int is_swiotlb_buffer(phys_addr_t paddr); |
127 | extern void swiotlb_set_max_segment(unsigned int); | 133 | extern void swiotlb_set_max_segment(unsigned int); |
128 | 134 | ||
135 | extern const struct dma_map_ops swiotlb_dma_ops; | ||
136 | |||
129 | #endif /* __LINUX_SWIOTLB_H */ | 137 | #endif /* __LINUX_SWIOTLB_H */ |