/kernel/linux/linux-5.10/drivers/dma-buf/ |
H A D | dma-buf.c | 46 struct dma_buf *dmabuf; in dmabuffs_dname() local 50 dmabuf = dentry->d_fsdata; in dmabuffs_dname() 51 spin_lock(&dmabuf->name_lock); in dmabuffs_dname() 52 if (dmabuf->name) in dmabuffs_dname() 53 ret = strlcpy(name, dmabuf->name, DMA_BUF_NAME_LEN); in dmabuffs_dname() 54 spin_unlock(&dmabuf->name_lock); in dmabuffs_dname() 62 struct dma_buf *dmabuf; in dma_buf_release() local 64 dmabuf = dentry->d_fsdata; in dma_buf_release() 65 if (unlikely(!dmabuf)) in dma_buf_release() 68 BUG_ON(dmabuf in dma_buf_release() 94 struct dma_buf *dmabuf; dma_buf_file_release() local 134 struct dma_buf *dmabuf; dma_buf_mmap_internal() local 155 struct dma_buf *dmabuf; dma_buf_llseek() local 214 struct dma_buf *dmabuf; dma_buf_poll() local 346 dma_buf_set_name(struct dma_buf *dmabuf, const char __user *buf) dma_buf_set_name() argument 373 struct dma_buf *dmabuf; dma_buf_ioctl() local 420 struct dma_buf *dmabuf = file->private_data; dma_buf_show_fdinfo() local 450 dma_buf_getfile(struct dma_buf *dmabuf, int flags) dma_buf_getfile() argument 526 struct dma_buf *dmabuf; dma_buf_export() local 624 dma_buf_fd(struct dma_buf *dmabuf, int flags) dma_buf_fd() argument 677 dma_buf_put(struct dma_buf *dmabuf) dma_buf_put() argument 707 dma_buf_dynamic_attach(struct dma_buf *dmabuf, struct device *dev, const struct dma_buf_attach_ops *importer_ops, void *importer_priv) dma_buf_dynamic_attach() argument 795 dma_buf_attach(struct dma_buf *dmabuf, struct device *dev) dma_buf_attach() argument 810 dma_buf_detach(struct dma_buf *dmabuf, struct dma_buf_attachment *attach) dma_buf_detach() argument 847 struct dma_buf *dmabuf = attach->dmabuf; dma_buf_pin() local 866 struct dma_buf *dmabuf = attach->dmabuf; dma_buf_unpin() local 986 dma_buf_move_notify(struct dma_buf *dmabuf) dma_buf_move_notify() argument 1082 __dma_buf_begin_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction) __dma_buf_begin_cpu_access() argument 1113 dma_buf_begin_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction) dma_buf_begin_cpu_access() argument 1147 dma_buf_end_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction) dma_buf_end_cpu_access() argument 1176 dma_buf_mmap(struct dma_buf *dmabuf, struct vm_area_struct *vma, unsigned long pgoff) dma_buf_mmap() argument 1230 dma_buf_vmap(struct dma_buf *dmabuf) dma_buf_vmap() argument 1270 dma_buf_vunmap(struct dma_buf *dmabuf, void *vaddr) dma_buf_vunmap() argument [all...] |
H A D | dma-buf-sysfs-stats.c | 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; in dma_buf_stats_attribute_show() local 70 dmabuf = sysfs_entry->dmabuf; in dma_buf_stats_attribute_show() 72 if (!dmabuf || !attribute->show) in dma_buf_stats_attribute_show() 75 return attribute->show(dmabuf, attribute, buf); in dma_buf_stats_attribute_show() 82 static ssize_t exporter_name_show(struct dma_buf *dmabuf, in exporter_name_show() argument 89 size_show(struct dma_buf *dmabuf, struct dma_buf_stats_attribute *attr, char *buf) size_show() argument 121 dma_buf_stats_teardown(struct dma_buf *dmabuf) dma_buf_stats_teardown() argument 171 dma_buf_stats_setup(struct dma_buf *dmabuf) dma_buf_stats_setup() argument [all...] |
H A D | dma-buf-sysfs-stats.h | 16 int dma_buf_stats_setup(struct dma_buf *dmabuf); 18 void dma_buf_stats_teardown(struct dma_buf *dmabuf); 28 static inline int dma_buf_stats_setup(struct dma_buf *dmabuf) in dma_buf_stats_setup() argument 33 static inline void dma_buf_stats_teardown(struct dma_buf *dmabuf) {} in dma_buf_stats_teardown() argument
|
/kernel/linux/linux-6.6/drivers/dma-buf/ |
H A D | dma-buf.c | 48 struct dma_buf *dmabuf; in dmabuffs_dname() local 52 dmabuf = dentry->d_fsdata; in dmabuffs_dname() 53 spin_lock(&dmabuf->name_lock); in dmabuffs_dname() 54 if (dmabuf->name) in dmabuffs_dname() 55 ret = strlcpy(name, dmabuf->name, DMA_BUF_NAME_LEN); in dmabuffs_dname() 56 spin_unlock(&dmabuf->name_lock); in dmabuffs_dname() 64 struct dma_buf *dmabuf; in dma_buf_release() local 66 dmabuf = dentry->d_fsdata; in dma_buf_release() 67 if (unlikely(!dmabuf)) in dma_buf_release() 70 BUG_ON(dmabuf in dma_buf_release() 93 struct dma_buf *dmabuf; dma_buf_file_release() local 134 struct dma_buf *dmabuf; dma_buf_mmap_internal() local 155 struct dma_buf *dmabuf; dma_buf_llseek() local 207 struct dma_buf *dmabuf = container_of(dcb->poll, struct dma_buf, poll); dma_buf_poll_cb() local 240 struct dma_buf *dmabuf; dma_buf_poll() local 321 dma_buf_set_name(struct dma_buf *dmabuf, const char __user *buf) dma_buf_set_name() argument 337 dma_buf_export_sync_file(struct dma_buf *dmabuf, void __user *user_data) dma_buf_export_sync_file() argument 393 dma_buf_import_sync_file(struct dma_buf *dmabuf, const void __user *user_data) dma_buf_import_sync_file() argument 444 struct dma_buf *dmabuf; dma_buf_ioctl() local 498 struct dma_buf *dmabuf = file->private_data; dma_buf_show_fdinfo() local 611 struct dma_buf *dmabuf; dma_buf_export() local 701 dma_buf_fd(struct dma_buf *dmabuf, int flags) dma_buf_fd() argument 754 dma_buf_put(struct dma_buf *dmabuf) dma_buf_put() argument 890 dma_buf_dynamic_attach(struct dma_buf *dmabuf, struct device *dev, const struct dma_buf_attach_ops *importer_ops, void *importer_priv) dma_buf_dynamic_attach() argument 976 dma_buf_attach(struct dma_buf *dmabuf, struct device *dev) dma_buf_attach() argument 1002 dma_buf_detach(struct dma_buf *dmabuf, struct dma_buf_attachment *attach) dma_buf_detach() argument 1043 struct dma_buf *dmabuf = attach->dmabuf; dma_buf_pin() local 1067 struct dma_buf *dmabuf = attach->dmabuf; dma_buf_unpin() local 1259 dma_buf_move_notify(struct dma_buf *dmabuf) dma_buf_move_notify() argument 1356 __dma_buf_begin_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction) __dma_buf_begin_cpu_access() argument 1392 dma_buf_begin_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction) dma_buf_begin_cpu_access() argument 1428 dma_buf_end_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction) dma_buf_end_cpu_access() argument 1459 dma_buf_mmap(struct dma_buf *dmabuf, struct vm_area_struct *vma, unsigned long pgoff) dma_buf_mmap() argument 1502 dma_buf_vmap(struct dma_buf *dmabuf, struct iosys_map *map) dma_buf_vmap() argument 1549 dma_buf_vmap_unlocked(struct dma_buf *dmabuf, struct iosys_map *map) dma_buf_vmap_unlocked() argument 1571 dma_buf_vunmap(struct dma_buf *dmabuf, struct iosys_map *map) dma_buf_vunmap() argument 1595 dma_buf_vunmap_unlocked(struct dma_buf *dmabuf, struct iosys_map *map) dma_buf_vunmap_unlocked() 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; in dma_buf_stats_attribute_show() local 70 dmabuf = sysfs_entry->dmabuf; in dma_buf_stats_attribute_show() 72 if (!dmabuf || !attribute->show) in dma_buf_stats_attribute_show() 75 return attribute->show(dmabuf, attribut in dma_buf_stats_attribute_show() 82 exporter_name_show(struct dma_buf *dmabuf, struct dma_buf_stats_attribute *attr, char *buf) exporter_name_show() argument 89 size_show(struct dma_buf *dmabuf, struct dma_buf_stats_attribute *attr, char *buf) size_show() argument 121 dma_buf_stats_teardown(struct dma_buf *dmabuf) dma_buf_stats_teardown() argument 171 dma_buf_stats_setup(struct dma_buf *dmabuf, struct file *file) dma_buf_stats_setup() argument [all...] |
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) in dma_buf_stats_setup() argument 33 static inline void dma_buf_stats_teardown(struct dma_buf *dmabuf) {} in dma_buf_stats_teardown() argument
|
/kernel/linux/linux-5.10/drivers/gpu/drm/i915/gem/selftests/ |
H A D | i915_gem_dmabuf.c | 17 struct dma_buf *dmabuf; in igt_dmabuf_export() local 23 dmabuf = i915_gem_prime_export(&obj->base, 0); in igt_dmabuf_export() 25 if (IS_ERR(dmabuf)) { in igt_dmabuf_export() 27 (int)PTR_ERR(dmabuf)); in igt_dmabuf_export() 28 return PTR_ERR(dmabuf); in igt_dmabuf_export() 31 dma_buf_put(dmabuf); in igt_dmabuf_export() 40 struct dma_buf *dmabuf; in igt_dmabuf_import_self() local 47 dmabuf = i915_gem_prime_export(&obj->base, 0); in igt_dmabuf_import_self() 48 if (IS_ERR(dmabuf)) { in igt_dmabuf_import_self() 50 (int)PTR_ERR(dmabuf)); in igt_dmabuf_import_self() 83 struct dma_buf *dmabuf; igt_dmabuf_import() local 165 struct dma_buf *dmabuf; igt_dmabuf_import_ownership() local 214 struct dma_buf *dmabuf; igt_dmabuf_export_vmap() local [all...] |
/kernel/linux/linux-6.6/drivers/gpu/drm/i915/gem/selftests/ |
H A D | i915_gem_dmabuf.c | 21 struct dma_buf *dmabuf; in igt_dmabuf_export() local 27 dmabuf = i915_gem_prime_export(&obj->base, 0); in igt_dmabuf_export() 29 if (IS_ERR(dmabuf)) { in igt_dmabuf_export() 31 (int)PTR_ERR(dmabuf)); in igt_dmabuf_export() 32 return PTR_ERR(dmabuf); in igt_dmabuf_export() 35 dma_buf_put(dmabuf); in igt_dmabuf_export() 44 struct dma_buf *dmabuf; in igt_dmabuf_import_self() local 51 dmabuf = i915_gem_prime_export(&obj->base, 0); in igt_dmabuf_import_self() 52 if (IS_ERR(dmabuf)) { in igt_dmabuf_import_self() 54 (int)PTR_ERR(dmabuf)); in igt_dmabuf_import_self() 98 struct dma_buf *dmabuf; igt_dmabuf_import_same_driver_lmem() local 222 struct dma_buf *dmabuf; igt_dmabuf_import_same_driver() local 345 struct dma_buf *dmabuf; igt_dmabuf_import() local 429 struct dma_buf *dmabuf; igt_dmabuf_import_ownership() local 480 struct dma_buf *dmabuf; igt_dmabuf_export_vmap() local [all...] |
/kernel/linux/linux-5.10/samples/vfio-mdev/ |
H A D | mbochs.c | 789 struct mbochs_dmabuf *dmabuf = vma->vm_private_data; in mbochs_dmabuf_vm_fault() local 791 if (WARN_ON(vmf->pgoff >= dmabuf->pagecount)) in mbochs_dmabuf_vm_fault() 794 vmf->page = dmabuf->pages[vmf->pgoff]; in mbochs_dmabuf_vm_fault() 805 struct mbochs_dmabuf *dmabuf = buf->priv; in mbochs_mmap_dmabuf() local 806 struct device *dev = mdev_dev(dmabuf->mdev_state->mdev); in mbochs_mmap_dmabuf() 808 dev_dbg(dev, "%s: %d\n", __func__, dmabuf->id); in mbochs_mmap_dmabuf() 814 vma->vm_private_data = dmabuf; in mbochs_mmap_dmabuf() 818 static void mbochs_print_dmabuf(struct mbochs_dmabuf *dmabuf, in mbochs_print_dmabuf() argument 821 struct device *dev = mdev_dev(dmabuf->mdev_state->mdev); in mbochs_print_dmabuf() 822 u32 fourcc = dmabuf in mbochs_print_dmabuf() 837 struct mbochs_dmabuf *dmabuf = at->dmabuf->priv; mbochs_map_dmabuf() local 866 struct mbochs_dmabuf *dmabuf = at->dmabuf->priv; mbochs_unmap_dmabuf() local 878 struct mbochs_dmabuf *dmabuf = buf->priv; mbochs_release_dmabuf() local 905 struct mbochs_dmabuf *dmabuf; mbochs_dmabuf_alloc() local 949 struct mbochs_dmabuf *dmabuf; mbochs_dmabuf_find_by_mode() local 963 struct mbochs_dmabuf *dmabuf; mbochs_dmabuf_find_by_id() local 974 mbochs_dmabuf_export(struct mbochs_dmabuf *dmabuf) mbochs_dmabuf_export() argument 1082 struct mbochs_dmabuf *dmabuf; mbochs_query_gfx_plane() local 1147 struct mbochs_dmabuf *dmabuf; mbochs_get_gfx_dmabuf() local 1297 struct mbochs_dmabuf *dmabuf, *tmp; mbochs_close() local [all...] |
/kernel/linux/linux-6.6/samples/vfio-mdev/ |
H A D | mbochs.c | 817 struct mbochs_dmabuf *dmabuf = vma->vm_private_data; in mbochs_dmabuf_vm_fault() local 819 if (WARN_ON(vmf->pgoff >= dmabuf->pagecount)) in mbochs_dmabuf_vm_fault() 822 vmf->page = dmabuf->pages[vmf->pgoff]; in mbochs_dmabuf_vm_fault() 833 struct mbochs_dmabuf *dmabuf = buf->priv; in mbochs_mmap_dmabuf() local 834 struct device *dev = mdev_dev(dmabuf->mdev_state->mdev); in mbochs_mmap_dmabuf() 836 dev_dbg(dev, "%s: %d\n", __func__, dmabuf->id); in mbochs_mmap_dmabuf() 842 vma->vm_private_data = dmabuf; in mbochs_mmap_dmabuf() 846 static void mbochs_print_dmabuf(struct mbochs_dmabuf *dmabuf, in mbochs_print_dmabuf() argument 849 struct device *dev = mdev_dev(dmabuf->mdev_state->mdev); in mbochs_print_dmabuf() 850 u32 fourcc = dmabuf in mbochs_print_dmabuf() 865 struct mbochs_dmabuf *dmabuf = at->dmabuf->priv; mbochs_map_dmabuf() local 894 struct mbochs_dmabuf *dmabuf = at->dmabuf->priv; mbochs_unmap_dmabuf() local 906 struct mbochs_dmabuf *dmabuf = buf->priv; mbochs_release_dmabuf() local 933 struct mbochs_dmabuf *dmabuf; mbochs_dmabuf_alloc() local 977 struct mbochs_dmabuf *dmabuf; mbochs_dmabuf_find_by_mode() local 991 struct mbochs_dmabuf *dmabuf; mbochs_dmabuf_find_by_id() local 1002 mbochs_dmabuf_export(struct mbochs_dmabuf *dmabuf) mbochs_dmabuf_export() argument 1101 struct mbochs_dmabuf *dmabuf; mbochs_query_gfx_plane() local 1164 struct mbochs_dmabuf *dmabuf; mbochs_get_gfx_dmabuf() local 1309 struct mbochs_dmabuf *dmabuf, *tmp; mbochs_close_device() local [all...] |
/kernel/linux/linux-6.6/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); 446 struct dma_buf *dmabuf; member 488 * @dmabuf: buffer for this attachment. 490 * @node: list of dma_buf_attachment, protected by dma_resv lock of the dmabuf. 509 struct dma_buf *dmabuf; member 556 * @dmabuf 563 get_dma_buf(struct dma_buf *dmabuf) get_dma_buf() argument 576 dma_buf_is_dynamic(struct dma_buf *dmabuf) dma_buf_is_dynamic() argument [all...] |
/kernel/linux/linux-6.6/drivers/infiniband/core/ |
H A D | umem_dmabuf.c | 24 dma_resv_assert_held(umem_dmabuf->attach->dmabuf->resv); in ib_umem_dmabuf_map_pages() 72 ret = dma_resv_wait_timeout(umem_dmabuf->attach->dmabuf->resv, in ib_umem_dmabuf_map_pages() 85 dma_resv_assert_held(umem_dmabuf->attach->dmabuf->resv); in ib_umem_dmabuf_unmap_pages() 118 struct dma_buf *dmabuf; in ib_umem_dmabuf_get() local 130 dmabuf = dma_buf_get(fd); in ib_umem_dmabuf_get() 131 if (IS_ERR(dmabuf)) in ib_umem_dmabuf_get() 132 return ERR_CAST(dmabuf); in ib_umem_dmabuf_get() 134 if (dmabuf->size < end) in ib_umem_dmabuf_get() 154 dmabuf, in ib_umem_dmabuf_get() 168 dma_buf_put(dmabuf); in ib_umem_dmabuf_get() 224 struct dma_buf *dmabuf = umem_dmabuf->attach->dmabuf; ib_umem_dmabuf_release() local [all...] |
/kernel/linux/linux-5.10/drivers/hid/ |
H A D | hid-elan.c | 80 unsigned char *dmabuf, unsigned char param) in elan_get_device_param() 84 dmabuf[0] = ELAN_FEATURE_REPORT; in elan_get_device_param() 85 dmabuf[1] = 0x05; in elan_get_device_param() 86 dmabuf[2] = 0x03; in elan_get_device_param() 87 dmabuf[3] = param; in elan_get_device_param() 88 dmabuf[4] = 0x01; in elan_get_device_param() 90 ret = hid_hw_raw_request(hdev, ELAN_FEATURE_REPORT, dmabuf, in elan_get_device_param() 98 ret = hid_hw_raw_request(hdev, ELAN_FEATURE_REPORT, dmabuf, in elan_get_device_param() 121 unsigned char *dmabuf; in elan_get_device_params() local 124 dmabuf in elan_get_device_params() 79 elan_get_device_param(struct hid_device *hdev, unsigned char *dmabuf, unsigned char param) elan_get_device_param() argument 393 unsigned char *dmabuf = kmemdup(buf, sizeof(buf), GFP_KERNEL); elan_start_multitouch() local 429 unsigned char *dmabuf = kzalloc(ELAN_LED_REPORT_SIZE, GFP_KERNEL); elan_mute_led_set_brigtness() local [all...] |
/kernel/linux/linux-6.6/drivers/hid/ |
H A D | hid-elan.c | 80 unsigned char *dmabuf, unsigned char param) in elan_get_device_param() 84 dmabuf[0] = ELAN_FEATURE_REPORT; in elan_get_device_param() 85 dmabuf[1] = 0x05; in elan_get_device_param() 86 dmabuf[2] = 0x03; in elan_get_device_param() 87 dmabuf[3] = param; in elan_get_device_param() 88 dmabuf[4] = 0x01; in elan_get_device_param() 90 ret = hid_hw_raw_request(hdev, ELAN_FEATURE_REPORT, dmabuf, in elan_get_device_param() 98 ret = hid_hw_raw_request(hdev, ELAN_FEATURE_REPORT, dmabuf, in elan_get_device_param() 121 unsigned char *dmabuf; in elan_get_device_params() local 124 dmabuf in elan_get_device_params() 79 elan_get_device_param(struct hid_device *hdev, unsigned char *dmabuf, unsigned char param) elan_get_device_param() argument 393 unsigned char *dmabuf = kmemdup(buf, sizeof(buf), GFP_KERNEL); elan_start_multitouch() local 420 unsigned char *dmabuf = kzalloc(ELAN_LED_REPORT_SIZE, GFP_KERNEL); elan_mute_led_set_brigtness() local [all...] |
/kernel/linux/linux-5.10/include/linux/ |
H A D | dma-buf.h | 90 * This is called with the dmabuf->resv object locked and is mutual 108 * This is called with the dmabuf->resv object locked and is mutual 141 * This is always called with the dmabuf->resv object locked when 343 struct dma_buf *dmabuf; member 385 * @dmabuf: buffer for this attachment. 387 * @node: list of dma_buf_attachment, protected by dma_resv lock of the dmabuf. 406 struct dma_buf *dmabuf; member 453 * @dmabuf: [in] pointer to dma_buf 456 * that either need to create additional references to the dmabuf on the 457 * kernel side. For example, an exporter that needs to keep a dmabuf pt 460 get_dma_buf(struct dma_buf *dmabuf) get_dma_buf() argument 473 dma_buf_is_dynamic(struct dma_buf *dmabuf) dma_buf_is_dynamic() argument [all...] |
/kernel/linux/linux-5.10/drivers/dma-buf/heaps/ |
H A D | heap-helpers.c | 93 static int dma_heap_attach(struct dma_buf *dmabuf, in dma_heap_attach() argument 97 struct heap_helper_buffer *buffer = dmabuf->priv; in dma_heap_attach() 125 static void dma_heap_detach(struct dma_buf *dmabuf, in dma_heap_detach() argument 129 struct heap_helper_buffer *buffer = dmabuf->priv; in dma_heap_detach() 178 static int dma_heap_mmap(struct dma_buf *dmabuf, struct vm_area_struct *vma) in dma_heap_mmap() argument 180 struct heap_helper_buffer *buffer = dmabuf->priv; in dma_heap_mmap() 191 static void dma_heap_dma_buf_release(struct dma_buf *dmabuf) in dma_heap_dma_buf_release() argument 193 struct heap_helper_buffer *buffer = dmabuf->priv; in dma_heap_dma_buf_release() 198 static int dma_heap_dma_buf_begin_cpu_access(struct dma_buf *dmabuf, in dma_heap_dma_buf_begin_cpu_access() argument 201 struct heap_helper_buffer *buffer = dmabuf in dma_heap_dma_buf_begin_cpu_access() 219 dma_heap_dma_buf_end_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction) dma_heap_dma_buf_end_cpu_access() argument 239 dma_heap_dma_buf_vmap(struct dma_buf *dmabuf) dma_heap_dma_buf_vmap() argument 251 dma_heap_dma_buf_vunmap(struct dma_buf *dmabuf, void *vaddr) dma_heap_dma_buf_vunmap() argument [all...] |
H A D | system_heap.c | 41 struct dma_buf *dmabuf; in system_heap_allocate() local 75 /* create the dmabuf */ in system_heap_allocate() 76 dmabuf = heap_helper_export_dmabuf(helper_buffer, fd_flags); in system_heap_allocate() 77 if (IS_ERR(dmabuf)) { in system_heap_allocate() 78 ret = PTR_ERR(dmabuf); in system_heap_allocate() 82 helper_buffer->dmabuf = dmabuf; in system_heap_allocate() 84 ret = dma_buf_fd(dmabuf, fd_flags); in system_heap_allocate() 86 dma_buf_put(dmabuf); in system_heap_allocate()
|
/kernel/linux/linux-5.10/drivers/gpu/drm/ |
H A D | drm_prime.c | 234 * @dev: parent device for the exported dmabuf 242 * Returns the new dmabuf. 383 struct dma_buf *dmabuf; in export_and_register_object() local 387 dmabuf = ERR_PTR(-ENOENT); in export_and_register_object() 388 return dmabuf; in export_and_register_object() 392 dmabuf = obj->funcs->export(obj, flags); in export_and_register_object() 394 dmabuf = dev->driver->gem_prime_export(obj, flags); in export_and_register_object() 396 dmabuf = drm_gem_prime_export(obj, flags); in export_and_register_object() 397 if (IS_ERR(dmabuf)) { in export_and_register_object() 401 return dmabuf; in export_and_register_object() 435 struct dma_buf *dmabuf; drm_gem_prime_handle_to_fd() local [all...] |
/kernel/linux/linux-6.6/drivers/dma-buf/heaps/ |
H A D | system_heap.c | 82 static int system_heap_attach(struct dma_buf *dmabuf, in system_heap_attach() argument 85 struct system_heap_buffer *buffer = dmabuf->priv; in system_heap_attach() 113 static void system_heap_detach(struct dma_buf *dmabuf, in system_heap_detach() argument 116 struct system_heap_buffer *buffer = dmabuf->priv; in system_heap_detach() 153 static int system_heap_dma_buf_begin_cpu_access(struct dma_buf *dmabuf, in system_heap_dma_buf_begin_cpu_access() argument 156 struct system_heap_buffer *buffer = dmabuf->priv; in system_heap_dma_buf_begin_cpu_access() 174 static int system_heap_dma_buf_end_cpu_access(struct dma_buf *dmabuf, in system_heap_dma_buf_end_cpu_access() argument 177 struct system_heap_buffer *buffer = dmabuf->priv; in system_heap_dma_buf_end_cpu_access() 195 static int system_heap_mmap(struct dma_buf *dmabuf, struct vm_area_struct *vma) in system_heap_mmap() argument 197 struct system_heap_buffer *buffer = dmabuf in system_heap_mmap() 243 system_heap_vmap(struct dma_buf *dmabuf, struct iosys_map *map) system_heap_vmap() argument 271 system_heap_vunmap(struct dma_buf *dmabuf, struct iosys_map *map) system_heap_vunmap() argument 284 system_heap_dma_buf_release(struct dma_buf *dmabuf) system_heap_dma_buf_release() argument 343 struct dma_buf *dmabuf; system_heap_allocate() local [all...] |
H A D | cma_heap.c | 50 static int cma_heap_attach(struct dma_buf *dmabuf, in cma_heap_attach() argument 53 struct cma_heap_buffer *buffer = dmabuf->priv; in cma_heap_attach() 83 static void cma_heap_detach(struct dma_buf *dmabuf, in cma_heap_detach() argument 86 struct cma_heap_buffer *buffer = dmabuf->priv; in cma_heap_detach() 121 static int cma_heap_dma_buf_begin_cpu_access(struct dma_buf *dmabuf, in cma_heap_dma_buf_begin_cpu_access() argument 124 struct cma_heap_buffer *buffer = dmabuf->priv; in cma_heap_dma_buf_begin_cpu_access() 142 static int cma_heap_dma_buf_end_cpu_access(struct dma_buf *dmabuf, in cma_heap_dma_buf_end_cpu_access() argument 145 struct cma_heap_buffer *buffer = dmabuf->priv; in cma_heap_dma_buf_end_cpu_access() 181 static int cma_heap_mmap(struct dma_buf *dmabuf, struct vm_area_struct *vma) in cma_heap_mmap() argument 183 struct cma_heap_buffer *buffer = dmabuf in cma_heap_mmap() 205 cma_heap_vmap(struct dma_buf *dmabuf, struct iosys_map *map) cma_heap_vmap() argument 232 cma_heap_vunmap(struct dma_buf *dmabuf, struct iosys_map *map) cma_heap_vunmap() argument 245 cma_heap_dma_buf_release(struct dma_buf *dmabuf) cma_heap_dma_buf_release() argument 288 struct dma_buf *dmabuf; cma_heap_allocate() local [all...] |
/kernel/linux/linux-6.6/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; in export_and_register_object() local 386 dmabuf = ERR_PTR(-ENOENT); in export_and_register_object() 387 return dmabuf; in export_and_register_object() 391 dmabuf = obj->funcs->export(obj, flags); in export_and_register_object() 393 dmabuf = drm_gem_prime_export(obj, flags); in export_and_register_object() 394 if (IS_ERR(dmabuf)) { in export_and_register_object() 398 return dmabuf; in export_and_register_object() 406 obj->dma_buf = dmabuf; in export_and_register_object() 432 struct dma_buf *dmabuf; drm_gem_prime_handle_to_fd() local [all...] |
/kernel/linux/linux-5.10/drivers/staging/media/tegra-vde/ |
H A D | dmabuf-cache.c | 31 struct dma_buf *dmabuf = entry->a->dmabuf; in tegra_vde_release_entry() local 39 dma_buf_detach(dmabuf, entry->a); in tegra_vde_release_entry() 40 dma_buf_put(dmabuf); in tegra_vde_release_entry() 61 struct dma_buf *dmabuf, in tegra_vde_dmabuf_cache_map() 76 if (entry->a->dmabuf != dmabuf) in tegra_vde_dmabuf_cache_map() 85 dma_buf_put(dmabuf); in tegra_vde_dmabuf_cache_map() 95 attachment = dma_buf_attach(dmabuf, dev); in tegra_vde_dmabuf_cache_map() 97 dev_err(dev, "Failed to attach dmabuf\ in tegra_vde_dmabuf_cache_map() 60 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) tegra_vde_dmabuf_cache_map() argument [all...] |
/kernel/linux/linux-6.6/drivers/media/platform/nvidia/tegra-vde/ |
H A D | dmabuf-cache.c | 34 struct dma_buf *dmabuf = entry->a->dmabuf; in tegra_vde_release_entry() local 42 dma_buf_detach(dmabuf, entry->a); in tegra_vde_release_entry() 43 dma_buf_put(dmabuf); in tegra_vde_release_entry() 64 struct dma_buf *dmabuf, in tegra_vde_dmabuf_cache_map() 79 if (entry->a->dmabuf != dmabuf) in tegra_vde_dmabuf_cache_map() 88 dma_buf_put(dmabuf); in tegra_vde_dmabuf_cache_map() 98 attachment = dma_buf_attach(dmabuf, dev); in tegra_vde_dmabuf_cache_map() 100 dev_err(dev, "Failed to attach dmabuf\ in tegra_vde_dmabuf_cache_map() 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) tegra_vde_dmabuf_cache_map() argument [all...] |
/kernel/linux/linux-5.10/drivers/staging/comedi/drivers/ |
H A D | addi_apci_3120.c | 150 struct apci3120_dmabuf dmabuf[2]; member 172 struct apci3120_dmabuf *dmabuf) in apci3120_init_dma() 189 apci3120_addon_write(dev, dmabuf->hw, AMCC_OP_REG_AMWAR); in apci3120_init_dma() 192 apci3120_addon_write(dev, dmabuf->use_size, AMCC_OP_REG_AMWTC); in apci3120_init_dma() 208 struct apci3120_dmabuf *dmabuf0 = &devpriv->dmabuf[0]; in apci3120_setup_dma() 209 struct apci3120_dmabuf *dmabuf1 = &devpriv->dmabuf[1]; in apci3120_setup_dma() 430 struct apci3120_dmabuf *dmabuf; in apci3120_interrupt_dma() local 434 dmabuf = &devpriv->dmabuf[devpriv->cur_dmabuf]; in apci3120_interrupt_dma() 436 nbytes = dmabuf in apci3120_interrupt_dma() 171 apci3120_init_dma(struct comedi_device *dev, struct apci3120_dmabuf *dmabuf) apci3120_init_dma() argument 909 struct apci3120_dmabuf *dmabuf; apci3120_dma_alloc() local 937 struct apci3120_dmabuf *dmabuf; apci3120_dma_free() local [all...] |
/kernel/linux/linux-6.6/drivers/comedi/drivers/ |
H A D | addi_apci_3120.c | 150 struct apci3120_dmabuf dmabuf[2]; member 172 struct apci3120_dmabuf *dmabuf) in apci3120_init_dma() 189 apci3120_addon_write(dev, dmabuf->hw, AMCC_OP_REG_AMWAR); in apci3120_init_dma() 192 apci3120_addon_write(dev, dmabuf->use_size, AMCC_OP_REG_AMWTC); in apci3120_init_dma() 208 struct apci3120_dmabuf *dmabuf0 = &devpriv->dmabuf[0]; in apci3120_setup_dma() 209 struct apci3120_dmabuf *dmabuf1 = &devpriv->dmabuf[1]; in apci3120_setup_dma() 430 struct apci3120_dmabuf *dmabuf; in apci3120_interrupt_dma() local 434 dmabuf = &devpriv->dmabuf[devpriv->cur_dmabuf]; in apci3120_interrupt_dma() 436 nbytes = dmabuf in apci3120_interrupt_dma() 171 apci3120_init_dma(struct comedi_device *dev, struct apci3120_dmabuf *dmabuf) apci3120_init_dma() argument 909 struct apci3120_dmabuf *dmabuf; apci3120_dma_alloc() local 937 struct apci3120_dmabuf *dmabuf; apci3120_dma_free() local [all...] |