/linux-6.3-rc2/drivers/dma-buf/ |
A D | dma-buf.c | 797 attach->dmabuf->ops->unmap_dma_buf(attach, sg_table, in __map_dma_buf() 907 attach = kzalloc(sizeof(*attach), GFP_KERNEL); in dma_buf_dynamic_attach() 919 ret = dmabuf->ops->attach(dmabuf, attach); in dma_buf_dynamic_attach() 1015 __unmap_dma_buf(attach, attach->sgt, attach->dir); in dma_buf_detach() 1111 if (WARN_ON(!attach || !attach->dmabuf)) in dma_buf_map_attachment() 1130 r = attach->dmabuf->ops->pin(attach); in dma_buf_map_attachment() 1142 attach->dmabuf->ops->unpin(attach); in dma_buf_map_attachment() 1187 if (WARN_ON(!attach || !attach->dmabuf)) in dma_buf_map_attachment_unlocked() 1214 if (WARN_ON(!attach || !attach->dmabuf || !sg_table)) in dma_buf_unmap_attachment() 1246 if (WARN_ON(!attach || !attach->dmabuf || !sg_table)) in dma_buf_unmap_attachment_unlocked() [all …]
|
/linux-6.3-rc2/tools/testing/selftests/bpf/ |
A D | DENYLIST.aarch64 | 16 cgroup_hierarchical_stats # attach unexpected error: -524 (errno 524) 17 d_path/basic # setup attach failed: -524 18 deny_namespace # attach unexpected error: -524 (errno 524) 21 fexit_sleep # fexit_attach fexit attach failed: -1 22 fexit_stress # fexit attach unexpected fexit attach: actual -52… 46 module_attach # skel_attach skeleton attach failed: -524 49 rcu_read_lock # failed to attach: ERROR: strerror_r(-524)=22 59 test_bprm_opts # attach attach failed: -524 60 test_ima # attach attach failed: -524 61 test_local_storage # attach lsm attach failed: -524 [all …]
|
/linux-6.3-rc2/drivers/infiniband/core/ |
A D | umem_dmabuf.c | 24 dma_resv_assert_held(umem_dmabuf->attach->dmabuf->resv); in ib_umem_dmabuf_map_pages() 29 sgt = dma_buf_map_attachment(umem_dmabuf->attach, in ib_umem_dmabuf_map_pages() 153 umem_dmabuf->attach = dma_buf_dynamic_attach( in ib_umem_dmabuf_get() 158 if (IS_ERR(umem_dmabuf->attach)) { in ib_umem_dmabuf_get() 159 ret = ERR_CAST(umem_dmabuf->attach); in ib_umem_dmabuf_get() 201 err = dma_buf_pin(umem_dmabuf->attach); in ib_umem_dmabuf_get_pinned() 209 dma_resv_unlock(umem_dmabuf->attach->dmabuf->resv); in ib_umem_dmabuf_get_pinned() 214 dma_buf_unpin(umem_dmabuf->attach); in ib_umem_dmabuf_get_pinned() 216 dma_resv_unlock(umem_dmabuf->attach->dmabuf->resv); in ib_umem_dmabuf_get_pinned() 229 dma_buf_unpin(umem_dmabuf->attach); in ib_umem_dmabuf_release() [all …]
|
/linux-6.3-rc2/drivers/gpu/drm/amd/amdgpu/ |
A D | amdgpu_dma_buf.c | 55 struct dma_buf_attachment *attach) in amdgpu_dma_buf_attach() argument 63 attach->peer2peer = false; in amdgpu_dma_buf_attach() 85 struct dma_buf_attachment *attach) in amdgpu_dma_buf_detach() argument 142 struct dma_buf *dma_buf = attach->dmabuf; in amdgpu_dma_buf_map() 155 attach->peer2peer) { in amdgpu_dma_buf_map() 184 bo->tbo.base.size, attach->dev, in amdgpu_dma_buf_map() 265 .attach = amdgpu_dma_buf_attach, 436 struct dma_buf_attachment *attach; in amdgpu_gem_prime_import() local 457 if (IS_ERR(attach)) { in amdgpu_gem_prime_import() 459 return ERR_CAST(attach); in amdgpu_gem_prime_import() [all …]
|
/linux-6.3-rc2/drivers/media/common/videobuf2/ |
A D | videobuf2-vmalloc.c | 223 attach = kzalloc(sizeof(*attach), GFP_KERNEL); in vb2_vmalloc_dmabuf_ops_attach() 224 if (!attach) in vb2_vmalloc_dmabuf_ops_attach() 227 sgt = &attach->sgt; in vb2_vmalloc_dmabuf_ops_attach() 230 kfree(attach); in vb2_vmalloc_dmabuf_ops_attach() 238 kfree(attach); in vb2_vmalloc_dmabuf_ops_attach() 245 attach->dma_dir = DMA_NONE; in vb2_vmalloc_dmabuf_ops_attach() 256 if (!attach) in vb2_vmalloc_dmabuf_ops_detach() 259 sgt = &attach->sgt; in vb2_vmalloc_dmabuf_ops_detach() 265 kfree(attach); in vb2_vmalloc_dmabuf_ops_detach() 275 sgt = &attach->sgt; in vb2_vmalloc_dmabuf_ops_map() [all …]
|
A D | videobuf2-dma-sg.c | 379 attach = kzalloc(sizeof(*attach), GFP_KERNEL); in vb2_dma_sg_dmabuf_ops_attach() 380 if (!attach) in vb2_dma_sg_dmabuf_ops_attach() 383 sgt = &attach->sgt; in vb2_dma_sg_dmabuf_ops_attach() 389 kfree(attach); in vb2_dma_sg_dmabuf_ops_attach() 401 attach->dma_dir = DMA_NONE; in vb2_dma_sg_dmabuf_ops_attach() 402 dbuf_attach->priv = attach; in vb2_dma_sg_dmabuf_ops_attach() 413 if (!attach) in vb2_dma_sg_dmabuf_ops_detach() 416 sgt = &attach->sgt; in vb2_dma_sg_dmabuf_ops_detach() 422 kfree(attach); in vb2_dma_sg_dmabuf_ops_detach() 432 sgt = &attach->sgt; in vb2_dma_sg_dmabuf_ops_map() [all …]
|
A D | videobuf2-dma-contig.c | 328 attach = kzalloc(sizeof(*attach), GFP_KERNEL); in vb2_dc_dmabuf_ops_attach() 329 if (!attach) in vb2_dc_dmabuf_ops_attach() 332 sgt = &attach->sgt; in vb2_dc_dmabuf_ops_attach() 338 kfree(attach); in vb2_dc_dmabuf_ops_attach() 350 attach->dma_dir = DMA_NONE; in vb2_dc_dmabuf_ops_attach() 351 dbuf_attach->priv = attach; in vb2_dc_dmabuf_ops_attach() 362 if (!attach) in vb2_dc_dmabuf_ops_detach() 365 sgt = &attach->sgt; in vb2_dc_dmabuf_ops_detach() 378 kfree(attach); in vb2_dc_dmabuf_ops_detach() 388 sgt = &attach->sgt; in vb2_dc_dmabuf_ops_map() [all …]
|
/linux-6.3-rc2/include/linux/ |
A D | dma-buf.h | 72 int (*attach)(struct dma_buf *, struct dma_buf_attachment *); member 109 int (*pin)(struct dma_buf_attachment *attach); 122 void (*unpin)(struct dma_buf_attachment *attach); 483 void (*move_notify)(struct dma_buf_attachment *attach); 590 dma_buf_attachment_is_dynamic(struct dma_buf_attachment *attach) in dma_buf_attachment_is_dynamic() argument 592 return !!attach->importer_ops; in dma_buf_attachment_is_dynamic() 602 struct dma_buf_attachment *attach); 603 int dma_buf_pin(struct dma_buf_attachment *attach); 604 void dma_buf_unpin(struct dma_buf_attachment *attach); 622 dma_buf_map_attachment_unlocked(struct dma_buf_attachment *attach, [all …]
|
/linux-6.3-rc2/drivers/gpu/drm/virtio/ |
A D | virtgpu_prime.c | 47 virtgpu_gem_map_dma_buf(struct dma_buf_attachment *attach, in virtgpu_gem_map_dma_buf() argument 50 struct drm_gem_object *obj = attach->dmabuf->priv; in virtgpu_gem_map_dma_buf() 54 return virtio_gpu_vram_map_dma_buf(bo, attach->dev, dir); in virtgpu_gem_map_dma_buf() 56 return drm_gem_map_dma_buf(attach, dir); in virtgpu_gem_map_dma_buf() 59 static void virtgpu_gem_unmap_dma_buf(struct dma_buf_attachment *attach, in virtgpu_gem_unmap_dma_buf() argument 63 struct drm_gem_object *obj = attach->dmabuf->priv; in virtgpu_gem_unmap_dma_buf() 67 virtio_gpu_vram_unmap_dma_buf(attach->dev, sgt, dir); in virtgpu_gem_unmap_dma_buf() 71 drm_gem_unmap_dma_buf(attach, sgt, dir); in virtgpu_gem_unmap_dma_buf() 77 .attach = virtio_dma_buf_attach, 166 struct drm_device *dev, struct dma_buf_attachment *attach, in virtgpu_gem_prime_import_sg_table() argument
|
/linux-6.3-rc2/drivers/xen/ |
A D | gntdev-dmabuf.c | 47 struct dma_buf_attachment *attach; member 252 attach->priv = NULL; in dmabuf_exp_ops_detach() 265 attach->dev); in dmabuf_exp_ops_map_dma_buf() 339 .attach = dmabuf_exp_ops_attach, 596 if (IS_ERR(attach)) { in dmabuf_imp_to_refs() 597 ret = ERR_CAST(attach); in dmabuf_imp_to_refs() 601 gntdev_dmabuf->u.imp.attach = attach; in dmabuf_imp_to_refs() 663 dma_buf_detach(dma_buf, attach); in dmabuf_imp_to_refs() 708 attach = gntdev_dmabuf->u.imp.attach; in dmabuf_imp_release() 713 dma_buf = attach->dmabuf; in dmabuf_imp_release() [all …]
|
/linux-6.3-rc2/drivers/gpu/drm/omapdrm/ |
A D | omap_gem_dmabuf.c | 107 struct dma_buf_attachment *attach; in omap_gem_prime_import() local 124 attach = dma_buf_attach(dma_buf, dev->dev); in omap_gem_prime_import() 125 if (IS_ERR(attach)) in omap_gem_prime_import() 126 return ERR_CAST(attach); in omap_gem_prime_import() 130 sgt = dma_buf_map_attachment_unlocked(attach, DMA_TO_DEVICE); in omap_gem_prime_import() 142 obj->import_attach = attach; in omap_gem_prime_import() 147 dma_buf_unmap_attachment_unlocked(attach, sgt, DMA_TO_DEVICE); in omap_gem_prime_import() 149 dma_buf_detach(dma_buf, attach); in omap_gem_prime_import()
|
/linux-6.3-rc2/drivers/gpu/drm/ |
A D | drm_prime.c | 600 struct dma_buf_attachment *attach) in drm_gem_map_detach() argument 795 .attach = drm_gem_map_attach, 919 struct dma_buf_attachment *attach; in drm_gem_prime_import_dev() local 940 if (IS_ERR(attach)) in drm_gem_prime_import_dev() 941 return ERR_CAST(attach); in drm_gem_prime_import_dev() 957 obj->import_attach = attach; in drm_gem_prime_import_dev() 965 dma_buf_detach(dma_buf, attach); in drm_gem_prime_import_dev() 1056 struct dma_buf_attachment *attach; in drm_prime_gem_destroy() local 1059 attach = obj->import_attach; in drm_prime_gem_destroy() 1062 dma_buf = attach->dmabuf; in drm_prime_gem_destroy() [all …]
|
A D | drm_gem_dma_helper.c | 463 struct dma_buf_attachment *attach, in drm_gem_dma_prime_import_sg_table() argument 469 if (drm_prime_get_contiguous_size(sgt) < attach->dmabuf->size) in drm_gem_dma_prime_import_sg_table() 473 dma_obj = __drm_gem_dma_create(dev, attach->dmabuf->size, true); in drm_gem_dma_prime_import_sg_table() 481 attach->dmabuf->size); in drm_gem_dma_prime_import_sg_table() 575 struct dma_buf_attachment *attach, in drm_gem_dma_prime_import_sg_table_vmap() argument 583 ret = dma_buf_vmap_unlocked(attach->dmabuf, &map); in drm_gem_dma_prime_import_sg_table_vmap() 589 obj = drm_gem_dma_prime_import_sg_table(dev, attach, sgt); in drm_gem_dma_prime_import_sg_table_vmap() 591 dma_buf_vunmap_unlocked(attach->dmabuf, &map); in drm_gem_dma_prime_import_sg_table_vmap()
|
/linux-6.3-rc2/drivers/gpu/drm/vmwgfx/ |
A D | vmwgfx_prime.c | 43 struct dma_buf_attachment *attach) in vmw_prime_map_attach() argument 49 struct dma_buf_attachment *attach) in vmw_prime_map_detach() argument 53 static struct sg_table *vmw_prime_map_dma_buf(struct dma_buf_attachment *attach, in vmw_prime_map_dma_buf() argument 59 static void vmw_prime_unmap_dma_buf(struct dma_buf_attachment *attach, in vmw_prime_unmap_dma_buf() argument 66 .attach = vmw_prime_map_attach,
|
/linux-6.3-rc2/drivers/gpu/drm/i915/gem/ |
A D | i915_gem_dmabuf.c | 31 struct drm_i915_gem_object *obj = dma_buf_to_obj(attach->dmabuf); in i915_gem_map_dma_buf() 56 ret = dma_map_sgtable(attach->dev, sgt, dir, DMA_ATTR_SKIP_CPU_SYNC); in i915_gem_map_dma_buf() 170 struct dma_buf_attachment *attach) in i915_gem_dmabuf_attach() argument 199 struct dma_buf_attachment *attach) in i915_gem_dmabuf_detach() argument 207 .attach = i915_gem_dmabuf_attach, 288 struct dma_buf_attachment *attach; in i915_gem_prime_import() local 310 attach = dma_buf_attach(dma_buf, dev->dev); in i915_gem_prime_import() 311 if (IS_ERR(attach)) in i915_gem_prime_import() 312 return ERR_CAST(attach); in i915_gem_prime_import() 325 obj->base.import_attach = attach; in i915_gem_prime_import() [all …]
|
/linux-6.3-rc2/drivers/gpu/drm/tegra/ |
A D | gem.c | 81 map->attach = dma_buf_attach(buf, dev); in tegra_bo_pin() 82 if (IS_ERR(map->attach)) { in tegra_bo_pin() 83 err = PTR_ERR(map->attach); in tegra_bo_pin() 89 dma_buf_detach(buf, map->attach); in tegra_bo_pin() 162 if (map->attach) { in tegra_bo_unpin() 165 dma_buf_detach(map->attach->dmabuf, map->attach); in tegra_bo_unpin() 449 struct dma_buf_attachment *attach; in tegra_bo_import() local 458 if (IS_ERR(attach)) { in tegra_bo_import() 459 err = PTR_ERR(attach); in tegra_bo_import() 477 bo->gem.import_attach = attach; in tegra_bo_import() [all …]
|
/linux-6.3-rc2/Documentation/bpf/libbpf/ |
A D | program_types.rst | 8 The table below lists the program types, their attach types where relevant and the ELF section 15 When ``extras`` are specified, they provide details of how to auto-attach the BPF program. The 190 .. [#fentry] The ``fentry`` attach format is ``fentry[.s]/<function>``. 191 .. [#kprobe] The ``kprobe`` attach format is ``kprobe/<function>[+<offset>]``. Valid 194 .. [#ksyscall] The ``ksyscall`` attach format is ``ksyscall/<syscall>``. 195 .. [#uprobe] The ``uprobe`` attach format is ``uprobe[.s]/<path>:<function>[+<offset>]``. 196 .. [#usdt] The ``usdt`` attach format is ``usdt/<path>:<provider>:<name>``. 197 .. [#kpmulti] The ``kprobe.multi`` attach format is ``kprobe.multi/<pattern>`` where ``pattern`` 201 .. [#rawtp] The ``raw_tp`` attach format is ``raw_tracepoint[.w]/<tracepoint>``. 202 .. [#tp] The ``tracepoint`` attach format is ``tracepoint/<category>/<name>``. [all …]
|
/linux-6.3-rc2/tools/bpf/bpftool/Documentation/ |
A D | bpftool-cgroup.rst | 22 { **show** | **list** | **tree** | **attach** | **detach** | **help** } 29 | **bpftool** **cgroup attach** *CGROUP* *ATTACH_TYPE* *PROG* [*ATTACH_FLAGS*] 52 Output will start with program ID followed by attach type, 53 attach flags and program name. 66 program ID, attach type, attach flags and program name. 72 **bpftool cgroup attach** *CGROUP* *ATTACH_TYPE* *PROG* [*ATTACH_FLAGS*] 73 Attach program *PROG* to the cgroup *CGROUP* with attach type 83 no attach flags or the **override** flag. Attaching another 84 program will release old program and attach the new one. 123 Detach *PROG* from the cgroup *CGROUP* and attach type [all …]
|
A D | bpftool-net.rst | 22 { **show** | **list** | **attach** | **detach** | **help** } 28 | **bpftool** **net attach** *ATTACH_TYPE* *PROG* **dev** *NAME* [ **overwrite** ] 59 **bpftool** **net attach** *ATTACH_TYPE* *PROG* **dev** *NAME* [ **overwrite** ] 74 *ATTACH_TYPE* previously used for attach must be specified. 153 | **# bpftool net attach xdpdrv id 16 dev enp6s0np0** 162 | **# bpftool net attach xdpdrv id 16 dev enp6s0np0** 163 | **# bpftool net attach xdpdrv id 20 dev enp6s0np0 overwrite** 172 | **# bpftool net attach xdpdrv id 16 dev enp6s0np0**
|
/linux-6.3-rc2/drivers/nvdimm/ |
A D | claim.c | 44 bool __nd_attach_ndns(struct device *dev, struct nd_namespace_common *attach, in __nd_attach_ndns() argument 47 struct nvdimm_bus *nvdimm_bus = walk_to_nvdimm_bus(&attach->dev); in __nd_attach_ndns() 49 if (attach->claim) in __nd_attach_ndns() 53 attach->claim = dev; in __nd_attach_ndns() 54 *_ndns = attach; in __nd_attach_ndns() 55 get_device(&attach->dev); in __nd_attach_ndns() 59 bool nd_attach_ndns(struct device *dev, struct nd_namespace_common *attach, in nd_attach_ndns() argument 64 nvdimm_bus_lock(&attach->dev); in nd_attach_ndns() 65 claimed = __nd_attach_ndns(dev, attach, _ndns); in nd_attach_ndns() 66 nvdimm_bus_unlock(&attach->dev); in nd_attach_ndns()
|
/linux-6.3-rc2/drivers/virtio/ |
A D | virtio_dma_buf.c | 28 exp_info->ops->attach != &virtio_dma_buf_attach || in virtio_dma_buf_export() 41 struct dma_buf_attachment *attach) in virtio_dma_buf_attach() argument 49 ret = ops->device_attach(dma_buf, attach); in virtio_dma_buf_attach() 63 return dma_buf->ops->attach == &virtio_dma_buf_attach; in is_virtio_dma_buf()
|
/linux-6.3-rc2/drivers/gpu/drm/armada/ |
A D | armada_gem.c | 389 struct drm_gem_object *obj = attach->dmabuf->priv; in armada_gem_prime_map_dma_buf() 419 if (dma_map_sgtable(attach->dev, sgt, dir, 0)) in armada_gem_prime_map_dma_buf() 428 if (dma_map_sgtable(attach->dev, sgt, dir, 0)) in armada_gem_prime_map_dma_buf() 455 struct drm_gem_object *obj = attach->dmabuf->priv; in armada_gem_prime_unmap_dma_buf() 460 dma_unmap_sgtable(attach->dev, sgt, dir, 0); in armada_gem_prime_unmap_dma_buf() 502 struct dma_buf_attachment *attach; in armada_gem_prime_import() local 517 attach = dma_buf_attach(buf, dev->dev); in armada_gem_prime_import() 518 if (IS_ERR(attach)) in armada_gem_prime_import() 519 return ERR_CAST(attach); in armada_gem_prime_import() 523 dma_buf_detach(buf, attach); in armada_gem_prime_import() [all …]
|
/linux-6.3-rc2/Documentation/bpf/ |
A D | map_cgroup_storage.rst | 10 attach to cgroups; the programs are made available by the same Kconfig. The 34 ``attach_type`` is the program's attach type. 37 When this key type is used, then all attach types of the particular cgroup and 39 ``struct bpf_cgroup_storage_key``, then programs of different attach types 133 multiple attach types, and each attach creates a fresh zeroed storage. The 145 does not already contain an entry for the cgroup and attach type pair, or else 146 the old storage is reused for the new attachment. If the map is attach type 147 shared, then attach type is simply ignored during comparison. Storage is freed 158 In all versions, userspace may use the attach parameters of cgroup and 161 attach type shared storages, only the first value in the struct, cgroup inode [all …]
|
/linux-6.3-rc2/include/drm/ |
A D | drm_prime.h | 78 struct dma_buf_attachment *attach); 80 struct dma_buf_attachment *attach); 81 struct sg_table *drm_gem_map_dma_buf(struct dma_buf_attachment *attach, 83 void drm_gem_unmap_dma_buf(struct dma_buf_attachment *attach,
|
/linux-6.3-rc2/samples/bpf/ |
A D | tcp_bpf.readme | 2 programs. These programs attach to a cgroupv2. The following commands create 3 a cgroupv2 and attach a bash shell to the group. 12 (attach) one of the tcp_*_kern.o programs: 15 bpftool cgroup attach /tmp/cgroupv2/foo sock_ops pinned /sys/fs/bpf/tcp_prog
|