Merge tag 'pm-4.13-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
[linux/fpc-iii.git] / arch / x86 / include / asm / swiotlb.h
blobd2f69b9ff73273588f20bb86d09ed3ee63f2e033
1 #ifndef _ASM_X86_SWIOTLB_H
2 #define _ASM_X86_SWIOTLB_H
4 #include <linux/swiotlb.h>
6 #ifdef CONFIG_SWIOTLB
7 extern int swiotlb;
8 extern int __init pci_swiotlb_detect_override(void);
9 extern int __init pci_swiotlb_detect_4gb(void);
10 extern void __init pci_swiotlb_init(void);
11 extern void __init pci_swiotlb_late_init(void);
12 #else
13 #define swiotlb 0
14 static inline int pci_swiotlb_detect_override(void)
16 return 0;
18 static inline int pci_swiotlb_detect_4gb(void)
20 return 0;
22 static inline void pci_swiotlb_init(void)
25 static inline void pci_swiotlb_late_init(void)
28 #endif
30 static inline void dma_mark_clean(void *addr, size_t size) {}
32 extern void *x86_swiotlb_alloc_coherent(struct device *hwdev, size_t size,
33 dma_addr_t *dma_handle, gfp_t flags,
34 unsigned long attrs);
35 extern void x86_swiotlb_free_coherent(struct device *dev, size_t size,
36 void *vaddr, dma_addr_t dma_addr,
37 unsigned long attrs);
39 #endif /* _ASM_X86_SWIOTLB_H */