/arch/mips/include/asm/mach-loongson/ |
D | dma-coherence.h | 29 dma_addr_t dma_addr) in plat_dma_addr_to_phys() argument 32 return (dma_addr > 0x8fffffff) ? dma_addr : (dma_addr & 0x0fffffff); in plat_dma_addr_to_phys() 34 return dma_addr & 0x7fffffff; in plat_dma_addr_to_phys() 38 static inline void plat_unmap_dma_mem(struct device *dev, dma_addr_t dma_addr, in plat_unmap_dma_mem() argument 61 dma_addr_t dma_addr) in plat_dma_mapping_error() argument
|
/arch/mips/include/asm/mach-jazz/ |
D | dma-coherence.h | 27 dma_addr_t dma_addr) in plat_dma_addr_to_phys() argument 29 return vdma_log2phys(dma_addr); in plat_dma_addr_to_phys() 32 static inline void plat_unmap_dma_mem(struct device *dev, dma_addr_t dma_addr, in plat_unmap_dma_mem() argument 35 vdma_free(dma_addr); in plat_unmap_dma_mem() 56 dma_addr_t dma_addr) in plat_dma_mapping_error() argument
|
/arch/arm/plat-mxc/ |
D | iram_alloc.c | 36 void __iomem *iram_alloc(unsigned int size, unsigned long *dma_addr) in iram_alloc() argument 41 *dma_addr = gen_pool_alloc(iram_pool, size); in iram_alloc() 42 pr_debug("iram alloc - %dB@0x%lX\n", size, *dma_addr); in iram_alloc() 43 if (!*dma_addr) in iram_alloc() 45 return iram_phys_to_virt(*dma_addr); in iram_alloc()
|
/arch/mips/include/asm/mach-ip32/ |
D | dma-coherence.h | 55 dma_addr_t dma_addr) in plat_dma_addr_to_phys() argument 57 unsigned long addr = dma_addr & RAM_OFFSET_MASK; in plat_dma_addr_to_phys() 59 if (dma_addr >= 256*1024*1024) in plat_dma_addr_to_phys() 65 static inline void plat_unmap_dma_mem(struct device *dev, dma_addr_t dma_addr, in plat_unmap_dma_mem() argument 89 dma_addr_t dma_addr) in plat_dma_mapping_error() argument
|
/arch/mips/include/asm/mach-generic/ |
D | dma-coherence.h | 27 dma_addr_t dma_addr) in plat_dma_addr_to_phys() argument 29 return dma_addr; in plat_dma_addr_to_phys() 32 static inline void plat_unmap_dma_mem(struct device *dev, dma_addr_t dma_addr, in plat_unmap_dma_mem() argument 55 dma_addr_t dma_addr) in plat_dma_mapping_error() argument
|
/arch/mips/include/asm/mach-rc32434/ |
D | dma_v.h | 41 static inline void rc32434_start_dma(struct dma_reg *ch, u32 dma_addr) in rc32434_start_dma() argument 44 __raw_writel(dma_addr, &ch->dmadptr); in rc32434_start_dma() 47 static inline void rc32434_chain_dma(struct dma_reg *ch, u32 dma_addr) in rc32434_chain_dma() argument 49 __raw_writel(dma_addr, &ch->dmandptr); in rc32434_chain_dma()
|
/arch/arm/plat-mxc/include/mach/ |
D | iram.h | 24 void __iomem *iram_alloc(unsigned int size, unsigned long *dma_addr); 25 void iram_free(unsigned long dma_addr, unsigned int size); 34 static inline void __iomem *iram_alloc(unsigned int size, unsigned long *dma_addr) in iram_alloc() argument
|
/arch/mips/include/asm/mach-ip27/ |
D | dma-coherence.h | 38 dma_addr_t dma_addr) in plat_dma_addr_to_phys() argument 40 return dma_addr & ~(0xffUL << 56); in plat_dma_addr_to_phys() 43 static inline void plat_unmap_dma_mem(struct device *dev, dma_addr_t dma_addr, in plat_unmap_dma_mem() argument 66 dma_addr_t dma_addr) in plat_dma_mapping_error() argument
|
/arch/mips/include/asm/mach-powertv/ |
D | dma-coherence.h | 79 dma_addr_t dma_addr) in plat_dma_addr_to_phys() argument 81 return dma_to_phys(dma_addr); in plat_dma_addr_to_phys() 84 static inline void plat_unmap_dma_mem(struct device *dev, dma_addr_t dma_addr, in plat_unmap_dma_mem() argument 107 dma_addr_t dma_addr) in plat_dma_mapping_error() argument
|
/arch/ia64/sn/pci/ |
D | pci_dma.c | 182 dma_addr_t dma_addr; in sn_dma_map_page() local 194 dma_addr = provider->dma_map_consistent(pdev, phys_addr, in sn_dma_map_page() 197 dma_addr = provider->dma_map(pdev, phys_addr, size, in sn_dma_map_page() 200 if (!dma_addr) { in sn_dma_map_page() 204 return dma_addr; in sn_dma_map_page() 219 static void sn_dma_unmap_page(struct device *dev, dma_addr_t dma_addr, in sn_dma_unmap_page() argument 228 provider->dma_unmap(pdev, dma_addr, dir); in sn_dma_unmap_page() 293 dma_addr_t dma_addr; in sn_dma_map_sg() local 296 dma_addr = provider->dma_map_consistent(pdev, in sn_dma_map_sg() 301 dma_addr = provider->dma_map(pdev, phys_addr, in sn_dma_map_sg() [all …]
|
/arch/mips/include/asm/mach-cavium-octeon/ |
D | dma-coherence.h | 33 dma_addr_t dma_addr) in plat_dma_addr_to_phys() argument 38 static inline void plat_unmap_dma_mem(struct device *dev, dma_addr_t dma_addr, in plat_unmap_dma_mem() argument 60 dma_addr_t dma_addr) in plat_dma_mapping_error() argument
|
/arch/arm/common/ |
D | dmabounce.c | 210 dma_addr_t dma_addr, const char *where) in find_safe_buffer_dev() argument 214 if (dma_mapping_error(dev, dma_addr)) { in find_safe_buffer_dev() 218 return find_safe_buffer(dev->archdata.dmabounce, dma_addr); in find_safe_buffer_dev() 221 static int needs_bounce(struct device *dev, dma_addr_t dma_addr, size_t size) in needs_bounce() argument 237 if ((dma_addr | (dma_addr + size - 1)) & ~mask) in needs_bounce() 241 return !!dev->archdata.dmabounce->needs_bounce(dev, dma_addr, size); in needs_bounce() 313 dma_addr_t dma_addr; in __dma_map_page() local 319 dma_addr = pfn_to_dma(dev, page_to_pfn(page)) + offset; in __dma_map_page() 321 ret = needs_bounce(dev, dma_addr, size); in __dma_map_page() 327 return dma_addr; in __dma_map_page() [all …]
|
/arch/hexagon/kernel/ |
D | dma.c | 58 dma_addr_t *dma_addr, gfp_t flag, in hexagon_dma_alloc_coherent() argument 78 *dma_addr = (dma_addr_t) (ret - PAGE_OFFSET); in hexagon_dma_alloc_coherent() 80 *dma_addr = ~0; in hexagon_dma_alloc_coherent() 86 dma_addr_t dma_addr, struct dma_attrs *attrs) in hexagon_free_coherent() argument 152 static inline void *dma_addr_to_virt(dma_addr_t dma_addr) in dma_addr_to_virt() argument 154 return phys_to_virt((unsigned long) dma_addr); in dma_addr_to_virt()
|
/arch/tile/kernel/ |
D | pci-dma.c | 91 static void __dma_map_pa_range(dma_addr_t dma_addr, size_t size) in __dma_map_pa_range() argument 93 struct page *page = pfn_to_page(PFN_DOWN(dma_addr)); in __dma_map_pa_range() 94 size_t bytesleft = PAGE_SIZE - (dma_addr & (PAGE_SIZE - 1)); in __dma_map_pa_range() 116 dma_addr_t dma_addr = __pa(ptr); in dma_map_single() local 121 __dma_map_pa_range(dma_addr, size); in dma_map_single() 123 return dma_addr; in dma_map_single() 127 void dma_unmap_single(struct device *dev, dma_addr_t dma_addr, size_t size, in dma_unmap_single() argument
|
/arch/sh/include/asm/ |
D | dma-mapping.h | 45 static inline int dma_mapping_error(struct device *dev, dma_addr_t dma_addr) in dma_mapping_error() argument 50 return ops->mapping_error(dev, dma_addr); in dma_mapping_error() 52 return dma_addr == 0; in dma_mapping_error() 93 dma_addr_t *dma_addr, gfp_t flag,
|
/arch/unicore32/mm/ |
D | dma-swiotlb.c | 28 void *vaddr, dma_addr_t dma_addr, in unicore_swiotlb_free_coherent() argument 31 swiotlb_free_coherent(dev, size, vaddr, dma_addr); in unicore_swiotlb_free_coherent()
|
/arch/mips/mm/ |
D | dma-default.c | 26 dma_addr_t dma_addr) in dma_addr_to_page() argument 29 plat_dma_addr_to_phys(dev, dma_addr) >> PAGE_SHIFT); in dma_addr_to_page() 209 static void mips_dma_unmap_page(struct device *dev, dma_addr_t dma_addr, in mips_dma_unmap_page() argument 213 __dma_sync(dma_addr_to_page(dev, dma_addr), in mips_dma_unmap_page() 214 dma_addr & ~PAGE_MASK, size, direction); in mips_dma_unmap_page() 216 plat_unmap_dma_mem(dev, dma_addr, size, direction); in mips_dma_unmap_page() 303 int mips_dma_mapping_error(struct device *dev, dma_addr_t dma_addr) in mips_dma_mapping_error() argument 305 return plat_dma_mapping_error(dev, dma_addr); in mips_dma_mapping_error()
|
/arch/powerpc/kernel/ |
D | iommu.c | 213 static void __iommu_free(struct iommu_table *tbl, dma_addr_t dma_addr, in __iommu_free() argument 218 entry = dma_addr >> IOMMU_PAGE_SHIFT; in __iommu_free() 226 printk(KERN_INFO "\tdma_addr = 0x%llx\n", (u64)dma_addr); in __iommu_free() 241 static void iommu_free(struct iommu_table *tbl, dma_addr_t dma_addr, in iommu_free() argument 248 __iommu_free(tbl, dma_addr, npages); in iommu_free() 265 dma_addr_t dma_next = 0, dma_addr; in iommu_map_sg() local 323 dma_addr = entry << IOMMU_PAGE_SHIFT; in iommu_map_sg() 324 dma_addr |= (s->offset & ~IOMMU_PAGE_MASK); in iommu_map_sg() 327 npages, entry, dma_addr); in iommu_map_sg() 342 if (novmerge || (dma_addr != dma_next) || in iommu_map_sg() [all …]
|
/arch/alpha/kernel/ |
D | pci_iommu.c | 371 static void alpha_pci_unmap_page(struct device *dev, dma_addr_t dma_addr, in alpha_pci_unmap_page() argument 384 if (dma_addr >= __direct_map_base in alpha_pci_unmap_page() 385 && dma_addr < __direct_map_base + __direct_map_size) { in alpha_pci_unmap_page() 389 dma_addr, size, __builtin_return_address(0)); in alpha_pci_unmap_page() 394 if (dma_addr > 0xffffffff) { in alpha_pci_unmap_page() 396 dma_addr, size, __builtin_return_address(0)); in alpha_pci_unmap_page() 401 if (!arena || dma_addr < arena->dma_base) in alpha_pci_unmap_page() 404 dma_ofs = (dma_addr - arena->dma_base) >> PAGE_SHIFT; in alpha_pci_unmap_page() 408 dma_addr, arena->dma_base, arena->size); in alpha_pci_unmap_page() 413 npages = iommu_num_pages(dma_addr, size, PAGE_SIZE); in alpha_pci_unmap_page() [all …]
|
/arch/ia64/kernel/ |
D | pci-swiotlb.c | 27 void *vaddr, dma_addr_t dma_addr, in ia64_swiotlb_free_coherent() argument 30 swiotlb_free_coherent(dev, size, vaddr, dma_addr); in ia64_swiotlb_free_coherent()
|
/arch/hexagon/include/asm/ |
D | dma-mapping.h | 64 static inline int dma_mapping_error(struct device *dev, dma_addr_t dma_addr) in dma_mapping_error() argument 69 return dma_ops->mapping_error(dev, dma_addr); in dma_mapping_error() 71 return (dma_addr == bad_dma_address); in dma_mapping_error()
|
/arch/x86/include/asm/ |
D | dma-mapping.h | 46 static inline int dma_mapping_error(struct device *dev, dma_addr_t dma_addr) in dma_mapping_error() argument 50 return ops->mapping_error(dev, dma_addr); in dma_mapping_error() 52 return (dma_addr == DMA_ERROR_CODE); in dma_mapping_error() 62 dma_addr_t *dma_addr, gfp_t flag,
|
/arch/blackfin/include/asm/ |
D | dma-mapping.h | 37 dma_mapping_error(struct device *dev, dma_addr_t dma_addr) in dma_mapping_error() argument 86 dma_unmap_single(struct device *dev, dma_addr_t dma_addr, size_t size, in dma_unmap_single() argument 93 dma_unmap_page(struct device *dev, dma_addr_t dma_addr, size_t size, in dma_unmap_page() argument 96 dma_unmap_single(dev, dma_addr, size, dir); in dma_unmap_page()
|
/arch/x86/kernel/ |
D | pci-swiotlb.c | 32 void *vaddr, dma_addr_t dma_addr, in x86_swiotlb_free_coherent() argument 35 swiotlb_free_coherent(dev, size, vaddr, dma_addr); in x86_swiotlb_free_coherent()
|
D | amd_gart_64.c | 265 static void gart_unmap_page(struct device *dev, dma_addr_t dma_addr, in gart_unmap_page() argument 273 if (dma_addr < iommu_bus_base + EMERGENCY_PAGES*PAGE_SIZE || in gart_unmap_page() 274 dma_addr >= iommu_bus_base + iommu_size) in gart_unmap_page() 277 iommu_page = (dma_addr - iommu_bus_base)>>PAGE_SHIFT; in gart_unmap_page() 278 npages = iommu_num_pages(dma_addr, size, PAGE_SIZE); in gart_unmap_page() 479 gart_alloc_coherent(struct device *dev, size_t size, dma_addr_t *dma_addr, in gart_alloc_coherent() argument 498 *dma_addr = paddr; in gart_alloc_coherent() 503 return dma_generic_alloc_coherent(dev, size, dma_addr, flag, in gart_alloc_coherent() 512 dma_addr_t dma_addr, struct dma_attrs *attrs) in gart_free_coherent() argument 514 gart_unmap_page(dev, dma_addr, size, DMA_BIDIRECTIONAL, NULL); in gart_free_coherent() [all …]
|