/linux-master/drivers/dma-buf/ |
H A D | dma-buf-sysfs-stats.h | 16 int dma_buf_stats_setup(struct dma_buf *dmabuf, struct file *file); 18 void dma_buf_stats_teardown(struct dma_buf *dmabuf); 28 static inline int dma_buf_stats_setup(struct dma_buf *dmabuf, struct file *file) argument 33 static inline void dma_buf_stats_teardown(struct dma_buf *dmabuf) {} argument
|
H A D | dma-buf.c | 47 struct dma_buf *dmabuf; local 51 dmabuf = dentry->d_fsdata; 52 spin_lock(&dmabuf->name_lock); 53 if (dmabuf->name) 54 ret = strscpy(name, dmabuf->name, sizeof(name)); 55 spin_unlock(&dmabuf->name_lock); 63 struct dma_buf *dmabuf; local 65 dmabuf = dentry->d_fsdata; 66 if (unlikely(!dmabuf)) 69 BUG_ON(dmabuf 92 struct dma_buf *dmabuf; local 133 struct dma_buf *dmabuf; local 154 struct dma_buf *dmabuf; local 206 struct dma_buf *dmabuf = container_of(dcb->poll, struct dma_buf, poll); local 239 struct dma_buf *dmabuf; local 320 dma_buf_set_name(struct dma_buf *dmabuf, const char __user *buf) argument 336 dma_buf_export_sync_file(struct dma_buf *dmabuf, void __user *user_data) argument 392 dma_buf_import_sync_file(struct dma_buf *dmabuf, const void __user *user_data) argument 443 struct dma_buf *dmabuf; local 497 struct dma_buf *dmabuf = file->private_data; local 610 struct dma_buf *dmabuf; local 700 dma_buf_fd(struct dma_buf *dmabuf, int flags) argument 753 dma_buf_put(struct dma_buf *dmabuf) argument 889 dma_buf_dynamic_attach(struct dma_buf *dmabuf, struct device *dev, const struct dma_buf_attach_ops *importer_ops, void *importer_priv) argument 975 dma_buf_attach(struct dma_buf *dmabuf, struct device *dev) argument 1001 dma_buf_detach(struct dma_buf *dmabuf, struct dma_buf_attachment *attach) argument 1042 struct dma_buf *dmabuf = attach->dmabuf; local 1066 struct dma_buf *dmabuf = attach->dmabuf; local 1258 dma_buf_move_notify(struct dma_buf *dmabuf) argument 1355 __dma_buf_begin_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction) argument 1391 dma_buf_begin_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction) argument 1427 dma_buf_end_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction) argument 1458 dma_buf_mmap(struct dma_buf *dmabuf, struct vm_area_struct *vma, unsigned long pgoff) argument 1501 dma_buf_vmap(struct dma_buf *dmabuf, struct iosys_map *map) argument 1548 dma_buf_vmap_unlocked(struct dma_buf *dmabuf, struct iosys_map *map) argument 1570 dma_buf_vunmap(struct dma_buf *dmabuf, struct iosys_map *map) argument 1594 dma_buf_vunmap_unlocked(struct dma_buf *dmabuf, struct iosys_map *map) argument [all...] |
H A D | dma-buf-sysfs-stats.c | 36 * The interface at ``/sys/kernel/dmabuf/buffers`` exposes information about 41 * * ``/sys/kernel/dmabuf/buffers/<inode_number>/exporter_name`` 42 * * ``/sys/kernel/dmabuf/buffers/<inode_number>/size`` 50 * Documentation/ABI/testing/sysfs-kernel-dmabuf-buffers. 55 ssize_t (*show)(struct dma_buf *dmabuf, 66 struct dma_buf *dmabuf; local 70 dmabuf = sysfs_entry->dmabuf; 72 if (!dmabuf || !attribute->show) 75 return attribute->show(dmabuf, attribut 82 exporter_name_show(struct dma_buf *dmabuf, struct dma_buf_stats_attribute *attr, char *buf) argument 89 size_show(struct dma_buf *dmabuf, struct dma_buf_stats_attribute *attr, char *buf) argument 121 dma_buf_stats_teardown(struct dma_buf *dmabuf) argument 171 dma_buf_stats_setup(struct dma_buf *dmabuf, struct file *file) argument [all...] |
/linux-master/drivers/gpu/drm/i915/gem/selftests/ |
H A D | i915_gem_dmabuf.c | 21 struct dma_buf *dmabuf; local 27 dmabuf = i915_gem_prime_export(&obj->base, 0); 29 if (IS_ERR(dmabuf)) { 31 (int)PTR_ERR(dmabuf)); 32 return PTR_ERR(dmabuf); 35 dma_buf_put(dmabuf); 44 struct dma_buf *dmabuf; local 51 dmabuf = i915_gem_prime_export(&obj->base, 0); 52 if (IS_ERR(dmabuf)) { 54 (int)PTR_ERR(dmabuf)); 98 struct dma_buf *dmabuf; local 222 struct dma_buf *dmabuf; local 345 struct dma_buf *dmabuf; local 429 struct dma_buf *dmabuf; local 480 struct dma_buf *dmabuf; local [all...] |
H A D | mock_dmabuf.c | 12 struct mock_dmabuf *mock = to_mock(attachment->dmabuf); 102 struct dma_buf *dmabuf; local 122 dmabuf = dma_buf_export(&exp_info); 123 if (IS_ERR(dmabuf)) 126 return dmabuf;
|
/linux-master/include/linux/ |
H A D | dma-buf.h | 93 * This is called with the &dmabuf.resv object locked and is mutual 117 * This is called with the dmabuf->resv object locked and is mutual 150 * This is always called with the dmabuf->resv object locked when 286 int (*vmap)(struct dma_buf *dmabuf, struct iosys_map *map); 287 void (*vunmap)(struct dma_buf *dmabuf, struct iosys_map *map); 449 struct dma_buf *dmabuf; member in struct:dma_buf::dma_buf_sysfs_entry 491 * @dmabuf: buffer for this attachment. 493 * @node: list of dma_buf_attachment, protected by dma_resv lock of the dmabuf. 512 struct dma_buf *dmabuf; member in struct:dma_buf_attachment 559 * @dmabuf 566 get_dma_buf(struct dma_buf *dmabuf) argument 579 dma_buf_is_dynamic(struct dma_buf *dmabuf) argument [all...] |
/linux-master/drivers/media/platform/nvidia/tegra-vde/ |
H A D | Makefile | 2 tegra-vde-y := vde.o iommu.o dmabuf-cache.o h264.o v4l2.o
|
H A D | dmabuf-cache.c | 34 struct dma_buf *dmabuf = entry->a->dmabuf; local 42 dma_buf_detach(dmabuf, entry->a); 43 dma_buf_put(dmabuf); 64 struct dma_buf *dmabuf, 79 if (entry->a->dmabuf != dmabuf) 88 dma_buf_put(dmabuf); 98 attachment = dma_buf_attach(dmabuf, dev); 100 dev_err(dev, "Failed to attach dmabuf\ 63 tegra_vde_dmabuf_cache_map(struct tegra_vde *vde, struct dma_buf *dmabuf, enum dma_data_direction dma_dir, struct dma_buf_attachment **ap, dma_addr_t *addrp) argument [all...] |
/linux-master/tools/testing/selftests/dmabuf-heaps/ |
H A D | Makefile | 4 TEST_GEN_PROGS = dmabuf-heap
|
/linux-master/drivers/hid/ |
H A D | hid-elan.c | 80 unsigned char *dmabuf, unsigned char param) 84 dmabuf[0] = ELAN_FEATURE_REPORT; 85 dmabuf[1] = 0x05; 86 dmabuf[2] = 0x03; 87 dmabuf[3] = param; 88 dmabuf[4] = 0x01; 90 ret = hid_hw_raw_request(hdev, ELAN_FEATURE_REPORT, dmabuf, 98 ret = hid_hw_raw_request(hdev, ELAN_FEATURE_REPORT, dmabuf, 121 unsigned char *dmabuf; local 124 dmabuf 79 elan_get_device_param(struct hid_device *hdev, unsigned char *dmabuf, unsigned char param) argument 393 unsigned char *dmabuf = kmemdup(buf, sizeof(buf), GFP_KERNEL); local 420 unsigned char *dmabuf = kzalloc(ELAN_LED_REPORT_SIZE, GFP_KERNEL); local [all...] |
/linux-master/drivers/infiniband/core/ |
H A D | umem_dmabuf.c | 24 dma_resv_assert_held(umem_dmabuf->attach->dmabuf->resv); 72 ret = dma_resv_wait_timeout(umem_dmabuf->attach->dmabuf->resv, 85 dma_resv_assert_held(umem_dmabuf->attach->dmabuf->resv); 118 struct dma_buf *dmabuf; local 130 dmabuf = dma_buf_get(fd); 131 if (IS_ERR(dmabuf)) 132 return ERR_CAST(dmabuf); 134 if (dmabuf->size < end) 154 dmabuf, 168 dma_buf_put(dmabuf); 224 struct dma_buf *dmabuf = umem_dmabuf->attach->dmabuf; local [all...] |
/linux-master/samples/vfio-mdev/ |
H A D | mbochs.c | 819 struct mbochs_dmabuf *dmabuf = vma->vm_private_data; local 821 if (WARN_ON(vmf->pgoff >= dmabuf->pagecount)) 824 vmf->page = dmabuf->pages[vmf->pgoff]; 835 struct mbochs_dmabuf *dmabuf = buf->priv; local 836 struct device *dev = mdev_dev(dmabuf->mdev_state->mdev); 838 dev_dbg(dev, "%s: %d\n", __func__, dmabuf->id); 844 vma->vm_private_data = dmabuf; 848 static void mbochs_print_dmabuf(struct mbochs_dmabuf *dmabuf, argument 851 struct device *dev = mdev_dev(dmabuf->mdev_state->mdev); 852 u32 fourcc = dmabuf 867 struct mbochs_dmabuf *dmabuf = at->dmabuf->priv; local 896 struct mbochs_dmabuf *dmabuf = at->dmabuf->priv; local 908 struct mbochs_dmabuf *dmabuf = buf->priv; local 935 struct mbochs_dmabuf *dmabuf; local 979 struct mbochs_dmabuf *dmabuf; local 993 struct mbochs_dmabuf *dmabuf; local 1004 mbochs_dmabuf_export(struct mbochs_dmabuf *dmabuf) argument 1103 struct mbochs_dmabuf *dmabuf; local 1166 struct mbochs_dmabuf *dmabuf; local 1311 struct mbochs_dmabuf *dmabuf, *tmp; local [all...] |
/linux-master/drivers/dma-buf/heaps/ |
H A D | system_heap.c | 82 static int system_heap_attach(struct dma_buf *dmabuf, argument 85 struct system_heap_buffer *buffer = dmabuf->priv; 113 static void system_heap_detach(struct dma_buf *dmabuf, argument 116 struct system_heap_buffer *buffer = dmabuf->priv; 153 static int system_heap_dma_buf_begin_cpu_access(struct dma_buf *dmabuf, argument 156 struct system_heap_buffer *buffer = dmabuf->priv; 174 static int system_heap_dma_buf_end_cpu_access(struct dma_buf *dmabuf, argument 177 struct system_heap_buffer *buffer = dmabuf->priv; 195 static int system_heap_mmap(struct dma_buf *dmabuf, struct vm_area_struct *vma) argument 197 struct system_heap_buffer *buffer = dmabuf 243 system_heap_vmap(struct dma_buf *dmabuf, struct iosys_map *map) argument 271 system_heap_vunmap(struct dma_buf *dmabuf, struct iosys_map *map) argument 284 system_heap_dma_buf_release(struct dma_buf *dmabuf) argument 343 struct dma_buf *dmabuf; local [all...] |
H A D | cma_heap.c | 50 static int cma_heap_attach(struct dma_buf *dmabuf, argument 53 struct cma_heap_buffer *buffer = dmabuf->priv; 83 static void cma_heap_detach(struct dma_buf *dmabuf, argument 86 struct cma_heap_buffer *buffer = dmabuf->priv; 121 static int cma_heap_dma_buf_begin_cpu_access(struct dma_buf *dmabuf, argument 124 struct cma_heap_buffer *buffer = dmabuf->priv; 142 static int cma_heap_dma_buf_end_cpu_access(struct dma_buf *dmabuf, argument 145 struct cma_heap_buffer *buffer = dmabuf->priv; 178 static int cma_heap_mmap(struct dma_buf *dmabuf, struct vm_area_struct *vma) argument 180 struct cma_heap_buffer *buffer = dmabuf 204 cma_heap_vmap(struct dma_buf *dmabuf, struct iosys_map *map) argument 231 cma_heap_vunmap(struct dma_buf *dmabuf, struct iosys_map *map) argument 244 cma_heap_dma_buf_release(struct dma_buf *dmabuf) argument 287 struct dma_buf *dmabuf; local [all...] |
/linux-master/drivers/gpu/drm/ |
H A D | drm_prime.c | 232 * @dev: parent device for the exported dmabuf 240 * Returns the new dmabuf. 382 struct dma_buf *dmabuf; local 386 dmabuf = ERR_PTR(-ENOENT); 387 return dmabuf; 391 dmabuf = obj->funcs->export(obj, flags); 393 dmabuf = drm_gem_prime_export(obj, flags); 394 if (IS_ERR(dmabuf)) { 398 return dmabuf; 406 obj->dma_buf = dmabuf; 432 struct dma_buf *dmabuf; local [all...] |
/linux-master/drivers/gpu/drm/xe/tests/ |
H A D | xe_dma_buf.c | 29 struct xe_bo *imported, struct dma_buf *dmabuf) 66 swap(exported->ttm.base.dma_buf, dmabuf); 68 swap(exported->ttm.base.dma_buf, dmabuf); 112 struct dma_buf *dmabuf; local 135 dmabuf = xe_gem_prime_export(&bo->ttm.base, 0); 136 if (IS_ERR(dmabuf)) { 138 PTR_ERR(dmabuf)); 142 import = xe_gem_prime_import(&xe->drm, dmabuf); 172 check_residency(test, bo, import_bo, dmabuf); 188 dma_buf_put(dmabuf); 28 check_residency(struct kunit *test, struct xe_bo *exported, struct xe_bo *imported, struct dma_buf *dmabuf) argument [all...] |
/linux-master/drivers/gpu/drm/xe/ |
H A D | xe_dma_buf.c | 24 static int xe_dma_buf_attach(struct dma_buf *dmabuf, argument 27 struct drm_gem_object *obj = attach->dmabuf->priv; 40 static void xe_dma_buf_detach(struct dma_buf *dmabuf, argument 43 struct drm_gem_object *obj = attach->dmabuf->priv; 50 struct drm_gem_object *obj = attach->dmabuf->priv; 82 struct drm_gem_object *obj = attach->dmabuf->priv; 91 struct dma_buf *dma_buf = attach->dmabuf; 147 struct dma_buf *dma_buf = attach->dmabuf; 275 * Importing dmabuf exported from out own gem increases 276 * refcount on gem itself instead of f_count of dmabuf [all...] |
/linux-master/drivers/comedi/drivers/ |
H A D | addi_apci_3120.c | 150 struct apci3120_dmabuf dmabuf[2]; member in struct:apci3120_private 172 struct apci3120_dmabuf *dmabuf) 189 apci3120_addon_write(dev, dmabuf->hw, AMCC_OP_REG_AMWAR); 192 apci3120_addon_write(dev, dmabuf->use_size, AMCC_OP_REG_AMWTC); 208 struct apci3120_dmabuf *dmabuf0 = &devpriv->dmabuf[0]; 209 struct apci3120_dmabuf *dmabuf1 = &devpriv->dmabuf[1]; 430 struct apci3120_dmabuf *dmabuf; local 434 dmabuf = &devpriv->dmabuf[devpriv->cur_dmabuf]; 436 nbytes = dmabuf 171 apci3120_init_dma(struct comedi_device *dev, struct apci3120_dmabuf *dmabuf) argument 909 struct apci3120_dmabuf *dmabuf; local 937 struct apci3120_dmabuf *dmabuf; local [all...] |
/linux-master/drivers/gpu/drm/etnaviv/ |
H A D | etnaviv_gem_prime.c | 68 dma_buf_vunmap_unlocked(etnaviv_obj->base.import_attach->dmabuf, &map); 70 /* Don't drop the pages for imported dmabuf, as they are not 85 ret = dma_buf_vmap(etnaviv_obj->base.import_attach->dmabuf, &map); 116 size_t size = PAGE_ALIGN(attach->dmabuf->size);
|
/linux-master/drivers/gpu/drm/i915/selftests/ |
H A D | i915_mock_selftests.h | 30 selftest(dmabuf, i915_gem_dmabuf_mock_selftests)
|
/linux-master/drivers/gpu/drm/msm/ |
H A D | msm_gem_prime.c | 45 return msm_gem_import(dev, attach->dmabuf, sg);
|
/linux-master/drivers/gpu/drm/i915/gvt/ |
H A D | Makefile | 9 gvt/dmabuf.o \
|
/linux-master/drivers/gpu/drm/radeon/ |
H A D | radeon_prime.c | 49 struct dma_resv *resv = attach->dmabuf->resv; 55 ret = radeon_bo_create(rdev, attach->dmabuf->size, PAGE_SIZE, false,
|
/linux-master/drivers/gpu/drm/nouveau/ |
H A D | nouveau_prime.c | 46 struct dma_resv *robj = attach->dmabuf->resv; 47 u64 size = attach->dmabuf->size;
|
/linux-master/drivers/gpu/drm/amd/amdgpu/ |
H A D | amdgpu_dma_buf.c | 50 * @dmabuf: DMA-buf where we attach to 55 static int amdgpu_dma_buf_attach(struct dma_buf *dmabuf, argument 58 struct drm_gem_object *obj = dmabuf->priv; 82 * @dmabuf: DMA-buf where we remove the attachment from 87 static void amdgpu_dma_buf_detach(struct dma_buf *dmabuf, argument 90 struct drm_gem_object *obj = dmabuf->priv; 108 struct drm_gem_object *obj = attach->dmabuf->priv; 124 struct drm_gem_object *obj = attach->dmabuf->priv; 146 struct dma_buf *dma_buf = attach->dmabuf; 455 * Importing dmabuf exporte [all...] |