Home
last modified time | relevance | path

Searched refs:cpu_addr (Results 1 – 25 of 188) sorted by relevance

12345678

/linux/kernel/dma/
H A Dops_helpers.c9 static struct page *dma_common_vaddr_to_page(void *cpu_addr) in dma_common_vaddr_to_page() argument
11 if (is_vmalloc_addr(cpu_addr)) in dma_common_vaddr_to_page()
12 return vmalloc_to_page(cpu_addr); in dma_common_vaddr_to_page()
13 return virt_to_page(cpu_addr); in dma_common_vaddr_to_page()
20 void *cpu_addr, dma_addr_t dma_addr, size_t size, in dma_common_get_sgtable() argument
23 struct page *page = dma_common_vaddr_to_page(cpu_addr); in dma_common_get_sgtable()
36 void *cpu_addr, dma_addr_t dma_addr, size_t size, in dma_common_mmap() argument
43 struct page *page = dma_common_vaddr_to_page(cpu_addr); in dma_common_mmap()
48 if (dma_mmap_from_dev_coherent(dev, vma, cpu_addr, size, &ret)) in dma_common_mmap()
H A Dremap.c9 struct page **dma_common_find_pages(void *cpu_addr) in dma_common_find_pages() argument
11 struct vm_struct *area = find_vm_area(cpu_addr); in dma_common_find_pages()
16 "unexpected flags in area: %p\n", cpu_addr); in dma_common_find_pages()
62 void dma_common_free_remap(void *cpu_addr, size_t size) in dma_common_free_remap() argument
64 struct vm_struct *area = find_vm_area(cpu_addr); in dma_common_free_remap()
67 WARN(1, "trying to free invalid coherent area: %p\n", cpu_addr); in dma_common_free_remap()
71 vunmap(cpu_addr); in dma_common_free_remap()
H A Dmapping.c482 void *cpu_addr, dma_addr_t dma_addr, size_t size, in dma_get_sgtable_attrs() argument
488 return dma_direct_get_sgtable(dev, sgt, cpu_addr, dma_addr, in dma_get_sgtable_attrs()
491 return iommu_dma_get_sgtable(dev, sgt, cpu_addr, dma_addr, in dma_get_sgtable_attrs()
495 return ops->get_sgtable(dev, sgt, cpu_addr, dma_addr, size, attrs); in dma_get_sgtable_attrs()
549 void *cpu_addr, dma_addr_t dma_addr, size_t size, in dma_mmap_attrs() argument
555 return dma_direct_mmap(dev, vma, cpu_addr, dma_addr, size, in dma_mmap_attrs()
558 return iommu_dma_mmap(dev, vma, cpu_addr, dma_addr, size, in dma_mmap_attrs()
562 return ops->mmap(dev, vma, cpu_addr, dma_addr, size, attrs); in dma_mmap_attrs()
595 void *cpu_addr; in dma_alloc_attrs() local
607 if (dma_alloc_from_dev_coherent(dev, size, dma_handle, &cpu_addr)) in dma_alloc_attrs()
[all …]
H A Ddirect.c315 void *cpu_addr, dma_addr_t dma_addr, unsigned long attrs) in dma_direct_free() argument
322 dma_free_contiguous(dev, cpu_addr, size); in dma_direct_free()
329 arch_dma_free(dev, size, cpu_addr, dma_addr, attrs); in dma_direct_free()
335 if (!dma_release_from_global_coherent(page_order, cpu_addr)) in dma_direct_free()
342 dma_free_from_pool(dev, cpu_addr, PAGE_ALIGN(size))) in dma_direct_free()
345 if (is_vmalloc_addr(cpu_addr)) { in dma_direct_free()
346 vunmap(cpu_addr); in dma_direct_free()
349 arch_dma_clear_uncached(cpu_addr, size); in dma_direct_free()
350 if (dma_set_encrypted(dev, cpu_addr, size)) in dma_direct_free()
522 void *cpu_addr, dma_addr_t dma_addr, size_t size, in dma_direct_get_sgtable() argument
[all …]
/linux/drivers/pci/controller/cadence/
H A Dpcie-cadence.c29 u64 cpu_addr, u64 pci_addr, size_t size) in cdns_pcie_set_outbound_region() argument
94 cpu_addr = pcie->ops->cpu_addr_fixup(pcie, cpu_addr); in cdns_pcie_set_outbound_region()
97 (lower_32_bits(cpu_addr) & GENMASK(31, 8)); in cdns_pcie_set_outbound_region()
98 addr1 = upper_32_bits(cpu_addr); in cdns_pcie_set_outbound_region()
106 u32 r, u64 cpu_addr) in cdns_pcie_set_outbound_region_for_normal_msg() argument
124 cpu_addr = pcie->ops->cpu_addr_fixup(pcie, cpu_addr); in cdns_pcie_set_outbound_region_for_normal_msg()
127 (lower_32_bits(cpu_addr) & GENMASK(31, 8)); in cdns_pcie_set_outbound_region_for_normal_msg()
128 addr1 = upper_32_bits(cpu_addr); in cdns_pcie_set_outbound_region_for_normal_msg()
H A Dpcie-cadence-host.c220 u64 cpu_addr, u64 size, in cdns_pcie_host_bar_ib_config() argument
233 (lower_32_bits(cpu_addr) & GENMASK(31, 8)); in cdns_pcie_host_bar_ib_config()
234 addr1 = upper_32_bits(cpu_addr); in cdns_pcie_host_bar_ib_config()
247 if (size + cpu_addr >= SZ_4G) { in cdns_pcie_host_bar_ib_config()
314 u64 cpu_addr, pci_addr, size, winsize; in cdns_pcie_host_bar_config() local
321 cpu_addr = entry->res->start; in cdns_pcie_host_bar_config()
328 pci_addr, cpu_addr); in cdns_pcie_host_bar_config()
343 ret = cdns_pcie_host_bar_ib_config(rc, bar, cpu_addr, in cdns_pcie_host_bar_config()
364 cpu_addr); in cdns_pcie_host_bar_config()
369 ret = cdns_pcie_host_bar_ib_config(rc, bar, cpu_addr, winsize, in cdns_pcie_host_bar_config()
[all …]
/linux/arch/s390/kvm/
H A Dtrace.h220 TP_PROTO(VCPU_PROTO_COMMON, __u8 order_code, __u16 cpu_addr, \
222 TP_ARGS(VCPU_ARGS_COMMON, order_code, cpu_addr, parameter),
227 __field(__u16, cpu_addr)
234 __entry->cpu_addr = cpu_addr;
242 __entry->cpu_addr, __entry->parameter)
246 TP_PROTO(VCPU_PROTO_COMMON, __u8 order_code, __u16 cpu_addr),
247 TP_ARGS(VCPU_ARGS_COMMON, order_code, cpu_addr),
252 __field(__u16, cpu_addr)
258 __entry->cpu_addr = cpu_addr;
265 __entry->cpu_addr)
H A Dsigp.c271 u16 cpu_addr, u32 parameter, u64 *status_reg) in handle_sigp_dst() argument
274 struct kvm_vcpu *dst_vcpu = kvm_get_vcpu_by_id(vcpu->kvm, cpu_addr); in handle_sigp_dst()
376 u16 cpu_addr) in handle_sigp_order_in_user_space() argument
420 order_code, cpu_addr); in handle_sigp_order_in_user_space()
430 u16 cpu_addr = vcpu->run->s.regs.gprs[r3]; in kvm_s390_handle_sigp() local
439 if (handle_sigp_order_in_user_space(vcpu, order_code, cpu_addr)) in kvm_s390_handle_sigp()
447 trace_kvm_s390_handle_sigp(vcpu, order_code, cpu_addr, parameter); in kvm_s390_handle_sigp()
455 rc = handle_sigp_dst(vcpu, order_code, cpu_addr, in kvm_s390_handle_sigp()
479 u16 cpu_addr = vcpu->run->s.regs.gprs[r3]; in kvm_s390_handle_sigp_pei() local
484 trace_kvm_s390_handle_sigp_pei(vcpu, order_code, cpu_addr); in kvm_s390_handle_sigp_pei()
[all …]
/linux/include/trace/events/
H A Dhabanalabs.h54 TP_PROTO(struct device *dev, u64 cpu_addr, u64 dma_addr, size_t size, const char *caller),
56 TP_ARGS(dev, cpu_addr, dma_addr, size, caller),
60 __field(u64, cpu_addr)
68 __entry->cpu_addr = cpu_addr;
74 TP_printk("%s: cpu_addr: %#llx, dma_addr: %#llx, size: %#x, caller: %s",
76 __entry->cpu_addr,
83 TP_PROTO(struct device *dev, u64 cpu_addr, u64 dma_addr, size_t size, const char *caller),
84 TP_ARGS(dev, cpu_addr, dma_addr, size, caller));
87 TP_PROTO(struct device *dev, u64 cpu_addr, u6
[all...]
/linux/drivers/gpu/drm/amd/amdgpu/
H A Damdgpu_doorbell_mgr.c42 return readl(adev->doorbell.cpu_addr + index); in amdgpu_mm_rdoorbell()
64 writel(v, adev->doorbell.cpu_addr + index); in amdgpu_mm_wdoorbell()
84 return atomic64_read((atomic64_t *)(adev->doorbell.cpu_addr + index)); in amdgpu_mm_rdoorbell64()
106 atomic64_set((atomic64_t *)(adev->doorbell.cpu_addr + index), v); in amdgpu_mm_wdoorbell64()
167 (void **)&adev->doorbell.cpu_addr); in amdgpu_doorbell_create_kernel_doorbells()
238 (void **)&adev->doorbell.cpu_addr); in amdgpu_doorbell_fini()
/linux/arch/openrisc/kernel/
H A Ddma.c68 void *arch_dma_set_uncached(void *cpu_addr, size_t size) in arch_dma_set_uncached() argument
70 unsigned long va = (unsigned long)cpu_addr; in arch_dma_set_uncached()
84 return cpu_addr; in arch_dma_set_uncached()
87 void arch_dma_clear_uncached(void *cpu_addr, size_t size) in arch_dma_clear_uncached() argument
89 unsigned long va = (unsigned long)cpu_addr; in arch_dma_clear_uncached()
/linux/drivers/media/common/saa7146/
H A Dsaa7146_core.c403 dev->d_rps0.cpu_addr = dma_alloc_coherent(&pci->dev, SAA7146_RPS_MEM, in saa7146_init_one()
406 if (!dev->d_rps0.cpu_addr) in saa7146_init_one()
409 dev->d_rps1.cpu_addr = dma_alloc_coherent(&pci->dev, SAA7146_RPS_MEM, in saa7146_init_one()
412 if (!dev->d_rps1.cpu_addr) in saa7146_init_one()
415 dev->d_i2c.cpu_addr = dma_alloc_coherent(&pci->dev, SAA7146_RPS_MEM, in saa7146_init_one()
417 if (!dev->d_i2c.cpu_addr) in saa7146_init_one()
464 dma_free_coherent(&pci->dev, SAA7146_RPS_MEM, dev->d_i2c.cpu_addr, in saa7146_init_one()
467 dma_free_coherent(&pci->dev, SAA7146_RPS_MEM, dev->d_rps1.cpu_addr, in saa7146_init_one()
470 dma_free_coherent(&pci->dev, SAA7146_RPS_MEM, dev->d_rps0.cpu_addr, in saa7146_init_one()
493 { dev->d_i2c.cpu_addr, dev->d_i2c.dma_handle }, in saa7146_remove_one()
[all …]
/linux/drivers/remoteproc/
H A Dti_k3_m4_remoteproc.c34 void __iomem *cpu_addr; member
260 if (!kproc->rmem[0].cpu_addr) { in k3_m4_get_loaded_rsc_table()
273 return (__force struct resource_table *)kproc->rmem[0].cpu_addr; in k3_m4_get_loaded_rsc_table()
305 va = kproc->mem[i].cpu_addr + offset; in k3_m4_rproc_da_to_va()
312 va = kproc->mem[i].cpu_addr + offset; in k3_m4_rproc_da_to_va()
324 va = kproc->rmem[i].cpu_addr + offset; in k3_m4_rproc_da_to_va()
364 kproc->mem[i].cpu_addr = devm_ioremap_wc(dev, res->start, in k3_m4_rproc_of_get_memories()
366 if (!kproc->mem[i].cpu_addr) { in k3_m4_rproc_of_get_memories()
377 kproc->mem[i].size, kproc->mem[i].cpu_addr, in k3_m4_rproc_of_get_memories()
446 kproc->rmem[i].cpu_addr = devm_ioremap_wc(dev, rmem->base, rmem->size); in k3_m4_reserved_mem_init()
[all …]
/linux/drivers/pci/controller/mobiveil/
H A Dpcie-mobiveil.c137 u64 cpu_addr, u64 pci_addr, u32 type, u64 size) in program_ib_windows() argument
157 mobiveil_csr_writel(pcie, lower_32_bits(cpu_addr), in program_ib_windows()
159 mobiveil_csr_writel(pcie, upper_32_bits(cpu_addr), in program_ib_windows()
174 u64 cpu_addr, u64 pci_addr, u32 type, u64 size) in program_ob_windows() argument
203 lower_32_bits(cpu_addr) & (~AXI_WINDOW_ALIGN_MASK), in program_ob_windows()
205 mobiveil_csr_writel(pcie, upper_32_bits(cpu_addr), in program_ob_windows()
/linux/arch/mips/mm/
H A Dioremap.c54 void __iomem *cpu_addr; in ioremap_prot() local
56 cpu_addr = plat_ioremap(phys_addr, size, flags); in ioremap_prot()
57 if (cpu_addr) in ioremap_prot()
58 return cpu_addr; in ioremap_prot()
/linux/drivers/iommu/
H A Ddma-iommu.c1560 static void __iommu_dma_free(struct device *dev, size_t size, void *cpu_addr) in __iommu_dma_free() argument
1568 dma_free_from_pool(dev, cpu_addr, alloc_size)) in __iommu_dma_free()
1571 if (is_vmalloc_addr(cpu_addr)) { in __iommu_dma_free()
1576 pages = dma_common_find_pages(cpu_addr); in __iommu_dma_free()
1578 page = vmalloc_to_page(cpu_addr); in __iommu_dma_free()
1579 dma_common_free_remap(cpu_addr, alloc_size); in __iommu_dma_free()
1582 page = virt_to_page(cpu_addr); in __iommu_dma_free()
1591 void iommu_dma_free(struct device *dev, size_t size, void *cpu_addr, in iommu_dma_free() argument
1595 __iommu_dma_free(dev, size, cpu_addr); in iommu_dma_free()
1605 void *cpu_addr; in iommu_dma_alloc_pages() local
[all …]
/linux/include/linux/
H A Ddma-map-ops.h31 void *cpu_addr, dma_addr_t dma_addr, size_t size,
166 void *cpu_addr, size_t size, int *ret);
184 int dma_mmap_from_global_coherent(struct vm_area_struct *vma, void *cpu_addr,
198 void *cpu_addr, size_t size, int *ret) in dma_mmap_from_global_coherent() argument
205 void *cpu_addr, dma_addr_t dma_addr, size_t size,
208 void *cpu_addr, dma_addr_t dma_addr, size_t size,
215 struct page **dma_common_find_pages(void *cpu_addr);
220 void dma_common_free_remap(void *cpu_addr, size_t size);
223 void **cpu_addr, gfp_t flags,
318 void arch_dma_free(struct device *dev, size_t size, void *cpu_addr,
/linux/arch/arm/mm/
H A Ddma-mapping.c54 void *cpu_addr; member
427 void *cpu_addr, size_t size, bool want_vaddr) in __free_from_contiguous() argument
431 dma_common_free_remap(cpu_addr, size); in __free_from_contiguous()
487 __free_from_contiguous(args->dev, args->page, args->cpu_addr, in cma_allocator_free()
504 __free_from_pool(args->cpu_addr, args->size); in pool_allocator_free()
523 dma_common_free_remap(args->cpu_addr, args->size); in remap_allocator_free()
605 static void __arm_dma_free(struct device *dev, size_t size, void *cpu_addr, in __arm_dma_free() argument
614 .cpu_addr = cpu_addr, in __arm_dma_free()
619 buf = arm_dma_buffer_find(cpu_addr); in __arm_dma_free()
620 if (WARN(!buf, "Freeing invalid buffer %p\n", cpu_addr)) in __arm_dma_free()
[all …]
/linux/arch/mips/loongson64/
H A Dinit.c208 range.cpu_addr, in reserve_pio_range()
209 range.cpu_addr + range.size - 1, in reserve_pio_range()
211 if (add_legacy_isa_io(&np->fwnode, range.cpu_addr, range.size)) in reserve_pio_range()
216 range.cpu_addr, in reserve_pio_range()
217 range.cpu_addr + range.size - 1, in reserve_pio_range()
/linux/drivers/accel/ivpu/
H A Divpu_gem.h87 static inline u32 cpu_to_vpu_addr(struct ivpu_bo *bo, void *cpu_addr) in cpu_to_vpu_addr() argument
89 if (cpu_addr < ivpu_bo_vaddr(bo)) in cpu_to_vpu_addr()
92 if (cpu_addr >= (ivpu_bo_vaddr(bo) + ivpu_bo_size(bo))) in cpu_to_vpu_addr()
95 return bo->vpu_addr + (cpu_addr - ivpu_bo_vaddr(bo)); in cpu_to_vpu_addr()
/linux/drivers/dma/
H A Dst_fdma.h185 readl((fchan)->fdev->slim_rproc->mem[ST_SLIM_DMEM].cpu_addr \
190 writel((val), (fchan)->fdev->slim_rproc->mem[ST_SLIM_DMEM].cpu_addr \
197 writel((val), (fchan)->fdev->slim_rproc->mem[ST_SLIM_DMEM].cpu_addr \
207 readl((fchan)->fdev->slim_rproc->mem[ST_SLIM_DMEM].cpu_addr \
212 writel((val), (fchan)->fdev->slim_rproc->mem[ST_SLIM_DMEM].cpu_addr \
/linux/drivers/pci/controller/dwc/
H A Dpcie-tegra194-acpi.c49 int index, int type, u64 cpu_addr, in program_outbound_atu() argument
52 atu_reg_write(pcie_ecam, index, lower_32_bits(cpu_addr), in program_outbound_atu()
54 atu_reg_write(pcie_ecam, index, upper_32_bits(cpu_addr), in program_outbound_atu()
58 atu_reg_write(pcie_ecam, index, lower_32_bits(cpu_addr + size - 1), in program_outbound_atu()
H A Dpcie-designware.c473 u64 cpu_addr = atu->cpu_addr; in dw_pcie_prog_outbound_atu() local
478 cpu_addr = pci->ops->cpu_addr_fixup(pci, cpu_addr); in dw_pcie_prog_outbound_atu()
480 limit_addr = cpu_addr + atu->size - 1; in dw_pcie_prog_outbound_atu()
482 if ((limit_addr & ~pci->region_limit) != (cpu_addr & ~pci->region_limit) || in dw_pcie_prog_outbound_atu()
483 !IS_ALIGNED(cpu_addr, pci->region_align) || in dw_pcie_prog_outbound_atu()
489 lower_32_bits(cpu_addr)); in dw_pcie_prog_outbound_atu()
491 upper_32_bits(cpu_addr)); in dw_pcie_prog_outbound_atu()
505 if (upper_32_bits(limit_addr) > upper_32_bits(cpu_addr) && in dw_pcie_prog_outbound_atu()
548 u64 cpu_addr, u64 pci_addr, u64 size) in dw_pcie_prog_inbound_atu() argument
554 !IS_ALIGNED(cpu_addr, pci->region_align) || in dw_pcie_prog_inbound_atu()
[all …]
/linux/drivers/of/
H A Daddress.c244 err = pci_register_io_range(&np->fwnode, range->cpu_addr, in of_pci_range_to_resource()
248 port = pci_address_to_pio(range->cpu_addr); in of_pci_range_to_resource()
255 start = range->cpu_addr; in of_pci_range_to_resource()
809 range->cpu_addr = of_translate_dma_address(parser->node, in of_pci_range_parser_one()
812 range->cpu_addr = of_translate_address(parser->node, in of_pci_range_parser_one()
821 u64 bus_addr, cpu_addr, size; in of_pci_range_parser_one() local
826 cpu_addr = of_translate_dma_address(parser->node, in of_pci_range_parser_one()
829 cpu_addr = of_translate_address(parser->node, in of_pci_range_parser_one()
836 cpu_addr != range->cpu_addr + range->size) in of_pci_range_parser_one()
920 if (range.cpu_addr == OF_BAD_ADDR) { in of_dma_get_range()
[all …]
/linux/net/smc/
H A Dsmc_loopback.c77 dmb_node->cpu_addr = kzalloc(dmb_node->len, GFP_KERNEL | in smc_lo_register_dmb()
80 if (!dmb_node->cpu_addr) { in smc_lo_register_dmb()
103 dmb->cpu_addr = dmb_node->cpu_addr; in smc_lo_register_dmb()
125 kvfree(dmb_node->cpu_addr); in __smc_lo_unregister_dmb()
189 dmb->cpu_addr = dmb_node->cpu_addr; in smc_lo_attach_dmb()
244 memcpy((char *)rmb_node->cpu_addr + offset, data, size); in smc_lo_move_data()

12345678