sphinx.addnodesdocument)}( rawsourcechildren]( translations LanguagesNode)}(hhh](h pending_xref)}(hhh]docutils.nodesTextChinese (Simplified)}parenthsba attributes}(ids]classes]names]dupnames]backrefs] refdomainstdreftypedoc reftarget&/translations/zh_CN/driver-api/dma-bufmodnameN classnameN refexplicitutagnamehhh ubh)}(hhh]hChinese (Traditional)}hh2sbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget&/translations/zh_TW/driver-api/dma-bufmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hItalian}hhFsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget&/translations/it_IT/driver-api/dma-bufmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hJapanese}hhZsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget&/translations/ja_JP/driver-api/dma-bufmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hKorean}hhnsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget&/translations/ko_KR/driver-api/dma-bufmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hPortuguese (Brazilian)}hhsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget&/translations/pt_BR/driver-api/dma-bufmodnameN classnameN refexplicituh1hhh ubh)}(hhh]hSpanish}hhsbah}(h]h ]h"]h$]h&] refdomainh)reftypeh+ reftarget&/translations/sp_SP/driver-api/dma-bufmodnameN classnameN refexplicituh1hhh ubeh}(h]h ]h"]h$]h&]current_languageEnglishuh1h hh _documenthsourceNlineNubhsection)}(hhh](htitle)}(h,Buffer Sharing and Synchronization (dma-buf)h]h,Buffer Sharing and Synchronization (dma-buf)}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhhh@/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf.rsthKubh paragraph)}(hThe dma-buf subsystem provides the framework for sharing buffers for hardware (DMA) access across multiple device drivers and subsystems, and for synchronizing asynchronous hardware access.h]hThe dma-buf subsystem provides the framework for sharing buffers for hardware (DMA) access across multiple device drivers and subsystems, and for synchronizing asynchronous hardware access.}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhhhhubh)}(hAs an example, it is used extensively by the DRM subsystem to exchange buffers between processes, contexts, library APIs within the same process, and also to exchange buffers with other subsystems such as V4L2.h]hAs an example, it is used extensively by the DRM subsystem to exchange buffers between processes, contexts, library APIs within the same process, and also to exchange buffers with other subsystems such as V4L2.}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhhhhubh)}(hThis document describes the way in which kernel subsystems can use and interact with the three main primitives offered by dma-buf:h]hThis document describes the way in which kernel subsystems can use and interact with the three main primitives offered by dma-buf:}(hhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK hhhhubh block_quote)}(hX- dma-buf, representing a sg_table and exposed to userspace as a file descriptor to allow passing between processes, subsystems, devices, etc; - dma-fence, providing a mechanism to signal when an asynchronous hardware operation has completed; and - dma-resv, which manages a set of dma-fences for a particular dma-buf allowing implicit (kernel-ordered) synchronization of work to preserve the illusion of coherent access h]h bullet_list)}(hhh](h list_item)}(hdma-buf, representing a sg_table and exposed to userspace as a file descriptor to allow passing between processes, subsystems, devices, etc;h]h)}(hdma-buf, representing a sg_table and exposed to userspace as a file descriptor to allow passing between processes, subsystems, devices, etc;h]hdma-buf, representing a sg_table and exposed to userspace as a file descriptor to allow passing between processes, subsystems, devices, etc;}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1jhhubj)}(hedma-fence, providing a mechanism to signal when an asynchronous hardware operation has completed; andh]h)}(hedma-fence, providing a mechanism to signal when an asynchronous hardware operation has completed; andh]hedma-fence, providing a mechanism to signal when an asynchronous hardware operation has completed; and}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjubah}(h]h ]h"]h$]h&]uh1jhhubj)}(hdma-resv, which manages a set of dma-fences for a particular dma-buf allowing implicit (kernel-ordered) synchronization of work to preserve the illusion of coherent access h]h)}(hdma-resv, which manages a set of dma-fences for a particular dma-buf allowing implicit (kernel-ordered) synchronization of work to preserve the illusion of coherent accessh]hdma-resv, which manages a set of dma-fences for a particular dma-buf allowing implicit (kernel-ordered) synchronization of work to preserve the illusion of coherent access}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhj4ubah}(h]h ]h"]h$]h&]uh1jhhubeh}(h]h ]h"]h$]h&]bullet-uh1hhhhKhhubah}(h]h ]h"]h$]h&]uh1hhhhKhhhhubh)}(hhh](h)}(h Userspace API principles and useh]h Userspace API principles and use}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjZhhhhhKubh)}(hFor more details on how to design your subsystem's API for dma-buf use, please see Documentation/userspace-api/dma-buf-alloc-exchange.rst.h]hFor more details on how to design your subsystem’s API for dma-buf use, please see Documentation/userspace-api/dma-buf-alloc-exchange.rst.}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhKhjZhhubeh}(h] userspace-api-principles-and-useah ]h"] userspace api principles and useah$]h&]uh1hhhhhhhhKubh)}(hhh](h)}(hShared DMA Buffersh]hShared DMA Buffers}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhK"ubh)}(hThis document serves as a guide to device-driver writers on what is the dma-buf buffer sharing API, how to use it for exporting and using shared buffers.h]hThis document serves as a guide to device-driver writers on what is the dma-buf buffer sharing API, how to use it for exporting and using shared buffers.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK$hjhhubh)}(hAny device driver which wishes to be a part of DMA buffer sharing, can do so as either the 'exporter' of buffers, or the 'user' or 'importer' of buffers.h]hAny device driver which wishes to be a part of DMA buffer sharing, can do so as either the ‘exporter’ of buffers, or the ‘user’ or ‘importer’ of buffers.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK'hjhhubh)}(hwSay a driver A wants to use buffers created by driver B, then we call B as the exporter, and A as buffer-user/importer.h]hwSay a driver A wants to use buffers created by driver B, then we call B as the exporter, and A as buffer-user/importer.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK*hjhhubh)}(h The exporterh]h The exporter}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK-hjhhubh)}(hX- implements and manages operations in :c:type:`struct dma_buf_ops ` for the buffer, - allows other users to share the buffer by using dma_buf sharing APIs, - manages the details of buffer allocation, wrapped in a :c:type:`struct dma_buf `, - decides about the actual backing storage where this allocation happens, - and takes care of any migration of scatterlist - for all (shared) users of this buffer. h]h)}(hhh](j)}(h_implements and manages operations in :c:type:`struct dma_buf_ops ` for the buffer,h]h)}(h_implements and manages operations in :c:type:`struct dma_buf_ops ` for the buffer,h](h%implements and manages operations in }(hjhhhNhNubh)}(h*:c:type:`struct dma_buf_ops `h]hliteral)}(hjh]hstruct dma_buf_ops}(hjhhhNhNubah}(h]h ](xrefcc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocdriver-api/dma-buf refdomainjreftypetype refexplicitrefwarn reftarget dma_buf_opsuh1hhhhK/hjubh for the buffer,}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhK/hjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hEallows other users to share the buffer by using dma_buf sharing APIs,h]h)}(hjh]hEallows other users to share the buffer by using dma_buf sharing APIs,}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK1hjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hZmanages the details of buffer allocation, wrapped in a :c:type:`struct dma_buf `,h]h)}(hZmanages the details of buffer allocation, wrapped in a :c:type:`struct dma_buf `,h](h7manages the details of buffer allocation, wrapped in a }(hj-hhhNhNubh)}(h":c:type:`struct dma_buf `h]j)}(hj7h]hstruct dma_buf}(hj9hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj5ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjdma_bufuh1hhhhK2hj-ubh,}(hj-hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhK2hj)ubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hGdecides about the actual backing storage where this allocation happens,h]h)}(hjfh]hGdecides about the actual backing storage where this allocation happens,}(hjhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK4hjdubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hXand takes care of any migration of scatterlist - for all (shared) users of this buffer. h]h)}(hWand takes care of any migration of scatterlist - for all (shared) users of this buffer.h]hWand takes care of any migration of scatterlist - for all (shared) users of this buffer.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK5hj{ubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]jRjSuh1hhhhK/hjubah}(h]h ]h"]h$]h&]uh1hhhhK/hjhhubh)}(hThe buffer-userh]hThe buffer-user}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK8hjhhubh)}(hX~- is one of (many) sharing users of the buffer. - doesn't need to worry about how the buffer is allocated, or where. - and needs a mechanism to get access to the scatterlist that makes up this buffer in memory, mapped into its own address space, so it can access the same area of memory. This interface is provided by :c:type:`struct dma_buf_attachment `. h]h)}(hhh](j)}(h-is one of (many) sharing users of the buffer.h]h)}(hjh]h-is one of (many) sharing users of the buffer.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK:hjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hBdoesn't need to worry about how the buffer is allocated, or where.h]h)}(hjh]hDdoesn’t need to worry about how the buffer is allocated, or where.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhK;hjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hXand needs a mechanism to get access to the scatterlist that makes up this buffer in memory, mapped into its own address space, so it can access the same area of memory. This interface is provided by :c:type:`struct dma_buf_attachment `. h]h)}(hXand needs a mechanism to get access to the scatterlist that makes up this buffer in memory, mapped into its own address space, so it can access the same area of memory. This interface is provided by :c:type:`struct dma_buf_attachment `.h](hand needs a mechanism to get access to the scatterlist that makes up this buffer in memory, mapped into its own address space, so it can access the same area of memory. This interface is provided by }(hjhhhNhNubh)}(h8:c:type:`struct dma_buf_attachment `h]j)}(hjh]hstruct dma_buf_attachment}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjdma_buf_attachmentuh1hhhhK` mutex. h](h)}(hX(Fallback operations in the kernel, for example when a device is connected over USB and the kernel needs to shuffle the data around first before sending it away. Cache coherency is handled by bracketing any transactions with calls to dma_buf_begin_cpu_access() and dma_buf_end_cpu_access() access.h]hX(Fallback operations in the kernel, for example when a device is connected over USB and the kernel needs to shuffle the data around first before sending it away. Cache coherency is handled by bracketing any transactions with calls to dma_buf_begin_cpu_access() and dma_buf_end_cpu_access() access.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubh)}(hSince for most kernel internal dma-buf accesses need the entire buffer, a vmap interface is introduced. Note that on very old 32-bit architectures vmalloc space might be limited and result in vmap calls failing.h]hSince for most kernel internal dma-buf accesses need the entire buffer, a vmap interface is introduced. Note that on very old 32-bit architectures vmalloc space might be limited and result in vmap calls failing.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubh)}(h Interfaces:h]h Interfaces:}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubh literal_block)}(hvoid *dma_buf_vmap(struct dma_buf *dmabuf, struct iosys_map *map) void dma_buf_vunmap(struct dma_buf *dmabuf, struct iosys_map *map)h]hvoid *dma_buf_vmap(struct dma_buf *dmabuf, struct iosys_map *map) void dma_buf_vunmap(struct dma_buf *dmabuf, struct iosys_map *map)}hjsbah}(h]h ]h"]h$]h&] xml:spacepreserveforcelanguagejhighlight_args}uh1jh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubh)}(hXThe vmap call can fail if there is no vmap support in the exporter, or if it runs out of vmalloc space. Note that the dma-buf layer keeps a reference count for all vmap access and calls down into the exporter's vmap function only when no vmapping exists, and only unmaps it once. Protection against concurrent vmap/vunmap calls is provided by taking the :c:type:`dma_buf.lock ` mutex.h](hXdThe vmap call can fail if there is no vmap support in the exporter, or if it runs out of vmalloc space. Note that the dma-buf layer keeps a reference count for all vmap access and calls down into the exporter’s vmap function only when no vmapping exists, and only unmaps it once. Protection against concurrent vmap/vunmap calls is provided by taking the }(hjhhhNhNubh)}(h :c:type:`dma_buf.lock `h]j)}(hjh]h dma_buf.lock}(hj hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjdma_bufuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubh mutex.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj%hMhjubeh}(h]h ]h"]h$]h&]uh1jhjubj)}(hXFor full compatibility on the importer side with existing userspace interfaces, which might already support mmap'ing buffers. This is needed in many processing pipelines (e.g. feeding a software rendered image into a hardware pipeline, thumbnail creation, snapshots, ...). Also, Android's ION framework already supported this and for DMA buffer file descriptors to replace ION buffers mmap support was needed. There is no special interfaces, userspace simply calls mmap on the dma-buf fd. But like for CPU access there's a need to bracket the actual access, which is handled by the ioctl (DMA_BUF_IOCTL_SYNC). Note that DMA_BUF_IOCTL_SYNC can fail with -EAGAIN or -EINTR, in which case it must be restarted. Some systems might need some sort of cache coherency management e.g. when CPU and GPU domains are being accessed through dma-buf at the same time. To circumvent this problem there are begin/end coherency markers, that forward directly to existing dma-buf device drivers vfunc hooks. Userspace can make use of those markers through the DMA_BUF_IOCTL_SYNC ioctl. The sequence would be used like following: - mmap dma-buf fd - for each drawing/upload cycle in CPU 1. SYNC_START ioctl, 2. read/write to mmap area 3. SYNC_END ioctl. This can be repeated as often as you want (with the new data being consumed by say the GPU or the scanout device) - munmap once you don't need the buffer any more For correctness and optimal performance, it is always required to use SYNC_START and SYNC_END before and after, respectively, when accessing the mapped address. Userspace cannot rely on coherent access, even when there are systems where it just works without calling these ioctls. h](h)}(hXFor full compatibility on the importer side with existing userspace interfaces, which might already support mmap'ing buffers. This is needed in many processing pipelines (e.g. feeding a software rendered image into a hardware pipeline, thumbnail creation, snapshots, ...). Also, Android's ION framework already supported this and for DMA buffer file descriptors to replace ION buffers mmap support was needed.h]hXFor full compatibility on the importer side with existing userspace interfaces, which might already support mmap’ing buffers. This is needed in many processing pipelines (e.g. feeding a software rendered image into a hardware pipeline, thumbnail creation, snapshots, ...). Also, Android’s ION framework already supported this and for DMA buffer file descriptors to replace ION buffers mmap support was needed.}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhj6ubh)}(hX)There is no special interfaces, userspace simply calls mmap on the dma-buf fd. But like for CPU access there's a need to bracket the actual access, which is handled by the ioctl (DMA_BUF_IOCTL_SYNC). Note that DMA_BUF_IOCTL_SYNC can fail with -EAGAIN or -EINTR, in which case it must be restarted.h]hX+There is no special interfaces, userspace simply calls mmap on the dma-buf fd. But like for CPU access there’s a need to bracket the actual access, which is handled by the ioctl (DMA_BUF_IOCTL_SYNC). Note that DMA_BUF_IOCTL_SYNC can fail with -EAGAIN or -EINTR, in which case it must be restarted.}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhj6ubh)}(hXSome systems might need some sort of cache coherency management e.g. when CPU and GPU domains are being accessed through dma-buf at the same time. To circumvent this problem there are begin/end coherency markers, that forward directly to existing dma-buf device drivers vfunc hooks. Userspace can make use of those markers through the DMA_BUF_IOCTL_SYNC ioctl. The sequence would be used like following:h]hXSome systems might need some sort of cache coherency management e.g. when CPU and GPU domains are being accessed through dma-buf at the same time. To circumvent this problem there are begin/end coherency markers, that forward directly to existing dma-buf device drivers vfunc hooks. Userspace can make use of those markers through the DMA_BUF_IOCTL_SYNC ioctl. The sequence would be used like following:}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhj6ubh)}(hXE - mmap dma-buf fd - for each drawing/upload cycle in CPU 1. SYNC_START ioctl, 2. read/write to mmap area 3. SYNC_END ioctl. This can be repeated as often as you want (with the new data being consumed by say the GPU or the scanout device) - munmap once you don't need the buffer any more For correctness and optimal performance, it is always required to use SYNC_START and SYNC_END before and after, respectively, when accessing the mapped address. Userspace cannot rely on coherent access, even when there are systems where it just works without calling these ioctls. h](h)}(hX%- mmap dma-buf fd - for each drawing/upload cycle in CPU 1. SYNC_START ioctl, 2. read/write to mmap area 3. SYNC_END ioctl. This can be repeated as often as you want (with the new data being consumed by say the GPU or the scanout device) - munmap once you don't need the buffer any more h]h)}(hhh](j)}(hmmap dma-buf fdh]h)}(hjth]hmmap dma-buf fd}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjrubah}(h]h ]h"]h$]h&]uh1jhjoubj)}(hfor each drawing/upload cycle in CPU 1. SYNC_START ioctl, 2. read/write to mmap area 3. SYNC_END ioctl. This can be repeated as often as you want (with the new data being consumed by say the GPU or the scanout device)h]h)}(hfor each drawing/upload cycle in CPU 1. SYNC_START ioctl, 2. read/write to mmap area 3. SYNC_END ioctl. This can be repeated as often as you want (with the new data being consumed by say the GPU or the scanout device)h]hfor each drawing/upload cycle in CPU 1. SYNC_START ioctl, 2. read/write to mmap area 3. SYNC_END ioctl. This can be repeated as often as you want (with the new data being consumed by say the GPU or the scanout device)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhjoubj)}(h/munmap once you don't need the buffer any more h]h)}(h.munmap once you don't need the buffer any moreh]h0munmap once you don’t need the buffer any more}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhjoubeh}(h]h ]h"]h$]h&]jRjSuh1hhjhMhjkubah}(h]h ]h"]h$]h&]uh1hhjhMhjgubh)}(hXFor correctness and optimal performance, it is always required to use SYNC_START and SYNC_END before and after, respectively, when accessing the mapped address. Userspace cannot rely on coherent access, even when there are systems where it just works without calling these ioctls.h]hXFor correctness and optimal performance, it is always required to use SYNC_START and SYNC_END before and after, respectively, when accessing the mapped address. Userspace cannot rely on coherent access, even when there are systems where it just works without calling these ioctls.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjgubeh}(h]h ]h"]h$]h&]uh1hhjhMhj6ubeh}(h]h ]h"]h$]h&]uh1jhjubj)}(hXAnd as a CPU fallback in userspace processing pipelines. Similar to the motivation for kernel cpu access it is again important that the userspace code of a given importing subsystem can use the same interfaces with a imported dma-buf buffer object as with a native buffer object. This is especially important for drm where the userspace part of contemporary OpenGL, X, and other drivers is huge, and reworking them to use a different way to mmap a buffer rather invasive. The assumption in the current dma-buf interfaces is that redirecting the initial mmap is all that's needed. A survey of some of the existing subsystems shows that no driver seems to do any nefarious thing like syncing up with outstanding asynchronous processing on the device or allocating special resources at fault time. So hopefully this is good enough, since adding interfaces to intercept pagefaults and allow pte shootdowns would increase the complexity quite a bit. Interface: .. code-block:: c int dma_buf_mmap(struct dma_buf *, struct vm_area_struct *, unsigned long); If the importing subsystem simply provides a special-purpose mmap call to set up a mapping in userspace, calling do_mmap with :c:type:`dma_buf.file ` will equally achieve that for a dma-buf object. h](h)}(h8And as a CPU fallback in userspace processing pipelines.h]h8And as a CPU fallback in userspace processing pipelines.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubh)}(hXSimilar to the motivation for kernel cpu access it is again important that the userspace code of a given importing subsystem can use the same interfaces with a imported dma-buf buffer object as with a native buffer object. This is especially important for drm where the userspace part of contemporary OpenGL, X, and other drivers is huge, and reworking them to use a different way to mmap a buffer rather invasive.h]hXSimilar to the motivation for kernel cpu access it is again important that the userspace code of a given importing subsystem can use the same interfaces with a imported dma-buf buffer object as with a native buffer object. This is especially important for drm where the userspace part of contemporary OpenGL, X, and other drivers is huge, and reworking them to use a different way to mmap a buffer rather invasive.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubh)}(hXThe assumption in the current dma-buf interfaces is that redirecting the initial mmap is all that's needed. A survey of some of the existing subsystems shows that no driver seems to do any nefarious thing like syncing up with outstanding asynchronous processing on the device or allocating special resources at fault time. So hopefully this is good enough, since adding interfaces to intercept pagefaults and allow pte shootdowns would increase the complexity quite a bit.h]hXThe assumption in the current dma-buf interfaces is that redirecting the initial mmap is all that’s needed. A survey of some of the existing subsystems shows that no driver seems to do any nefarious thing like syncing up with outstanding asynchronous processing on the device or allocating special resources at fault time. So hopefully this is good enough, since adding interfaces to intercept pagefaults and allow pte shootdowns would increase the complexity quite a bit.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubh)}(h Interface:h]h Interface:}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubj)}(hKint dma_buf_mmap(struct dma_buf *, struct vm_area_struct *, unsigned long);h]hKint dma_buf_mmap(struct dma_buf *, struct vm_area_struct *, unsigned long);}hj#sbah}(h]h ]h"]h$]h&]jjjjjj}uh1jh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhjubh)}(hIf the importing subsystem simply provides a special-purpose mmap call to set up a mapping in userspace, calling do_mmap with :c:type:`dma_buf.file ` will equally achieve that for a dma-buf object.h](h~If the importing subsystem simply provides a special-purpose mmap call to set up a mapping in userspace, calling do_mmap with }(hj3hhhNhNubh)}(h :c:type:`dma_buf.file `h]j)}(hj=h]h dma_buf.file}(hj?hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj;ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjdma_bufuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:119: ./drivers/dma-buf/dma-buf.chMhj3ubh0 will equally achieve that for a dma-buf object.}(hj3hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjZhMhjubeh}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]jRjSuh1hhjhMhjhhubeh}(h]jah ]h"] cpu access to dma buffer objectsah$]h&]uh1hhjhhhhhKu referencedKubh)}(hhh](h)}(hImplicit Fence Poll Supporth]hImplicit Fence Poll Support}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjyhhhhhK{ubh)}(hX1To support cross-device and cross-driver synchronization of buffer access implicit fences (represented internally in the kernel with :c:type:`struct dma_fence `) can be attached to a :c:type:`dma_buf`. The glue for that and a few related things are provided in the :c:type:`dma_resv` structure.h](hTo support cross-device and cross-driver synchronization of buffer access implicit fences (represented internally in the kernel with }(hjhhhNhNubh)}(h&:c:type:`struct dma_fence `h]j)}(hjh]hstruct dma_fence}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnj dma_fenceuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:125: ./drivers/dma-buf/dma-buf.chMhjubh) can be attached to a }(hjhhhNhNubh)}(h:c:type:`dma_buf`h]j)}(hjh]hdma_buf}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjdma_bufuh1hhjhMhjubhA. The glue for that and a few related things are provided in the }(hjhhhNhNubh)}(h:c:type:`dma_resv`h]j)}(hjh]hdma_resv}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjdma_resvuh1hhjhMhjubh structure.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMhjyhhubh)}(hgUserspace can query the state of these implicitly tracked fences using poll() and related system calls:h]hgUserspace can query the state of these implicitly tracked fences using poll() and related system calls:}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:125: ./drivers/dma-buf/dma-buf.chMhjyhhubh)}(hhh](j)}(hsChecking for EPOLLIN, i.e. read access, can be use to query the state of the most recent write or exclusive fence. h]h)}(hrChecking for EPOLLIN, i.e. read access, can be use to query the state of the most recent write or exclusive fence.h]hrChecking for EPOLLIN, i.e. read access, can be use to query the state of the most recent write or exclusive fence.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:125: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(h|Checking for EPOLLOUT, i.e. write access, can be used to query the state of all attached fences, shared and exclusive ones. h]h)}(h{Checking for EPOLLOUT, i.e. write access, can be used to query the state of all attached fences, shared and exclusive ones.h]h{Checking for EPOLLOUT, i.e. write access, can be used to query the state of all attached fences, shared and exclusive ones.}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:125: ./drivers/dma-buf/dma-buf.chM"hj-ubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]jRjSuh1hhj&hMhjyhhubh)}(hNote that this only signals the completion of the respective fences, i.e. the DMA transfers are complete. Cache flushing and any other necessary preparations before CPU access can begin still need to happen.h]hNote that this only signals the completion of the respective fences, i.e. the DMA transfers are complete. Cache flushing and any other necessary preparations before CPU access can begin still need to happen.}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:125: ./drivers/dma-buf/dma-buf.chM%hjyhhubh)}(hAs an alternative to poll(), the set of fences on DMA buffer can be exported as a :c:type:`sync_file` using :c:type:`dma_buf_sync_file_export`.h](hRAs an alternative to poll(), the set of fences on DMA buffer can be exported as a }(hj[hhhNhNubh)}(h:c:type:`sync_file`h]j)}(hjeh]h sync_file}(hjghhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjcubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnj sync_fileuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:125: ./drivers/dma-buf/dma-buf.chM)hj[ubh using }(hj[hhhNhNubh)}(h":c:type:`dma_buf_sync_file_export`h]j)}(hjh]hdma_buf_sync_file_export}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjdma_buf_sync_file_exportuh1hhjhM)hj[ubh.}(hj[hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhM)hjyhhubeh}(h]jah ]h"]implicit fence poll supportah$]h&]uh1hhjhhhhhK{jxKubh)}(hhh](h)}(hDMA Buffer ioctlsh]hDMA Buffer ioctls}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhKubhindex)}(hhh]h}(h]h ]h"]h$]h&]entries](singledma_buf_sync (C struct)c.dma_buf_synchNtauh1jhjhhh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhNubhdesc)}(hhh](hdesc_signature)}(h dma_buf_synch]hdesc_signature_line)}(hstruct dma_buf_synch](hdesc_sig_keyword)}(hstructh]hstruct}(hjhhhNhNubah}(h]h ]kah"]h$]h&]uh1jhjhhh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKubhdesc_sig_space)}(h h]h }(hjhhhNhNubah}(h]h ]wah"]h$]h&]uh1jhjhhhjhKubh desc_name)}(h dma_buf_synch]h desc_sig_name)}(hjh]h dma_buf_sync}(hj hhhNhNubah}(h]h ]nah"]h$]h&]uh1j hj ubah}(h]h ](sig-namedescnameeh"]h$]h&]jjuh1j hjhhhjhKubeh}(h]h ]h"]h$]h&]jj add_permalinkuh1jsphinx_line_type declaratorhjhhhjhKubah}(h]jah ](sig sig-objecteh"]h$]h&] is_multiline _toc_parts) _toc_namehuh1jhjhKhjhhubh desc_content)}(hhh]h)}(hSynchronize with CPU access.h]hSynchronize with CPU access.}(hjE hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjB hhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhKubeh}(h]h ](jstructeh"]h$]h&]domainjobjtypej] desctypej] noindex noindexentrynocontentsentryuh1jhhhjhjhNubh container)}(hX8**Definition**:: struct dma_buf_sync { __u64 flags; }; **Members** ``flags`` Set of access flags DMA_BUF_SYNC_START: Indicates the start of a map access session. DMA_BUF_SYNC_END: Indicates the end of a map access session. DMA_BUF_SYNC_READ: Indicates that the mapped DMA buffer will be read by the client via the CPU map. DMA_BUF_SYNC_WRITE: Indicates that the mapped DMA buffer will be written by the client via the CPU map. DMA_BUF_SYNC_RW: An alias for DMA_BUF_SYNC_READ | DMA_BUF_SYNC_WRITE.h](h)}(h**Definition**::h](hstrong)}(h**Definition**h]h Definition}(hjs hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjm ubh:}(hjm hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhji ubj)}(h)struct dma_buf_sync { __u64 flags; };h]h)struct dma_buf_sync { __u64 flags; };}hj sbah}(h]h ]h"]h$]h&]jjuh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK!hji ubh)}(h **Members**h]jr )}(hj h]hMembers}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK%hji ubhdefinition_list)}(hhh]hdefinition_list_item)}(hX``flags`` Set of access flags DMA_BUF_SYNC_START: Indicates the start of a map access session. DMA_BUF_SYNC_END: Indicates the end of a map access session. DMA_BUF_SYNC_READ: Indicates that the mapped DMA buffer will be read by the client via the CPU map. DMA_BUF_SYNC_WRITE: Indicates that the mapped DMA buffer will be written by the client via the CPU map. DMA_BUF_SYNC_RW: An alias for DMA_BUF_SYNC_READ | DMA_BUF_SYNC_WRITE.h](hterm)}(h ``flags``h]j)}(hj h]hflags}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKJhj ubh definition)}(hhh](h)}(hSet of access flagsh]hSet of access flags}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK:hj ubj )}(hhh](j )}(hADMA_BUF_SYNC_START: Indicates the start of a map access session. h](j )}(hDMA_BUF_SYNC_START:h]hDMA_BUF_SYNC_START:}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j h`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK=hj ubj )}(hhh]h)}(h,Indicates the start of a map access session.h]h,Indicates the start of a map access session.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hK=hj ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj hK=hj ubj )}(h=DMA_BUF_SYNC_END: Indicates the end of a map access session. h](j )}(hDMA_BUF_SYNC_END:h]hDMA_BUF_SYNC_END:}(hj# hhhNhNubah}(h]h ]h"]h$]h&]uh1j h`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK@hj ubj )}(hhh]h)}(h*Indicates the end of a map access session.h]h*Indicates the end of a map access session.}(hj5 hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj1 hK@hj2 ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj1 hK@hj ubj )}(hdDMA_BUF_SYNC_READ: Indicates that the mapped DMA buffer will be read by the client via the CPU map. h](j )}(hDMA_BUF_SYNC_READ:h]hDMA_BUF_SYNC_READ:}(hjS hhhNhNubah}(h]h ]h"]h$]h&]uh1j h`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKDhjO ubj )}(hhh]h)}(hPIndicates that the mapped DMA buffer will be read by the client via the CPU map.h]hPIndicates that the mapped DMA buffer will be read by the client via the CPU map.}(hje hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKChjb ubah}(h]h ]h"]h$]h&]uh1j hjO ubeh}(h]h ]h"]h$]h&]uh1j hja hKDhj ubj )}(hhDMA_BUF_SYNC_WRITE: Indicates that the mapped DMA buffer will be written by the client via the CPU map. h](j )}(hDMA_BUF_SYNC_WRITE:h]hDMA_BUF_SYNC_WRITE:}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j h`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKHhj ubj )}(hhh]h)}(hSIndicates that the mapped DMA buffer will be written by the client via the CPU map.h]hSIndicates that the mapped DMA buffer will be written by the client via the CPU map.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKGhj ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj hKHhj ubj )}(hEDMA_BUF_SYNC_RW: An alias for DMA_BUF_SYNC_READ | DMA_BUF_SYNC_WRITE.h](j )}(hDMA_BUF_SYNC_RW:h]hDMA_BUF_SYNC_RW:}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1j hj hKJhj ubj )}(hhh]h)}(h4An alias for DMA_BUF_SYNC_READ | DMA_BUF_SYNC_WRITE.h]h4An alias for DMA_BUF_SYNC_READ | DMA_BUF_SYNC_WRITE.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKKhj ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj hKJhj ubeh}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj hKJhj ubah}(h]h ]h"]h$]h&]uh1j hji ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhjhNubh)}(h**Description**h]jr )}(hj h]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKNhjhhubh)}(hX*When a DMA buffer is accessed from the CPU via mmap, it is not always possible to guarantee coherency between the CPU-visible map and underlying memory. To manage coherency, DMA_BUF_IOCTL_SYNC must be used to bracket any CPU access to give the kernel the chance to shuffle memory around if needed.h]hX*When a DMA buffer is accessed from the CPU via mmap, it is not always possible to guarantee coherency between the CPU-visible map and underlying memory. To manage coherency, DMA_BUF_IOCTL_SYNC must be used to bracket any CPU access to give the kernel the chance to shuffle memory around if needed.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjhhubh)}(hPrior to accessing the map, the client must call DMA_BUF_IOCTL_SYNC with DMA_BUF_SYNC_START and the appropriate read/write flags. Once the access is complete, the client should call DMA_BUF_IOCTL_SYNC with DMA_BUF_SYNC_END and the same read/write flags.h]hPrior to accessing the map, the client must call DMA_BUF_IOCTL_SYNC with DMA_BUF_SYNC_START and the appropriate read/write flags. Once the access is complete, the client should call DMA_BUF_IOCTL_SYNC with DMA_BUF_SYNC_END and the same read/write flags.}(hj' hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK"hjhhubh)}(hXThe synchronization provided via DMA_BUF_IOCTL_SYNC only provides cache coherency. It does not prevent other processes or devices from accessing the memory at the same time. If synchronization with a GPU or other device driver is required, it is the client's responsibility to wait for buffer to be ready for reading or writing before calling this ioctl with DMA_BUF_SYNC_START. Likewise, the client must ensure that follow-up work is not submitted to GPU or other device driver until after this ioctl has been called with DMA_BUF_SYNC_END?h]hX!The synchronization provided via DMA_BUF_IOCTL_SYNC only provides cache coherency. It does not prevent other processes or devices from accessing the memory at the same time. If synchronization with a GPU or other device driver is required, it is the client’s responsibility to wait for buffer to be ready for reading or writing before calling this ioctl with DMA_BUF_SYNC_START. Likewise, the client must ensure that follow-up work is not submitted to GPU or other device driver until after this ioctl has been called with DMA_BUF_SYNC_END?}(hj6 hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK'hjhhubh)}(hXeIf the driver or API with which the client is interacting uses implicit synchronization, waiting for prior work to complete can be done via poll() on the DMA buffer file descriptor. If the driver or API requires explicit synchronization, the client may have to wait on a sync_file or other synchronization primitive outside the scope of the DMA buffer API.h]hXeIf the driver or API with which the client is interacting uses implicit synchronization, waiting for prior work to complete can be done via poll() on the DMA buffer file descriptor. If the driver or API requires explicit synchronization, the client may have to wait on a sync_file or other synchronization primitive outside the scope of the DMA buffer API.}(hjE hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK0hjhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_buf_export_sync_file (C struct)c.dma_buf_export_sync_filehNtauh1jhjhhhjhNubj)}(hhh](j)}(hdma_buf_export_sync_fileh]j)}(hstruct dma_buf_export_sync_fileh](j)}(hjh]hstruct}(hjm hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhji hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK9ubj)}(h h]h }(hj{ hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhji hhhjz hK9ubj )}(hdma_buf_export_sync_fileh]j )}(hjg h]hdma_buf_export_sync_file}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hji hhhjz hK9ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hje hhhjz hK9ubah}(h]j` ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjz hK9hjb hhubjA )}(hhh]h)}(hGet a sync_file from a dma-bufh]hGet a sync_file from a dma-buf}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKZhj hhubah}(h]h ]h"]h$]h&]uh1j@ hjb hhhjz hK9ubeh}(h]h ](jstructeh"]h$]h&]ja jjb j jc j jd je jf uh1jhhhjhjhNubjh )}(hX**Definition**:: struct dma_buf_export_sync_file { __u32 flags; __s32 fd; }; **Members** ``flags`` Read/write flags Must be DMA_BUF_SYNC_READ, DMA_BUF_SYNC_WRITE, or both. If DMA_BUF_SYNC_READ is set and DMA_BUF_SYNC_WRITE is not set, the returned sync file waits on any writers of the dma-buf to complete. Waiting on the returned sync file is equivalent to poll() with POLLIN. If DMA_BUF_SYNC_WRITE is set, the returned sync file waits on any users of the dma-buf (read or write) to complete. Waiting on the returned sync file is equivalent to poll() with POLLOUT. If both DMA_BUF_SYNC_WRITE and DMA_BUF_SYNC_READ are set, this is equivalent to just DMA_BUF_SYNC_WRITE. ``fd`` Returned sync file descriptorh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubh:}(hj hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK^hj ubj)}(hCstruct dma_buf_export_sync_file { __u32 flags; __s32 fd; };h]hCstruct dma_buf_export_sync_file { __u32 flags; __s32 fd; };}hj sbah}(h]h ]h"]h$]h&]jjuh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK`hj ubh)}(h **Members**h]jr )}(hj h]hMembers}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKehj ubj )}(hhh](j )}(hXK``flags`` Read/write flags Must be DMA_BUF_SYNC_READ, DMA_BUF_SYNC_WRITE, or both. If DMA_BUF_SYNC_READ is set and DMA_BUF_SYNC_WRITE is not set, the returned sync file waits on any writers of the dma-buf to complete. Waiting on the returned sync file is equivalent to poll() with POLLIN. If DMA_BUF_SYNC_WRITE is set, the returned sync file waits on any users of the dma-buf (read or write) to complete. Waiting on the returned sync file is equivalent to poll() with POLLOUT. If both DMA_BUF_SYNC_WRITE and DMA_BUF_SYNC_READ are set, this is equivalent to just DMA_BUF_SYNC_WRITE. h](j )}(h ``flags``h]j)}(hj h]hflags}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhj ubj )}(hhh](h)}(hRead/write flagsh]hRead/write flags}(hj5 hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKzhj2 ubh)}(h7Must be DMA_BUF_SYNC_READ, DMA_BUF_SYNC_WRITE, or both.h]h7Must be DMA_BUF_SYNC_READ, DMA_BUF_SYNC_WRITE, or both.}(hjD hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK|hj2 ubh)}(hIf DMA_BUF_SYNC_READ is set and DMA_BUF_SYNC_WRITE is not set, the returned sync file waits on any writers of the dma-buf to complete. Waiting on the returned sync file is equivalent to poll() with POLLIN.h]hIf DMA_BUF_SYNC_READ is set and DMA_BUF_SYNC_WRITE is not set, the returned sync file waits on any writers of the dma-buf to complete. Waiting on the returned sync file is equivalent to poll() with POLLIN.}(hjS hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK~hj2 ubh)}(hX%If DMA_BUF_SYNC_WRITE is set, the returned sync file waits on any users of the dma-buf (read or write) to complete. Waiting on the returned sync file is equivalent to poll() with POLLOUT. If both DMA_BUF_SYNC_WRITE and DMA_BUF_SYNC_READ are set, this is equivalent to just DMA_BUF_SYNC_WRITE.h]hX%If DMA_BUF_SYNC_WRITE is set, the returned sync file waits on any users of the dma-buf (read or write) to complete. Waiting on the returned sync file is equivalent to poll() with POLLOUT. If both DMA_BUF_SYNC_WRITE and DMA_BUF_SYNC_READ are set, this is equivalent to just DMA_BUF_SYNC_WRITE.}(hjb hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhj2 ubeh}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj1 hKhj ubj )}(h$``fd`` Returned sync file descriptorh](j )}(h``fd``h]j)}(hj h]hfd}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhj} ubj )}(hhh]h)}(hReturned sync file descriptorh]hReturned sync file descriptor}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhj ubah}(h]h ]h"]h$]h&]uh1j hj} ubeh}(h]h ]h"]h$]h&]uh1j hj hKhj ubeh}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhjhNubh)}(h**Description**h]jr )}(hj h]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjhhubh)}(hX2Userspace can perform a DMA_BUF_IOCTL_EXPORT_SYNC_FILE to retrieve the current set of fences on a dma-buf file descriptor as a sync_file. CPU waits via poll() or other driver-specific mechanisms typically wait on whatever fences are on the dma-buf at the time the wait begins. This is similar except that it takes a snapshot of the current fences on the dma-buf for waiting later instead of waiting immediately. This is useful for modern graphics APIs such as Vulkan which assume an explicit synchronization model but still need to inter-operate with dma-buf.h]hX2Userspace can perform a DMA_BUF_IOCTL_EXPORT_SYNC_FILE to retrieve the current set of fences on a dma-buf file descriptor as a sync_file. CPU waits via poll() or other driver-specific mechanisms typically wait on whatever fences are on the dma-buf at the time the wait begins. This is similar except that it takes a snapshot of the current fences on the dma-buf for waiting later instead of waiting immediately. This is useful for modern graphics APIs such as Vulkan which assume an explicit synchronization model but still need to inter-operate with dma-buf.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhK[hjhhubh)}(h,The intended usage pattern is the following:h]h,The intended usage pattern is the following:}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKdhjhhubh)}(hX1. Export a sync_file with flags corresponding to the expected GPU usage via DMA_BUF_IOCTL_EXPORT_SYNC_FILE. 2. Submit rendering work which uses the dma-buf. The work should wait on the exported sync file before rendering and produce another sync_file when complete. 3. Import the rendering-complete sync_file into the dma-buf with flags corresponding to the GPU usage via DMA_BUF_IOCTL_IMPORT_SYNC_FILE. h]jm)}(hhh](j)}(hjExport a sync_file with flags corresponding to the expected GPU usage via DMA_BUF_IOCTL_EXPORT_SYNC_FILE. h]h)}(hiExport a sync_file with flags corresponding to the expected GPU usage via DMA_BUF_IOCTL_EXPORT_SYNC_FILE.h]hiExport a sync_file with flags corresponding to the expected GPU usage via DMA_BUF_IOCTL_EXPORT_SYNC_FILE.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKfhj ubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(hSubmit rendering work which uses the dma-buf. The work should wait on the exported sync file before rendering and produce another sync_file when complete. h]h)}(hSubmit rendering work which uses the dma-buf. The work should wait on the exported sync file before rendering and produce another sync_file when complete.h]hSubmit rendering work which uses the dma-buf. The work should wait on the exported sync file before rendering and produce another sync_file when complete.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKihj ubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(hImport the rendering-complete sync_file into the dma-buf with flags corresponding to the GPU usage via DMA_BUF_IOCTL_IMPORT_SYNC_FILE. h]h)}(hImport the rendering-complete sync_file into the dma-buf with flags corresponding to the GPU usage via DMA_BUF_IOCTL_IMPORT_SYNC_FILE.h]hImport the rendering-complete sync_file into the dma-buf with flags corresponding to the GPU usage via DMA_BUF_IOCTL_IMPORT_SYNC_FILE.}(hj7 hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKmhj3 ubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]jSjTjUhjVjWuh1jlhj ubah}(h]h ]h"]h$]h&]uh1hhj hKfhjhhubh)}(hXPUnlike doing implicit synchronization via a GPU kernel driver's exec ioctl, the above is not a single atomic operation. If userspace wants to ensure ordering via these fences, it is the respnosibility of userspace to use locks or other mechanisms to ensure that no other context adds fences or submits work between steps 1 and 3 above.h]hXRUnlike doing implicit synchronization via a GPU kernel driver’s exec ioctl, the above is not a single atomic operation. If userspace wants to ensure ordering via these fences, it is the respnosibility of userspace to use locks or other mechanisms to ensure that no other context adds fences or submits work between steps 1 and 3 above.}(hjX hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKphjhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_buf_import_sync_file (C struct)c.dma_buf_import_sync_filehNtauh1jhjhhhjhNubj)}(hhh](j)}(hdma_buf_import_sync_fileh]j)}(hstruct dma_buf_import_sync_fileh](j)}(hjh]hstruct}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj| hhh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKyubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj| hhhj hKyubj )}(hdma_buf_import_sync_fileh]j )}(hjz h]hdma_buf_import_sync_file}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj| hhhj hKyubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjx hhhj hKyubah}(h]js ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj hKyhju hhubjA )}(hhh]h)}(h!Insert a sync_file into a dma-bufh]h!Insert a sync_file into a dma-buf}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhj hhubah}(h]h ]h"]h$]h&]uh1j@ hju hhhj hKyubeh}(h]h ](jstructeh"]h$]h&]ja jjb j jc j jd je jf uh1jhhhjhjhNubjh )}(hXp**Definition**:: struct dma_buf_import_sync_file { __u32 flags; __s32 fd; }; **Members** ``flags`` Read/write flags Must be DMA_BUF_SYNC_READ, DMA_BUF_SYNC_WRITE, or both. If DMA_BUF_SYNC_READ is set and DMA_BUF_SYNC_WRITE is not set, this inserts the sync_file as a read-only fence. Any subsequent implicitly synchronized writes to this dma-buf will wait on this fence but reads will not. If DMA_BUF_SYNC_WRITE is set, this inserts the sync_file as a write fence. All subsequent implicitly synchronized access to this dma-buf will wait on this fence. ``fd`` Sync file descriptorh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubh:}(hj hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhj ubj)}(hCstruct dma_buf_import_sync_file { __u32 flags; __s32 fd; };h]hCstruct dma_buf_import_sync_file { __u32 flags; __s32 fd; };}hj sbah}(h]h ]h"]h$]h&]jjuh1jh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhj ubh)}(h **Members**h]jr )}(hjh]hMembers}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhj ubj )}(hhh](j )}(hX``flags`` Read/write flags Must be DMA_BUF_SYNC_READ, DMA_BUF_SYNC_WRITE, or both. If DMA_BUF_SYNC_READ is set and DMA_BUF_SYNC_WRITE is not set, this inserts the sync_file as a read-only fence. Any subsequent implicitly synchronized writes to this dma-buf will wait on this fence but reads will not. If DMA_BUF_SYNC_WRITE is set, this inserts the sync_file as a write fence. All subsequent implicitly synchronized access to this dma-buf will wait on this fence. h](j )}(h ``flags``h]j)}(hj/h]hflags}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj-ubah}(h]h ]h"]h$]h&]uh1j h`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhj)ubj )}(hhh](h)}(hRead/write flagsh]hRead/write flags}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjEubh)}(h7Must be DMA_BUF_SYNC_READ, DMA_BUF_SYNC_WRITE, or both.h]h7Must be DMA_BUF_SYNC_READ, DMA_BUF_SYNC_WRITE, or both.}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjEubh)}(hIf DMA_BUF_SYNC_READ is set and DMA_BUF_SYNC_WRITE is not set, this inserts the sync_file as a read-only fence. Any subsequent implicitly synchronized writes to this dma-buf will wait on this fence but reads will not.h]hIf DMA_BUF_SYNC_READ is set and DMA_BUF_SYNC_WRITE is not set, this inserts the sync_file as a read-only fence. Any subsequent implicitly synchronized writes to this dma-buf will wait on this fence but reads will not.}(hjfhhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjEubh)}(hIf DMA_BUF_SYNC_WRITE is set, this inserts the sync_file as a write fence. All subsequent implicitly synchronized access to this dma-buf will wait on this fence.h]hIf DMA_BUF_SYNC_WRITE is set, this inserts the sync_file as a write fence. All subsequent implicitly synchronized access to this dma-buf will wait on this fence.}(hjuhhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjEubeh}(h]h ]h"]h$]h&]uh1j hj)ubeh}(h]h ]h"]h$]h&]uh1j hjDhKhj&ubj )}(h``fd`` Sync file descriptorh](j )}(h``fd``h]j)}(hjh]hfd}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjubj )}(hhh]h)}(hSync file descriptorh]hSync file descriptor}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhj&ubeh}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhjhNubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjhhubh)}(hXbUserspace can perform a DMA_BUF_IOCTL_IMPORT_SYNC_FILE to insert a sync_file into a dma-buf for the purposes of implicit synchronization with other dma-buf consumers. This allows clients using explicitly synchronized APIs such as Vulkan to inter-op with dma-buf consumers which expect implicit synchronization such as OpenGL or most media drivers/video.h]hXbUserspace can perform a DMA_BUF_IOCTL_IMPORT_SYNC_FILE to insert a sync_file into a dma-buf for the purposes of implicit synchronization with other dma-buf consumers. This allows clients using explicitly synchronized APIs such as Vulkan to inter-op with dma-buf consumers which expect implicit synchronization such as OpenGL or most media drivers/video.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh`/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:131: ./include/uapi/linux/dma-buf.hhKhjhhubeh}(h]j-ah ]h"]dma buffer ioctlsah$]h&]uh1hhjhhhhhKjxKubh)}(hhh](h)}(hDMA-BUF locking conventionh]hDMA-BUF locking convention}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhKubh)}(hIn order to avoid deadlock situations between dma-buf exports and importers, all dma-buf API users must follow the common dma-buf locking convention.h]hIn order to avoid deadlock situations between dma-buf exports and importers, all dma-buf API users must follow the common dma-buf locking convention.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjhhubh)}(hConvention for importersh]hConvention for importers}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjhhubjm)}(hhh](j)}(hImporters must hold the dma-buf reservation lock when calling these functions: - dma_buf_pin() - dma_buf_unpin() - dma_buf_map_attachment() - dma_buf_unmap_attachment() - dma_buf_vmap() - dma_buf_vunmap() h](h)}(hNImporters must hold the dma-buf reservation lock when calling these functions:h]hNImporters must hold the dma-buf reservation lock when calling these functions:}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhj7ubh)}(h~- dma_buf_pin() - dma_buf_unpin() - dma_buf_map_attachment() - dma_buf_unmap_attachment() - dma_buf_vmap() - dma_buf_vunmap() h]h)}(hhh](j)}(h dma_buf_pin()h]h)}(hjSh]h dma_buf_pin()}(hjUhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjQubah}(h]h ]h"]h$]h&]uh1jhjNubj)}(hdma_buf_unpin()h]h)}(hjkh]hdma_buf_unpin()}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjiubah}(h]h ]h"]h$]h&]uh1jhjNubj)}(hdma_buf_map_attachment()h]h)}(hjh]hdma_buf_map_attachment()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhjNubj)}(hdma_buf_unmap_attachment()h]h)}(hjh]hdma_buf_unmap_attachment()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhjNubj)}(hdma_buf_vmap()h]h)}(hjh]hdma_buf_vmap()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhjNubj)}(hdma_buf_vunmap() h]h)}(hdma_buf_vunmap()h]hdma_buf_vunmap()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhjNubeh}(h]h ]h"]h$]h&]jRjSuh1hhjbhMhjJubah}(h]h ]h"]h$]h&]uh1hhjbhMhj7ubeh}(h]h ]h"]h$]h&]uh1jhj4ubj)}(hXImporters must not hold the dma-buf reservation lock when calling these functions: - dma_buf_attach() - dma_buf_dynamic_attach() - dma_buf_detach() - dma_buf_export() - dma_buf_fd() - dma_buf_get() - dma_buf_put() - dma_buf_mmap() - dma_buf_begin_cpu_access() - dma_buf_end_cpu_access() - dma_buf_map_attachment_unlocked() - dma_buf_unmap_attachment_unlocked() - dma_buf_vmap_unlocked() - dma_buf_vunmap_unlocked() h](h)}(hRImporters must not hold the dma-buf reservation lock when calling these functions:h]hRImporters must not hold the dma-buf reservation lock when calling these functions:}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubh)}(hXL- dma_buf_attach() - dma_buf_dynamic_attach() - dma_buf_detach() - dma_buf_export() - dma_buf_fd() - dma_buf_get() - dma_buf_put() - dma_buf_mmap() - dma_buf_begin_cpu_access() - dma_buf_end_cpu_access() - dma_buf_map_attachment_unlocked() - dma_buf_unmap_attachment_unlocked() - dma_buf_vmap_unlocked() - dma_buf_vunmap_unlocked() h]h)}(hhh](j)}(hdma_buf_attach()h]h)}(hjh]hdma_buf_attach()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(hdma_buf_dynamic_attach()h]h)}(hj(h]hdma_buf_dynamic_attach()}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhj&ubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(hdma_buf_detach()h]h)}(hj@h]hdma_buf_detach()}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhj>ubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(hdma_buf_export()h]h)}(hjXh]hdma_buf_export()}(hjZhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjVubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(h dma_buf_fd()h]h)}(hjph]h dma_buf_fd()}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjnubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(h dma_buf_get()h]h)}(hjh]h dma_buf_get()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(h dma_buf_put()h]h)}(hjh]h dma_buf_put()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(hdma_buf_mmap()h]h)}(hjh]hdma_buf_mmap()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(hdma_buf_begin_cpu_access()h]h)}(hjh]hdma_buf_begin_cpu_access()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(hdma_buf_end_cpu_access()h]h)}(hjh]hdma_buf_end_cpu_access()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(h!dma_buf_map_attachment_unlocked()h]h)}(hjh]h!dma_buf_map_attachment_unlocked()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(h#dma_buf_unmap_attachment_unlocked()h]h)}(hjh]h#dma_buf_unmap_attachment_unlocked()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(hdma_buf_vmap_unlocked()h]h)}(hj0h]hdma_buf_vmap_unlocked()}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhj.ubah}(h]h ]h"]h$]h&]uh1jhj ubj)}(hdma_buf_vunmap_unlocked() h]h)}(hdma_buf_vunmap_unlocked()h]hdma_buf_vunmap_unlocked()}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjFubah}(h]h ]h"]h$]h&]uh1jhj ubeh}(h]h ]h"]h$]h&]jRjSuh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjubeh}(h]h ]h"]h$]h&]uh1jhj4ubeh}(h]h ]h"]h$]h&]jSjTjUhjVjWuh1jlhjhhhNhNubh)}(hConvention for exportersh]hConvention for exporters}(hjwhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjhhubjm)}(hhh](j)}(hXThese :c:type:`dma_buf_ops` callbacks are invoked with unlocked dma-buf reservation and exporter can take the lock: - :c:type:`dma_buf_ops.attach\(\) ` - :c:type:`dma_buf_ops.detach\(\) ` - :c:type:`dma_buf_ops.release\(\) ` - :c:type:`dma_buf_ops.begin_cpu_access\(\) ` - :c:type:`dma_buf_ops.end_cpu_access\(\) ` - :c:type:`dma_buf_ops.mmap\(\) ` h](h)}(hsThese :c:type:`dma_buf_ops` callbacks are invoked with unlocked dma-buf reservation and exporter can take the lock:h](hThese }(hjhhhNhNubh)}(h:c:type:`dma_buf_ops`h]j)}(hjh]h dma_buf_ops}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarn c:parent_keysphinx.domains.c LookupKey)}data]sbj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubhX callbacks are invoked with unlocked dma-buf reservation and exporter can take the lock:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMhjubh)}(hX7- :c:type:`dma_buf_ops.attach\(\) ` - :c:type:`dma_buf_ops.detach\(\) ` - :c:type:`dma_buf_ops.release\(\) ` - :c:type:`dma_buf_ops.begin_cpu_access\(\) ` - :c:type:`dma_buf_ops.end_cpu_access\(\) ` - :c:type:`dma_buf_ops.mmap\(\) ` h]h)}(hhh](j)}(h.:c:type:`dma_buf_ops.attach\(\) `h]h)}(hjh]h)}(h.:c:type:`dma_buf_ops.attach\(\) `h]j)}(hjh]hdma_buf_ops.attach()}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(h.:c:type:`dma_buf_ops.detach\(\) `h]h)}(hjh]h)}(h.:c:type:`dma_buf_ops.detach\(\) `h]j)}(hj h]hdma_buf_ops.detach()}(hj hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1hhj'hMhjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(h/:c:type:`dma_buf_ops.release\(\) `h]h)}(hj6h]h)}(h/:c:type:`dma_buf_ops.release\(\) `h]j)}(hj=h]hdma_buf_ops.release()}(hj?hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj;ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhj8ubah}(h]h ]h"]h$]h&]uh1hhjZhMhj4ubah}(h]h ]h"]h$]h&]uh1jhjubj)}(h8:c:type:`dma_buf_ops.begin_cpu_access\(\) `h]h)}(hjih]h)}(h8:c:type:`dma_buf_ops.begin_cpu_access\(\) `h]j)}(hjph]hdma_buf_ops.begin_cpu_access()}(hjrhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjnubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjkubah}(h]h ]h"]h$]h&]uh1hhjhMhjgubah}(h]h ]h"]h$]h&]uh1jhjubj)}(h6:c:type:`dma_buf_ops.end_cpu_access\(\) `h]h)}(hjh]h)}(h6:c:type:`dma_buf_ops.end_cpu_access\(\) `h]j)}(hjh]hdma_buf_ops.end_cpu_access()}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(h-:c:type:`dma_buf_ops.mmap\(\) ` h]h)}(h,:c:type:`dma_buf_ops.mmap\(\) `h]h)}(h,:c:type:`dma_buf_ops.mmap\(\) `h]j)}(hjh]hdma_buf_ops.mmap()}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]jRjSuh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjubeh}(h]h ]h"]h$]h&]uh1jhjubj)}(hXThese :c:type:`dma_buf_ops` callbacks are invoked with locked dma-buf reservation and exporter can't take the lock: - :c:type:`dma_buf_ops.pin\(\) ` - :c:type:`dma_buf_ops.unpin\(\) ` - :c:type:`dma_buf_ops.map_dma_buf\(\) ` - :c:type:`dma_buf_ops.unmap_dma_buf\(\) ` - :c:type:`dma_buf_ops.vmap\(\) ` - :c:type:`dma_buf_ops.vunmap\(\) ` h](h)}(hsThese :c:type:`dma_buf_ops` callbacks are invoked with locked dma-buf reservation and exporter can't take the lock:h](hThese }(hjhhhNhNubh)}(h:c:type:`dma_buf_ops`h]j)}(hj!h]h dma_buf_ops}(hj#hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubhZ callbacks are invoked with locked dma-buf reservation and exporter can’t take the lock:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj>hMhjubh)}(hX,- :c:type:`dma_buf_ops.pin\(\) ` - :c:type:`dma_buf_ops.unpin\(\) ` - :c:type:`dma_buf_ops.map_dma_buf\(\) ` - :c:type:`dma_buf_ops.unmap_dma_buf\(\) ` - :c:type:`dma_buf_ops.vmap\(\) ` - :c:type:`dma_buf_ops.vunmap\(\) ` h]h)}(hhh](j)}(h+:c:type:`dma_buf_ops.pin\(\) `h]h)}(hjRh]h)}(h+:c:type:`dma_buf_ops.pin\(\) `h]j)}(hjYh]hdma_buf_ops.pin()}(hj[hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjWubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjTubah}(h]h ]h"]h$]h&]uh1hhjvhMhjPubah}(h]h ]h"]h$]h&]uh1jhjMubj)}(h-:c:type:`dma_buf_ops.unpin\(\) `h]h)}(hjh]h)}(h-:c:type:`dma_buf_ops.unpin\(\) `h]j)}(hjh]hdma_buf_ops.unpin()}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1jhjMubj)}(h3:c:type:`dma_buf_ops.map_dma_buf\(\) `h]h)}(hjh]h)}(h3:c:type:`dma_buf_ops.map_dma_buf\(\) `h]j)}(hjh]hdma_buf_ops.map_dma_buf()}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1jhjMubj)}(h5:c:type:`dma_buf_ops.unmap_dma_buf\(\) `h]h)}(hjh]h)}(h5:c:type:`dma_buf_ops.unmap_dma_buf\(\) `h]j)}(hjh]hdma_buf_ops.unmap_dma_buf()}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1jhjMubj)}(h,:c:type:`dma_buf_ops.vmap\(\) `h]h)}(hjh]h)}(h,:c:type:`dma_buf_ops.vmap\(\) `h]j)}(hj%h]hdma_buf_ops.vmap()}(hj'hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj#ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhj ubah}(h]h ]h"]h$]h&]uh1hhjBhMhjubah}(h]h ]h"]h$]h&]uh1jhjMubj)}(h/:c:type:`dma_buf_ops.vunmap\(\) ` h]h)}(h.:c:type:`dma_buf_ops.vunmap\(\) `h]h)}(h.:c:type:`dma_buf_ops.vunmap\(\) `h]j)}(hjYh]hdma_buf_ops.vunmap()}(hj[hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjWubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjSubah}(h]h ]h"]h$]h&]uh1hhjvhMhjOubah}(h]h ]h"]h$]h&]uh1jhjMubeh}(h]h ]h"]h$]h&]jRjSuh1hhjvhMhjIubah}(h]h ]h"]h$]h&]uh1hhjvhMhjubeh}(h]h ]h"]h$]h&]uh1jhjubj)}(hrExporters must hold the dma-buf reservation lock when calling these functions: - dma_buf_invalidate_mappings() h](h)}(hNExporters must hold the dma-buf reservation lock when calling these functions:h]hNExporters must hold the dma-buf reservation lock when calling these functions:}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubh)}(h!- dma_buf_invalidate_mappings() h]h)}(hhh]j)}(hdma_buf_invalidate_mappings() h]h)}(hdma_buf_invalidate_mappings()h]hdma_buf_invalidate_mappings()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:136: ./drivers/dma-buf/dma-buf.chMhjubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]jRjSuh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjubeh}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]jSjTjUhjVjWuh1jlhjhhhNhNubeh}(h]dma-buf-locking-conventionah ]h"]dma-buf locking conventionah$]h&]uh1hhjhhhhhKubh)}(hhh](h)}(h)Kernel Functions and Structures Referenceh]h)Kernel Functions and Structures Reference}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhKubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_export (C function)c.dma_buf_exporthNtauh1jhjhhhNhNubj)}(hhh](j)}(hLstruct dma_buf * dma_buf_export (const struct dma_buf_export_info *exp_info)h]j)}(hJstruct dma_buf *dma_buf_export(const struct dma_buf_export_info *exp_info)h](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hj1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj.ubah}(h]h ]h"]h$]h&] refdomainjreftype identifier reftargetj3modnameN classnameNjj)}j]j ASTIdentifier)}jGdma_buf_exportsbc.dma_buf_exportasbuh1hhjhhhjhMubj)}(h h]h }(hjUhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubhdesc_sig_punctuation)}(h*h]h*}(hjehhhNhNubah}(h]h ]pah"]h$]h&]uh1jchjhhhjhMubj )}(hdma_buf_exporth]j )}(hjRh]hdma_buf_export}(hjxhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjtubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubhdesc_parameterlist)}(h,(const struct dma_buf_export_info *exp_info)h]hdesc_parameter)}(h*const struct dma_buf_export_info *exp_infoh](j)}(hconsth]hconst}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_buf_export_infoh]hdma_buf_export_info}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jPc.dma_buf_exportasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hexp_infoh]hexp_info}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj hhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(hCreates a new dma_buf, and associates an anon file with this buffer, so it can be exported. Also connect the allocator specific data and ops to the buffer. Additionally, provide a name string for exporter; useful in debugging.h]hCreates a new dma_buf, and associates an anon file with this buffer, so it can be exported. Also connect the allocator specific data and ops to the buffer. Additionally, provide a name string for exporter; useful in debugging.}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj1hhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jLjc jLjd je jf uh1jhhhjhNhNubjh )}(hXD**Parameters** ``const struct dma_buf_export_info *exp_info`` [in] holds all the export related information provided by the exporter. see :c:type:`struct dma_buf_export_info ` for further details. **Description** Returns, on success, a newly created struct dma_buf object, which wraps the supplied private data and operations for struct dma_buf_ops. On either missing ops, or error in allocating struct dma_buf, will return negative error. For most cases the easiest way to create **exp_info** is through the ``DEFINE_DMA_BUF_EXPORT_INFO`` macro.h](h)}(h**Parameters**h]jr )}(hjVh]h Parameters}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjTubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjPubj )}(hhh]j )}(h``const struct dma_buf_export_info *exp_info`` [in] holds all the export related information provided by the exporter. see :c:type:`struct dma_buf_export_info ` for further details. h](j )}(h.``const struct dma_buf_export_info *exp_info``h]j)}(hjuh]h*const struct dma_buf_export_info *exp_info}(hjwhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjsubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjoubj )}(hhh]h)}(h[in] holds all the export related information provided by the exporter. see :c:type:`struct dma_buf_export_info ` for further details.h](hO[in] holds all the export related information provided by the exporter. see }(hjhhhNhNubh)}(h::c:type:`struct dma_buf_export_info `h]j)}(hjh]hstruct dma_buf_export_info}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_export_infouh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjubh for further details.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjoubeh}(h]h ]h"]h$]h&]uh1j hjhMhjlubah}(h]h ]h"]h$]h&]uh1j hjPubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjPubh)}(hReturns, on success, a newly created struct dma_buf object, which wraps the supplied private data and operations for struct dma_buf_ops. On either missing ops, or error in allocating struct dma_buf, will return negative error.h]hReturns, on success, a newly created struct dma_buf object, which wraps the supplied private data and operations for struct dma_buf_ops. On either missing ops, or error in allocating struct dma_buf, will return negative error.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjPubh)}(hjFor most cases the easiest way to create **exp_info** is through the ``DEFINE_DMA_BUF_EXPORT_INFO`` macro.h](h)For most cases the easiest way to create }(hjhhhNhNubjr )}(h **exp_info**h]hexp_info}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh is through the }(hjhhhNhNubj)}(h``DEFINE_DMA_BUF_EXPORT_INFO``h]hDEFINE_DMA_BUF_EXPORT_INFO}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh macro.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjPubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_fd (C function) c.dma_buf_fdhNtauh1jhjhhhNhNubj)}(hhh](j)}(h2int dma_buf_fd (struct dma_buf *dmabuf, int flags)h]j)}(h1int dma_buf_fd(struct dma_buf *dmabuf, int flags)h](hdesc_sig_keyword_type)}(hinth]hint}(hjNhhhNhNubah}(h]h ]ktah"]h$]h&]uh1jLhjHhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMubj)}(h h]h }(hj^hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjHhhhj]hMubj )}(h dma_buf_fdh]j )}(h dma_buf_fdh]h dma_buf_fd}(hjphhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjlubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjHhhhj]hMubj)}(h#(struct dma_buf *dmabuf, int flags)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjrsb c.dma_buf_fdasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hdmabufh]hdmabuf}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h int flagsh](jM)}(hinth]hint}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hflagsh]hflags}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjHhhhj]hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjDhhhj]hMubah}(h]j?ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj]hMhjAhhubjA )}(hhh]h)}(h6returns a file descriptor for the given struct dma_bufh]h6returns a file descriptor for the given struct dma_buf}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjAhhubah}(h]h ]h"]h$]h&]uh1j@ hjAhhhj]hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j\jc j\jd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_buf *dmabuf`` [in] pointer to dma_buf for which fd is required. ``int flags`` [in] flags to give to fd **Description** On success, returns an associated 'fd'. Else, returns error.h](h)}(h**Parameters**h]jr )}(hjfh]h Parameters}(hjhhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjdubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj`ubj )}(hhh](j )}(hP``struct dma_buf *dmabuf`` [in] pointer to dma_buf for which fd is required. h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjh]hstruct dma_buf *dmabuf}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjubj )}(hhh]h)}(h4[in] pointer to dma_buf for which fd is required.h]h4[in] pointer to dma_buf for which fd is required.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhj|ubj )}(h*``int flags`` [in] flags to give to fd h](j )}(h ``int flags``h]j)}(hjh]h int flags}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjubj )}(hhh]h)}(hn] flags to give to fdh]hn] flags to give to fd}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhj|ubeh}(h]h ]h"]h$]h&]uh1j hj`ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj`ubh)}(hhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj:hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM'ubj)}(h h]h }(hjMhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj:hhhjLhM'ubj )}(hdma_buf_fd_installh]j )}(hdma_buf_fd_installh]hdma_buf_fd_install}(hj_hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj[ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj:hhhjLhM'ubj)}(h (struct dma_buf *dmabuf, int fd)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hj{hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjwubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjasbc.dma_buf_fd_installasbuh1hhjwubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjwubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjwubj )}(hdmabufh]hdmabuf}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjwubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjsubj)}(hint fdh](jM)}(hinth]hint}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hfdh]hfd}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjsubeh}(h]h ]h"]h$]h&]jjuh1jhj:hhhjLhM'ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj6hhhjLhM'ubah}(h]j1ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjLhM'hj3hhubjA )}(hhh]h)}(h#install a reserved fd for a dma-bufh]h#install a reserved fd for a dma-buf}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM'hj0hhubah}(h]h ]h"]h$]h&]uh1j@ hj3hhhjLhM'ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jKjc jKjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_buf *dmabuf`` [in] pointer to dma_buf ``int fd`` [in] fd reserved with get_unused_fd_flags() **Description** Publishes a previously reserved fd into the caller's fd table. Must only be called after all fallible work (e.g. copy_to_user) has succeeded, as it cannot be undone safely once called. The caller is responsible for having emitted the trace event (via dma_buf_fd() or get_unused_fd_flags() + this function) before calling this.h](h)}(h**Parameters**h]jr )}(hjUh]h Parameters}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjSubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM+hjOubj )}(hhh](j )}(h6``struct dma_buf *dmabuf`` [in] pointer to dma_buf h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjth]hstruct dma_buf *dmabuf}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjrubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM(hjnubj )}(hhh]h)}(h[in] pointer to dma_bufh]h[in] pointer to dma_buf}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM(hjubah}(h]h ]h"]h$]h&]uh1j hjnubeh}(h]h ]h"]h$]h&]uh1j hjhM(hjkubj )}(h:``int fd`` [in] fd reserved with get_unused_fd_flags() h](j )}(h ``int fd``h]j)}(hjh]hint fd}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM)hjubj )}(hhh]h)}(h.[in] fd reserved with get_unused_fd_flags()h]h.[in] fd reserved with get_unused_fd_flags()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM)hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhM)hjkubeh}(h]h ]h"]h$]h&]uh1j hjOubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM+hjOubh)}(hPublishes a previously reserved fd into the caller's fd table. Must only be called after all fallible work (e.g. copy_to_user) has succeeded, as it cannot be undone safely once called.h]hPublishes a previously reserved fd into the caller’s fd table. Must only be called after all fallible work (e.g. copy_to_user) has succeeded, as it cannot be undone safely once called.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM*hjOubh)}(hThe caller is responsible for having emitted the trace event (via dma_buf_fd() or get_unused_fd_flags() + this function) before calling this.h]hThe caller is responsible for having emitted the trace event (via dma_buf_fd() or get_unused_fd_flags() + this function) before calling this.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM.hjOubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_get (C function) c.dma_buf_gethNtauh1jhjhhhNhNubj)}(hhh](j)}(h%struct dma_buf * dma_buf_get (int fd)h]j)}(h#struct dma_buf *dma_buf_get(int fd)h](j)}(hjh]hstruct}(hj<hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj8hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM;ubj)}(h h]h }(hjJhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj8hhhjIhM;ubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hj[hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjXubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj]modnameN classnameNjj)}j]jO)}jG dma_buf_getsb c.dma_buf_getasbuh1hhj8hhhjIhM;ubj)}(h h]h }(hj|hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj8hhhjIhM;ubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj8hhhjIhM;ubj )}(h dma_buf_geth]j )}(hjyh]h dma_buf_get}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj8hhhjIhM;ubj)}(h(int fd)h]j)}(hint fdh](jM)}(hinth]hint}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hfdh]hfd}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhj8hhhjIhM;ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj4hhhjIhM;ubah}(h]j/ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjIhM;hj1hhubjA )}(hhh]h)}(h+returns the struct dma_buf related to an fdh]h+returns the struct dma_buf related to an fd}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM;hjhhubah}(h]h ]h"]h$]h&]uh1j@ hj1hhhjIhM;ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``int fd`` [in] fd associated with the struct dma_buf to be returned **Description** On success, returns the struct dma_buf associated with an fd; uses file's refcounting done by fget to increase refcount. returns ERR_PTR otherwise.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM?hjubj )}(hhh]j )}(hH``int fd`` [in] fd associated with the struct dma_buf to be returned h](j )}(h ``int fd``h]j)}(hj=h]hint fd}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj;ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM<hj7ubj )}(hhh]h)}(h<[in] fd associated with the struct dma_buf to be returnedh]h<[in] fd associated with the struct dma_buf to be returned}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjRhM<hjSubah}(h]h ]h"]h$]h&]uh1j hj7ubeh}(h]h ]h"]h$]h&]uh1j hjRhM<hj4ubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjxh]h Description}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjvubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM>hjubh)}(hOn success, returns the struct dma_buf associated with an fd; uses file's refcounting done by fget to increase refcount. returns ERR_PTR otherwise.h]hOn success, returns the struct dma_buf associated with an fd; uses file’s refcounting done by fget to increase refcount. returns ERR_PTR otherwise.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM=hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_put (C function) c.dma_buf_puthNtauh1jhjhhhNhNubj)}(hhh](j)}(h)void dma_buf_put (struct dma_buf *dmabuf)h]j)}(h(void dma_buf_put(struct dma_buf *dmabuf)h](jM)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMZubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMZubj )}(h dma_buf_puth]j )}(h dma_buf_puth]h dma_buf_put}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMZubj)}(h(struct dma_buf *dmabuf)h]j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsb c.dma_buf_putasbuh1hhjubj)}(h h]h }(hj8hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjFhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hdmabufh]hdmabuf}(hjShhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMZubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMZubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMZhjhhubjA )}(hhh]h)}(h decreases refcount of the bufferh]h decreases refcount of the buffer}(hj}hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMZhjzhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMZubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_buf *dmabuf`` [in] buffer to reduce refcount of **Description** Uses file's refcounting done implicitly by fput(). If, as a result of this call, the refcount becomes 0, the 'release' file operation related to this fd is called. It calls :c:type:`dma_buf_ops.release ` vfunc in turn, and frees the memory allocated for dmabuf when exported.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM^hjubj )}(hhh]j )}(h@``struct dma_buf *dmabuf`` [in] buffer to reduce refcount of h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjh]hstruct dma_buf *dmabuf}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM[hjubj )}(hhh]h)}(h$[in] buffer to reduce refcount ofh]h$[in] buffer to reduce refcount of}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM[hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhM[hjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM]hjubh)}(h2Uses file's refcounting done implicitly by fput().h]h4Uses file’s refcounting done implicitly by fput().}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM\hjubh)}(hIf, as a result of this call, the refcount becomes 0, the 'release' file operation related to this fd is called. It calls :c:type:`dma_buf_ops.release ` vfunc in turn, and frees the memory allocated for dmabuf when exported.h](h~If, as a result of this call, the refcount becomes 0, the ‘release’ file operation related to this fd is called. It calls }(hjhhhNhNubh)}(h+:c:type:`dma_buf_ops.release `h]j)}(hj(h]hdma_buf_ops.release}(hj*hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj&ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM^hjubhH vfunc in turn, and frees the memory allocated for dmabuf when exported.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjEhM^hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_buf_dynamic_attach (C function)c.dma_buf_dynamic_attachhNtauh1jhjhhhNhNubj)}(hhh](j)}(hstruct dma_buf_attachment * dma_buf_dynamic_attach (struct dma_buf *dmabuf, struct device *dev, const struct dma_buf_attach_ops *importer_ops, void *importer_priv)h]j)}(hstruct dma_buf_attachment *dma_buf_dynamic_attach(struct dma_buf *dmabuf, struct device *dev, const struct dma_buf_attach_ops *importer_ops, void *importer_priv)h](j)}(hjh]hstruct}(hjphhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMubj)}(h h]h }(hj~hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjlhhhj}hMubh)}(hhh]j )}(hdma_buf_attachmenth]hdma_buf_attachment}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGdma_buf_dynamic_attachsbc.dma_buf_dynamic_attachasbuh1hhjlhhhj}hMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjlhhhj}hMubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjlhhhj}hMubj )}(hdma_buf_dynamic_attachh]j )}(hjh]hdma_buf_dynamic_attach}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjlhhhj}hMubj)}(hp(struct dma_buf *dmabuf, struct device *dev, const struct dma_buf_attach_ops *importer_ops, void *importer_priv)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]jc.dma_buf_dynamic_attachasbuh1hhjubj)}(h h]h }(hj&hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj4hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hdmabufh]hdmabuf}(hjAhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hstruct device *devh](j)}(hjh]hstruct}(hjZhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjVubj)}(h h]h }(hjghhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjVubh)}(hhh]j )}(hdeviceh]hdevice}(hjxhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjuubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjzmodnameN classnameNjj)}j]jc.dma_buf_dynamic_attachasbuh1hhjVubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjVubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjVubj )}(hdevh]hdev}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjVubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h-const struct dma_buf_attach_ops *importer_opsh](j)}(hjh]hconst}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_buf_attach_opsh]hdma_buf_attach_ops}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]jc.dma_buf_dynamic_attachasbuh1hhjubj)}(h h]h }(hj! hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj/ hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(h importer_opsh]h importer_ops}(hj< hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hvoid *importer_privh](jM)}(hvoidh]hvoid}(hjU hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjQ ubj)}(h h]h }(hjc hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjQ ubjd)}(hjgh]h*}(hjq hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjQ ubj )}(h importer_privh]h importer_priv}(hj~ hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjQ ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjlhhhj}hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhhj}hMubah}(h]jcah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj}hMhjehhubjA )}(hhh]h)}(h,Add the device to dma_buf's attachments listh]h.Add the device to dma_buf’s attachments list}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj hhubah}(h]h ]h"]h$]h&]uh1j@ hjehhhj}hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j jc j jd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_buf *dmabuf`` [in] buffer to attach device to. ``struct device *dev`` [in] device to be attached. ``const struct dma_buf_attach_ops *importer_ops`` [in] importer operations for the attachment ``void *importer_priv`` [in] importer private pointer for the attachment **Description** Returns struct dma_buf_attachment pointer for this attachment. Attachments must be cleaned up by calling dma_buf_detach(). Optionally this calls :c:type:`dma_buf_ops.attach ` to allow device-specific attach functionality. A pointer to newly created :c:type:`dma_buf_attachment` on success, or a negative error code wrapped into a pointer on failure. Note that this can fail if the backing storage of **dmabuf** is in a place not accessible to **dev**, and cannot be moved to a more suitable place. This is indicated with the error code -EBUSY.h](h)}(h**Parameters**h]jr )}(hj h]h Parameters}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj ubj )}(hhh](j )}(h?``struct dma_buf *dmabuf`` [in] buffer to attach device to. h](j )}(h``struct dma_buf *dmabuf``h]j)}(hj h]hstruct dma_buf *dmabuf}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj ubj )}(hhh]h)}(h#[in] buffer to attach device to.h]h#[in] buffer to attach device to.}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hMhj ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj hMhj ubj )}(h6``struct device *dev`` [in] device to be attached. h](j )}(h``struct device *dev``h]j)}(hj"!h]hstruct device *dev}(hj$!hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj !ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj!ubj )}(hhh]h)}(h[in] device to be attached.h]h[in] device to be attached.}(hj;!hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj7!hMhj8!ubah}(h]h ]h"]h$]h&]uh1j hj!ubeh}(h]h ]h"]h$]h&]uh1j hj7!hMhj ubj )}(ha``const struct dma_buf_attach_ops *importer_ops`` [in] importer operations for the attachment h](j )}(h1``const struct dma_buf_attach_ops *importer_ops``h]j)}(hj[!h]h-const struct dma_buf_attach_ops *importer_ops}(hj]!hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjY!ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjU!ubj )}(hhh]h)}(h.[in] importer operations for the attachmenth]h.[in] importer operations for the attachment}(hjt!hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjp!hMhjq!ubah}(h]h ]h"]h$]h&]uh1j hjU!ubeh}(h]h ]h"]h$]h&]uh1j hjp!hMhj ubj )}(hL``void *importer_priv`` [in] importer private pointer for the attachment h](j )}(h``void *importer_priv``h]j)}(hj!h]hvoid *importer_priv}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj!ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj!ubj )}(hhh]h)}(h3[in] importer private pointer for the attachmenth]h3[in] importer private pointer for the attachment}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj!hMhj!ubah}(h]h ]h"]h$]h&]uh1j hj!ubeh}(h]h ]h"]h$]h&]uh1j hj!hMhj ubeh}(h]h ]h"]h$]h&]uh1j hj ubh)}(h**Description**h]jr )}(hj!h]h Description}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj!ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj ubh)}(hzReturns struct dma_buf_attachment pointer for this attachment. Attachments must be cleaned up by calling dma_buf_detach().h]hzReturns struct dma_buf_attachment pointer for this attachment. Attachments must be cleaned up by calling dma_buf_detach().}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj ubh)}(hoOptionally this calls :c:type:`dma_buf_ops.attach ` to allow device-specific attach functionality.h](hOptionally this calls }(hj!hhhNhNubh)}(h*:c:type:`dma_buf_ops.attach `h]j)}(hj!h]hdma_buf_ops.attach}(hj"hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj!ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj!ubh/ to allow device-specific attach functionality.}(hj!hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj"hMhj ubh)}(hA pointer to newly created :c:type:`dma_buf_attachment` on success, or a negative error code wrapped into a pointer on failure.h](hA pointer to newly created }(hj&"hhhNhNubh)}(h:c:type:`dma_buf_attachment`h]j)}(hj0"h]hdma_buf_attachment}(hj2"hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj."ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_attachmentuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj&"ubhH on success, or a negative error code wrapped into a pointer on failure.}(hj&"hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjM"hMhj ubh)}(hNote that this can fail if the backing storage of **dmabuf** is in a place not accessible to **dev**, and cannot be moved to a more suitable place. This is indicated with the error code -EBUSY.h](h2Note that this can fail if the backing storage of }(hjX"hhhNhNubjr )}(h **dmabuf**h]hdmabuf}(hj`"hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjX"ubh! is in a place not accessible to }(hjX"hhhNhNubjr )}(h**dev**h]hdev}(hjr"hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjX"ubh], and cannot be moved to a more suitable place. This is indicated with the error code -EBUSY.}(hjX"hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_attach (C function)c.dma_buf_attachhNtauh1jhjhhhNhNubj)}(hhh](j)}(hWstruct dma_buf_attachment * dma_buf_attach (struct dma_buf *dmabuf, struct device *dev)h]j)}(hUstruct dma_buf_attachment *dma_buf_attach(struct dma_buf *dmabuf, struct device *dev)h](j)}(hjh]hstruct}(hj"hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj"hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM2ubj)}(h h]h }(hj"hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj"hhhj"hM2ubh)}(hhh]j )}(hdma_buf_attachmenth]hdma_buf_attachment}(hj"hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj"ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj"modnameN classnameNjj)}j]jO)}jGdma_buf_attachsbc.dma_buf_attachasbuh1hhj"hhhj"hM2ubj)}(h h]h }(hj"hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj"hhhj"hM2ubjd)}(hjgh]h*}(hj"hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj"hhhj"hM2ubj )}(hdma_buf_attachh]j )}(hj"h]hdma_buf_attach}(hj #hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj#ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj"hhhj"hM2ubj)}(h,(struct dma_buf *dmabuf, struct device *dev)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hj%#hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj!#ubj)}(h h]h }(hj2#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj!#ubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hjC#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj@#ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjE#modnameN classnameNjj)}j]j"c.dma_buf_attachasbuh1hhj!#ubj)}(h h]h }(hja#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj!#ubjd)}(hjgh]h*}(hjo#hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj!#ubj )}(hdmabufh]hdmabuf}(hj|#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj!#ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj#ubj)}(hstruct device *devh](j)}(hjh]hstruct}(hj#hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj#ubj)}(h h]h }(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj#ubh)}(hhh]j )}(hdeviceh]hdevice}(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj#ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj#modnameN classnameNjj)}j]j"c.dma_buf_attachasbuh1hhj#ubj)}(h h]h }(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj#ubjd)}(hjgh]h*}(hj#hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj#ubj )}(hdevh]hdev}(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj#ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj#ubeh}(h]h ]h"]h$]h&]jjuh1jhj"hhhj"hM2ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj"hhhj"hM2ubah}(h]j"ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj"hM2hj"hhubjA )}(hhh]h)}(h"Wrapper for dma_buf_dynamic_attachh]h"Wrapper for dma_buf_dynamic_attach}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM2hj$hhubah}(h]h ]h"]h$]h&]uh1j@ hj"hhhj"hM2ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j.$jc j.$jd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_buf *dmabuf`` [in] buffer to attach device to. ``struct device *dev`` [in] device to be attached. **Description** Wrapper to call dma_buf_dynamic_attach() for drivers which still use a static mapping.h](h)}(h**Parameters**h]jr )}(hj8$h]h Parameters}(hj:$hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj6$ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM6hj2$ubj )}(hhh](j )}(h?``struct dma_buf *dmabuf`` [in] buffer to attach device to. h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjW$h]hstruct dma_buf *dmabuf}(hjY$hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjU$ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM3hjQ$ubj )}(hhh]h)}(h#[in] buffer to attach device to.h]h#[in] buffer to attach device to.}(hjp$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjl$hM3hjm$ubah}(h]h ]h"]h$]h&]uh1j hjQ$ubeh}(h]h ]h"]h$]h&]uh1j hjl$hM3hjN$ubj )}(h6``struct device *dev`` [in] device to be attached. h](j )}(h``struct device *dev``h]j)}(hj$h]hstruct device *dev}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj$ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM4hj$ubj )}(hhh]h)}(h[in] device to be attached.h]h[in] device to be attached.}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj$hM4hj$ubah}(h]h ]h"]h$]h&]uh1j hj$ubeh}(h]h ]h"]h$]h&]uh1j hj$hM4hjN$ubeh}(h]h ]h"]h$]h&]uh1j hj2$ubh)}(h**Description**h]jr )}(hj$h]h Description}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj$ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM6hj2$ubh)}(hVWrapper to call dma_buf_dynamic_attach() for drivers which still use a static mapping.h]hVWrapper to call dma_buf_dynamic_attach() for drivers which still use a static mapping.}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM5hj2$ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_detach (C function)c.dma_buf_detachhNtauh1jhjhhhNhNubj)}(hhh](j)}(hOvoid dma_buf_detach (struct dma_buf *dmabuf, struct dma_buf_attachment *attach)h]j)}(hNvoid dma_buf_detach(struct dma_buf *dmabuf, struct dma_buf_attachment *attach)h](jM)}(hvoidh]hvoid}(hj%hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj %hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMAubj)}(h h]h }(hj%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj %hhhj%hMAubj )}(hdma_buf_detachh]j )}(hdma_buf_detachh]hdma_buf_detach}(hj1%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj-%ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj %hhhj%hMAubj)}(h;(struct dma_buf *dmabuf, struct dma_buf_attachment *attach)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hjM%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjI%ubj)}(h h]h }(hjZ%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjI%ubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hjk%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjh%ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjm%modnameN classnameNjj)}j]jO)}jGj3%sbc.dma_buf_detachasbuh1hhjI%ubj)}(h h]h }(hj%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjI%ubjd)}(hjgh]h*}(hj%hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjI%ubj )}(hdmabufh]hdmabuf}(hj%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjI%ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjE%ubj)}(h!struct dma_buf_attachment *attachh](j)}(hjh]hstruct}(hj%hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj%ubj)}(h h]h }(hj%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj%ubh)}(hhh]j )}(hdma_buf_attachmenth]hdma_buf_attachment}(hj%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj%ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj%modnameN classnameNjj)}j]j%c.dma_buf_detachasbuh1hhj%ubj)}(h h]h }(hj%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj%ubjd)}(hjgh]h*}(hj &hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj%ubj )}(hattachh]hattach}(hj&hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj%ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjE%ubeh}(h]h ]h"]h$]h&]jjuh1jhj %hhhj%hMAubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj%hhhj%hMAubah}(h]j%ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj%hMAhj%hhubjA )}(hhh]h)}(h:Remove the given attachment from dmabuf's attachments listh]h` for device-specific detach.h](h)}(h**Parameters**h]jr )}(hjb&h]h Parameters}(hjd&hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj`&ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMEhj\&ubj )}(hhh](j )}(h:``struct dma_buf *dmabuf`` [in] buffer to detach from. h](j )}(h``struct dma_buf *dmabuf``h]j)}(hj&h]hstruct dma_buf *dmabuf}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj&ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMBhj{&ubj )}(hhh]h)}(h[in] buffer to detach from.h]h[in] buffer to detach from.}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj&hMBhj&ubah}(h]h ]h"]h$]h&]uh1j hj{&ubeh}(h]h ]h"]h$]h&]uh1j hj&hMBhjx&ubj )}(hd``struct dma_buf_attachment *attach`` [in] attachment to be detached; is free'd after this call. h](j )}(h%``struct dma_buf_attachment *attach``h]j)}(hj&h]h!struct dma_buf_attachment *attach}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj&ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMChj&ubj )}(hhh]h)}(h=[in] attachment to be detached; is free'd after this call.h]h?[in] attachment to be detached; is free’d after this call.}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj&hMChj&ubah}(h]h ]h"]h$]h&]uh1j hj&ubeh}(h]h ]h"]h$]h&]uh1j hj&hMChjx&ubeh}(h]h ]h"]h$]h&]uh1j hj\&ubh)}(h**Description**h]jr )}(hj&h]h Description}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj&ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMEhj\&ubh)}(hBClean up a device attachment obtained by calling dma_buf_attach().h]hBClean up a device attachment obtained by calling dma_buf_attach().}(hj 'hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMDhj\&ubh)}(h\Optionally this calls :c:type:`dma_buf_ops.detach ` for device-specific detach.h](hOptionally this calls }(hj'hhhNhNubh)}(h*:c:type:`dma_buf_ops.detach `h]j)}(hj$'h]hdma_buf_ops.detach}(hj&'hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj"'ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_buf_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMFhj'ubh for device-specific detach.}(hj'hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjA'hMFhj\&ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_pin (C function) c.dma_buf_pinhNtauh1jhjhhhNhNubj)}(hhh](j)}(h3int dma_buf_pin (struct dma_buf_attachment *attach)h]j)}(h2int dma_buf_pin(struct dma_buf_attachment *attach)h](jM)}(hinth]hint}(hjl'hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjh'hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM]ubj)}(h h]h }(hj{'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjh'hhhjz'hM]ubj )}(h dma_buf_pinh]j )}(h dma_buf_pinh]h dma_buf_pin}(hj'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj'ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjh'hhhjz'hM]ubj)}(h#(struct dma_buf_attachment *attach)h]j)}(h!struct dma_buf_attachment *attachh](j)}(hjh]hstruct}(hj'hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj'ubj)}(h h]h }(hj'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj'ubh)}(hhh]j )}(hdma_buf_attachmenth]hdma_buf_attachment}(hj'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj'ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj'modnameN classnameNjj)}j]jO)}jGj'sb c.dma_buf_pinasbuh1hhj'ubj)}(h h]h }(hj'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj'ubjd)}(hjgh]h*}(hj'hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj'ubj )}(hattachh]hattach}(hj(hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj'ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj'ubah}(h]h ]h"]h$]h&]jjuh1jhjh'hhhjz'hM]ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjd'hhhjz'hM]ubah}(h]j_'ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjz'hM]hja'hhubjA )}(hhh]h)}(hLock down the DMA-bufh]hLock down the DMA-buf}(hj,(hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM]hj)(hhubah}(h]h ]h"]h$]h&]uh1j@ hja'hhhjz'hM]ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jD(jc jD(jd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_buf_attachment *attach`` [in] attachment which should be pinned **Description** Only dynamic importers (who set up **attach** with dma_buf_dynamic_attach()) may call this, and only for limited use cases like scanout and not for temporary pin operations. It is not permitted to allow userspace to pin arbitrary amounts of buffers through this interface. Buffers must be unpinned by calling dma_buf_unpin(). **Return** 0 on success, negative error code on failure.h](h)}(h**Parameters**h]jr )}(hjN(h]h Parameters}(hjP(hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjL(ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMahjH(ubj )}(hhh]j )}(hP``struct dma_buf_attachment *attach`` [in] attachment which should be pinned h](j )}(h%``struct dma_buf_attachment *attach``h]j)}(hjm(h]h!struct dma_buf_attachment *attach}(hjo(hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjk(ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM^hjg(ubj )}(hhh]h)}(h)[in] attachment which should be pinnedh]h)[in] attachment which should be pinned}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj(hM^hj(ubah}(h]h ]h"]h$]h&]uh1j hjg(ubeh}(h]h ]h"]h$]h&]uh1j hj(hM^hjd(ubah}(h]h ]h"]h$]h&]uh1j hjH(ubh)}(h**Description**h]jr )}(hj(h]h Description}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj(ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM`hjH(ubh)}(hXOnly dynamic importers (who set up **attach** with dma_buf_dynamic_attach()) may call this, and only for limited use cases like scanout and not for temporary pin operations. It is not permitted to allow userspace to pin arbitrary amounts of buffers through this interface.h](h#Only dynamic importers (who set up }(hj(hhhNhNubjr )}(h **attach**h]hattach}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj(ubh with dma_buf_dynamic_attach()) may call this, and only for limited use cases like scanout and not for temporary pin operations. It is not permitted to allow userspace to pin arbitrary amounts of buffers through this interface.}(hj(hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM_hjH(ubh)}(h4Buffers must be unpinned by calling dma_buf_unpin().h]h4Buffers must be unpinned by calling dma_buf_unpin().}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMdhjH(ubh)}(h **Return**h]jr )}(hj(h]hReturn}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj(ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMfhjH(ubh)}(h-0 on success, negative error code on failure.h]h-0 on success, negative error code on failure.}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMghjH(ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_unpin (C function)c.dma_buf_unpinhNtauh1jhjhhhNhNubj)}(hhh](j)}(h6void dma_buf_unpin (struct dma_buf_attachment *attach)h]j)}(h5void dma_buf_unpin(struct dma_buf_attachment *attach)h](jM)}(hvoidh]hvoid}(hj5)hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj1)hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM{ubj)}(h h]h }(hjD)hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj1)hhhjC)hM{ubj )}(h dma_buf_unpinh]j )}(h dma_buf_unpinh]h dma_buf_unpin}(hjV)hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjR)ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj1)hhhjC)hM{ubj)}(h#(struct dma_buf_attachment *attach)h]j)}(h!struct dma_buf_attachment *attachh](j)}(hjh]hstruct}(hjr)hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjn)ubj)}(h h]h }(hj)hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjn)ubh)}(hhh]j )}(hdma_buf_attachmenth]hdma_buf_attachment}(hj)hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj)ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj)modnameN classnameNjj)}j]jO)}jGjX)sbc.dma_buf_unpinasbuh1hhjn)ubj)}(h h]h }(hj)hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjn)ubjd)}(hjgh]h*}(hj)hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjn)ubj )}(hattachh]hattach}(hj)hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjn)ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjj)ubah}(h]h ]h"]h$]h&]jjuh1jhj1)hhhjC)hM{ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj-)hhhjC)hM{ubah}(h]j()ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjC)hM{hj*)hhubjA )}(hhh]h)}(hUnpin a DMA-bufh]hUnpin a DMA-buf}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM{hj)hhubah}(h]h ]h"]h$]h&]uh1j@ hj*)hhhjC)hM{ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j *jc j *jd je jf uh1jhhhjhNhNubjh )}(hXI**Parameters** ``struct dma_buf_attachment *attach`` [in] attachment which should be unpinned **Description** This unpins a buffer pinned by dma_buf_pin() and allows the exporter to move any mapping of **attach** again and inform the importer through :c:type:`dma_buf_attach_ops.invalidate_mappings `.h](h)}(h**Parameters**h]jr )}(hj*h]h Parameters}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj*ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj*ubj )}(hhh]j )}(hR``struct dma_buf_attachment *attach`` [in] attachment which should be unpinned h](j )}(h%``struct dma_buf_attachment *attach``h]j)}(hj6*h]h!struct dma_buf_attachment *attach}(hj8*hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj4*ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM|hj0*ubj )}(hhh]h)}(h+[in] attachment which should be unpinnedh]h+[in] attachment which should be unpinned}(hjO*hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjK*hM|hjL*ubah}(h]h ]h"]h$]h&]uh1j hj0*ubeh}(h]h ]h"]h$]h&]uh1j hjK*hM|hj-*ubah}(h]h ]h"]h$]h&]uh1j hj*ubh)}(h**Description**h]jr )}(hjq*h]h Description}(hjs*hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjo*ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM~hj*ubh)}(hThis unpins a buffer pinned by dma_buf_pin() and allows the exporter to move any mapping of **attach** again and inform the importer through :c:type:`dma_buf_attach_ops.invalidate_mappings `.h](h\This unpins a buffer pinned by dma_buf_pin() and allows the exporter to move any mapping of }(hj*hhhNhNubjr )}(h **attach**h]hattach}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj*ubh' again and inform the importer through }(hj*hhhNhNubh)}(hE:c:type:`dma_buf_attach_ops.invalidate_mappings `h]j)}(hj*h]h&dma_buf_attach_ops.invalidate_mappings}(hj*hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj*ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_attach_opsuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM}hj*ubh.}(hj*hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj*hM}hj*ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_buf_map_attachment (C function)c.dma_buf_map_attachmenthNtauh1jhjhhhNhNubj)}(hhh](j)}(hostruct sg_table * dma_buf_map_attachment (struct dma_buf_attachment *attach, enum dma_data_direction direction)h]j)}(hmstruct sg_table *dma_buf_map_attachment(struct dma_buf_attachment *attach, enum dma_data_direction direction)h](j)}(hjh]hstruct}(hj*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj*hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMubj)}(h h]h }(hj*hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj*hhhj*hMubh)}(hhh]j )}(hsg_tableh]hsg_table}(hj +hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj+ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj +modnameN classnameNjj)}j]jO)}jGdma_buf_map_attachmentsbc.dma_buf_map_attachmentasbuh1hhj*hhhj*hMubj)}(h h]h }(hj++hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj*hhhj*hMubjd)}(hjgh]h*}(hj9+hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj*hhhj*hMubj )}(hdma_buf_map_attachmenth]j )}(hj(+h]hdma_buf_map_attachment}(hjJ+hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjF+ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj*hhhj*hMubj)}(hF(struct dma_buf_attachment *attach, enum dma_data_direction direction)h](j)}(h!struct dma_buf_attachment *attachh](j)}(hjh]hstruct}(hje+hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhja+ubj)}(h h]h }(hjr+hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhja+ubh)}(hhh]j )}(hdma_buf_attachmenth]hdma_buf_attachment}(hj+hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj+ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj+modnameN classnameNjj)}j]j&+c.dma_buf_map_attachmentasbuh1hhja+ubj)}(h h]h }(hj+hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhja+ubjd)}(hjgh]h*}(hj+hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchja+ubj )}(hattachh]hattach}(hj+hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hja+ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj]+ubj)}(h!enum dma_data_direction directionh](j)}(henumh]henum}(hj+hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj+ubj)}(h h]h }(hj+hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj+ubh)}(hhh]j )}(hdma_data_directionh]hdma_data_direction}(hj+hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj+ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj+modnameN classnameNjj)}j]j&+c.dma_buf_map_attachmentasbuh1hhj+ubj)}(h h]h }(hj,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj+ubj )}(h directionh]h direction}(hj ,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj+ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj]+ubeh}(h]h ]h"]h$]h&]jjuh1jhj*hhhj*hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj*hhhj*hMubah}(h]j*ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj*hMhj*hhubjA )}(hhh]h)}(hReturns the scatterlist table of the attachment; mapped into _device_ address space. Is a wrapper for map_dma_buf() of the dma_buf_ops.h]hReturns the scatterlist table of the attachment; mapped into _device_ address space. Is a wrapper for map_dma_buf() of the dma_buf_ops.}(hjJ,hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjG,hhubah}(h]h ]h"]h$]h&]uh1j@ hj*hhhj*hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jb,jc jb,jd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_buf_attachment *attach`` [in] attachment whose scatterlist is to be returned ``enum dma_data_direction direction`` [in] direction of DMA transfer **Description** Returns sg_table containing the scatterlist to be returned; returns ERR_PTR on error. May return -EINTR if it is interrupted by a signal. On success, the DMA addresses and lengths in the returned scatterlist are PAGE_SIZE aligned. A mapping must be unmapped by using dma_buf_unmap_attachment(). Note that the underlying backing storage is pinned for as long as a mapping exists, therefore users/importers should not hold onto a mapping for undue amounts of time. Important: Dynamic importers must wait for the exclusive fence of the struct dma_resv attached to the DMA-BUF first.h](h)}(h**Parameters**h]jr )}(hjl,h]h Parameters}(hjn,hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjj,ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjf,ubj )}(hhh](j )}(h]``struct dma_buf_attachment *attach`` [in] attachment whose scatterlist is to be returned h](j )}(h%``struct dma_buf_attachment *attach``h]j)}(hj,h]h!struct dma_buf_attachment *attach}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj,ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj,ubj )}(hhh]h)}(h6[in] attachment whose scatterlist is to be returnedh]h6[in] attachment whose scatterlist is to be returned}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj,hMhj,ubah}(h]h ]h"]h$]h&]uh1j hj,ubeh}(h]h ]h"]h$]h&]uh1j hj,hMhj,ubj )}(hH``enum dma_data_direction direction`` [in] direction of DMA transfer h](j )}(h%``enum dma_data_direction direction``h]j)}(hj,h]h!enum dma_data_direction direction}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj,ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj,ubj )}(hhh]h)}(h![in] direction of DMA transferh]h![in] direction of DMA transfer}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj,hMhj,ubah}(h]h ]h"]h$]h&]uh1j hj,ubeh}(h]h ]h"]h$]h&]uh1j hj,hMhj,ubeh}(h]h ]h"]h$]h&]uh1j hjf,ubh)}(h**Description**h]jr )}(hj,h]h Description}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj,ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjf,ubh)}(hReturns sg_table containing the scatterlist to be returned; returns ERR_PTR on error. May return -EINTR if it is interrupted by a signal.h]hReturns sg_table containing the scatterlist to be returned; returns ERR_PTR on error. May return -EINTR if it is interrupted by a signal.}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjf,ubh)}(h\On success, the DMA addresses and lengths in the returned scatterlist are PAGE_SIZE aligned.h]h\On success, the DMA addresses and lengths in the returned scatterlist are PAGE_SIZE aligned.}(hj$-hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjf,ubh)}(hA mapping must be unmapped by using dma_buf_unmap_attachment(). Note that the underlying backing storage is pinned for as long as a mapping exists, therefore users/importers should not hold onto a mapping for undue amounts of time.h]hA mapping must be unmapped by using dma_buf_unmap_attachment(). Note that the underlying backing storage is pinned for as long as a mapping exists, therefore users/importers should not hold onto a mapping for undue amounts of time.}(hj3-hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjf,ubh)}(htImportant: Dynamic importers must wait for the exclusive fence of the struct dma_resv attached to the DMA-BUF first.h]htImportant: Dynamic importers must wait for the exclusive fence of the struct dma_resv attached to the DMA-BUF first.}(hjB-hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjf,ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j,dma_buf_map_attachment_unlocked (C function)!c.dma_buf_map_attachment_unlockedhNtauh1jhjhhhNhNubj)}(hhh](j)}(hxstruct sg_table * dma_buf_map_attachment_unlocked (struct dma_buf_attachment *attach, enum dma_data_direction direction)h]j)}(hvstruct sg_table *dma_buf_map_attachment_unlocked(struct dma_buf_attachment *attach, enum dma_data_direction direction)h](j)}(hjh]hstruct}(hjq-hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjm-hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMubj)}(h h]h }(hj-hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjm-hhhj~-hMubh)}(hhh]j )}(hsg_tableh]hsg_table}(hj-hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj-ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj-modnameN classnameNjj)}j]jO)}jGdma_buf_map_attachment_unlockedsb!c.dma_buf_map_attachment_unlockedasbuh1hhjm-hhhj~-hMubj)}(h h]h }(hj-hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjm-hhhj~-hMubjd)}(hjgh]h*}(hj-hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjm-hhhj~-hMubj )}(hdma_buf_map_attachment_unlockedh]j )}(hj-h]hdma_buf_map_attachment_unlocked}(hj-hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj-ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjm-hhhj~-hMubj)}(hF(struct dma_buf_attachment *attach, enum dma_data_direction direction)h](j)}(h!struct dma_buf_attachment *attachh](j)}(hjh]hstruct}(hj-hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj-ubj)}(h h]h }(hj-hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj-ubh)}(hhh]j )}(hdma_buf_attachmenth]hdma_buf_attachment}(hj .hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj.ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj .modnameN classnameNjj)}j]j-!c.dma_buf_map_attachment_unlockedasbuh1hhj-ubj)}(h h]h }(hj'.hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj-ubjd)}(hjgh]h*}(hj5.hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj-ubj )}(hattachh]hattach}(hjB.hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj-ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj-ubj)}(h!enum dma_data_direction directionh](j)}(hj+h]henum}(hj[.hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjW.ubj)}(h h]h }(hjh.hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjW.ubh)}(hhh]j )}(hdma_data_directionh]hdma_data_direction}(hjy.hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjv.ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj{.modnameN classnameNjj)}j]j-!c.dma_buf_map_attachment_unlockedasbuh1hhjW.ubj)}(h h]h }(hj.hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjW.ubj )}(h directionh]h direction}(hj.hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjW.ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj-ubeh}(h]h ]h"]h$]h&]jjuh1jhjm-hhhj~-hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hji-hhhj~-hMubah}(h]jd-ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj~-hMhjf-hhubjA )}(hhh]h)}(hReturns the scatterlist table of the attachment; mapped into _device_ address space. Is a wrapper for map_dma_buf() of the dma_buf_ops.h]hReturns the scatterlist table of the attachment; mapped into _device_ address space. Is a wrapper for map_dma_buf() of the dma_buf_ops.}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj.hhubah}(h]h ]h"]h$]h&]uh1j@ hjf-hhhj~-hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j.jc j.jd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_buf_attachment *attach`` [in] attachment whose scatterlist is to be returned ``enum dma_data_direction direction`` [in] direction of DMA transfer **Description** Unlocked variant of dma_buf_map_attachment().h](h)}(h**Parameters**h]jr )}(hj.h]h Parameters}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj.ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj.ubj )}(hhh](j )}(h]``struct dma_buf_attachment *attach`` [in] attachment whose scatterlist is to be returned h](j )}(h%``struct dma_buf_attachment *attach``h]j)}(hj/h]h!struct dma_buf_attachment *attach}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj/ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj /ubj )}(hhh]h)}(h6[in] attachment whose scatterlist is to be returnedh]h6[in] attachment whose scatterlist is to be returned}(hj)/hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj%/hMhj&/ubah}(h]h ]h"]h$]h&]uh1j hj /ubeh}(h]h ]h"]h$]h&]uh1j hj%/hMhj/ubj )}(hH``enum dma_data_direction direction`` [in] direction of DMA transfer h](j )}(h%``enum dma_data_direction direction``h]j)}(hjI/h]h!enum dma_data_direction direction}(hjK/hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjG/ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjC/ubj )}(hhh]h)}(h![in] direction of DMA transferh]h![in] direction of DMA transfer}(hjb/hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj^/hMhj_/ubah}(h]h ]h"]h$]h&]uh1j hjC/ubeh}(h]h ]h"]h$]h&]uh1j hj^/hMhj/ubeh}(h]h ]h"]h$]h&]uh1j hj.ubh)}(h**Description**h]jr )}(hj/h]h Description}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj/ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj.ubh)}(h-Unlocked variant of dma_buf_map_attachment().h]h-Unlocked variant of dma_buf_map_attachment().}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj.ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j%dma_buf_unmap_attachment (C function)c.dma_buf_unmap_attachmenthNtauh1jhjhhhNhNubj)}(hhh](j)}(hvoid dma_buf_unmap_attachment (struct dma_buf_attachment *attach, struct sg_table *sg_table, enum dma_data_direction direction)h]j)}(h~void dma_buf_unmap_attachment(struct dma_buf_attachment *attach, struct sg_table *sg_table, enum dma_data_direction direction)h](jM)}(hvoidh]hvoid}(hj/hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj/hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM ubj)}(h h]h }(hj/hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj/hhhj/hM ubj )}(hdma_buf_unmap_attachmenth]j )}(hdma_buf_unmap_attachmenth]hdma_buf_unmap_attachment}(hj/hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj/ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj/hhhj/hM ubj)}(ha(struct dma_buf_attachment *attach, struct sg_table *sg_table, enum dma_data_direction direction)h](j)}(h!struct dma_buf_attachment *attachh](j)}(hjh]hstruct}(hj0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj0ubj)}(h h]h }(hj0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj0ubh)}(hhh]j )}(hdma_buf_attachmenth]hdma_buf_attachment}(hj$0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj!0ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj&0modnameN classnameNjj)}j]jO)}jGj/sbc.dma_buf_unmap_attachmentasbuh1hhj0ubj)}(h h]h }(hjD0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj0ubjd)}(hjgh]h*}(hjR0hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj0ubj )}(hattachh]hattach}(hj_0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj0ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj/ubj)}(hstruct sg_table *sg_tableh](j)}(hjh]hstruct}(hjx0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjt0ubj)}(h h]h }(hj0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjt0ubh)}(hhh]j )}(hsg_tableh]hsg_table}(hj0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj0ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj0modnameN classnameNjj)}j]j@0c.dma_buf_unmap_attachmentasbuh1hhjt0ubj)}(h h]h }(hj0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjt0ubjd)}(hjgh]h*}(hj0hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjt0ubj )}(hsg_tableh]hsg_table}(hj0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjt0ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj/ubj)}(h!enum dma_data_direction directionh](j)}(hj+h]henum}(hj0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj0ubj)}(h h]h }(hj0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj0ubh)}(hhh]j )}(hdma_data_directionh]hdma_data_direction}(hj1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj1ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj1modnameN classnameNjj)}j]j@0c.dma_buf_unmap_attachmentasbuh1hhj0ubj)}(h h]h }(hj$1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj0ubj )}(h directionh]h direction}(hj21hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj0ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj/ubeh}(h]h ]h"]h$]h&]jjuh1jhj/hhhj/hM ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj/hhhj/hM ubah}(h]j/ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj/hM hj/hhubjA )}(hhh]h)}(hunmaps and decreases usecount of the buffer;might deallocate the scatterlist associated. Is a wrapper for unmap_dma_buf() of dma_buf_ops.h]hunmaps and decreases usecount of the buffer;might deallocate the scatterlist associated. Is a wrapper for unmap_dma_buf() of dma_buf_ops.}(hj\1hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM hjY1hhubah}(h]h ]h"]h$]h&]uh1j@ hj/hhhj/hM ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jt1jc jt1jd je jf uh1jhhhjhNhNubjh )}(hX^**Parameters** ``struct dma_buf_attachment *attach`` [in] attachment to unmap buffer from ``struct sg_table *sg_table`` [in] scatterlist info of the buffer to unmap ``enum dma_data_direction direction`` [in] direction of DMA transfer **Description** This unmaps a DMA mapping for **attached** obtained by dma_buf_map_attachment().h](h)}(h**Parameters**h]jr )}(hj~1h]h Parameters}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj|1ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjx1ubj )}(hhh](j )}(hN``struct dma_buf_attachment *attach`` [in] attachment to unmap buffer from h](j )}(h%``struct dma_buf_attachment *attach``h]j)}(hj1h]h!struct dma_buf_attachment *attach}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj1ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj1ubj )}(hhh]h)}(h'[in] attachment to unmap buffer fromh]h'[in] attachment to unmap buffer from}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj1hMhj1ubah}(h]h ]h"]h$]h&]uh1j hj1ubeh}(h]h ]h"]h$]h&]uh1j hj1hMhj1ubj )}(hN``struct sg_table *sg_table`` [in] scatterlist info of the buffer to unmap h](j )}(h``struct sg_table *sg_table``h]j)}(hj1h]hstruct sg_table *sg_table}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj1ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj1ubj )}(hhh]h)}(h/[in] scatterlist info of the buffer to unmaph]h/[in] scatterlist info of the buffer to unmap}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj1hMhj1ubah}(h]h ]h"]h$]h&]uh1j hj1ubeh}(h]h ]h"]h$]h&]uh1j hj1hMhj1ubj )}(hH``enum dma_data_direction direction`` [in] direction of DMA transfer h](j )}(h%``enum dma_data_direction direction``h]j)}(hj2h]h!enum dma_data_direction direction}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj 2ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj 2ubj )}(hhh]h)}(h![in] direction of DMA transferh]h![in] direction of DMA transfer}(hj(2hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj$2hMhj%2ubah}(h]h ]h"]h$]h&]uh1j hj 2ubeh}(h]h ]h"]h$]h&]uh1j hj$2hMhj1ubeh}(h]h ]h"]h$]h&]uh1j hjx1ubh)}(h**Description**h]jr )}(hjJ2h]h Description}(hjL2hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjH2ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjx1ubh)}(hPThis unmaps a DMA mapping for **attached** obtained by dma_buf_map_attachment().h](hThis unmaps a DMA mapping for }(hj`2hhhNhNubjr )}(h **attached**h]hattached}(hjh2hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj`2ubh& obtained by dma_buf_map_attachment().}(hj`2hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjx1ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j.dma_buf_unmap_attachment_unlocked (C function)#c.dma_buf_unmap_attachment_unlockedhNtauh1jhjhhhNhNubj)}(hhh](j)}(hvoid dma_buf_unmap_attachment_unlocked (struct dma_buf_attachment *attach, struct sg_table *sg_table, enum dma_data_direction direction)h]j)}(hvoid dma_buf_unmap_attachment_unlocked(struct dma_buf_attachment *attach, struct sg_table *sg_table, enum dma_data_direction direction)h](jM)}(hvoidh]hvoid}(hj2hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj2hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM(ubj)}(h h]h }(hj2hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj2hhhj2hM(ubj )}(h!dma_buf_unmap_attachment_unlockedh]j )}(h!dma_buf_unmap_attachment_unlockedh]h!dma_buf_unmap_attachment_unlocked}(hj2hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj2ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj2hhhj2hM(ubj)}(ha(struct dma_buf_attachment *attach, struct sg_table *sg_table, enum dma_data_direction direction)h](j)}(h!struct dma_buf_attachment *attachh](j)}(hjh]hstruct}(hj2hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj2ubj)}(h h]h }(hj2hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj2ubh)}(hhh]j )}(hdma_buf_attachmenth]hdma_buf_attachment}(hj2hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj2ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj2modnameN classnameNjj)}j]jO)}jGj2sb#c.dma_buf_unmap_attachment_unlockedasbuh1hhj2ubj)}(h h]h }(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj2ubjd)}(hjgh]h*}(hj*3hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj2ubj )}(hattachh]hattach}(hj73hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj2ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj2ubj)}(hstruct sg_table *sg_tableh](j)}(hjh]hstruct}(hjP3hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjL3ubj)}(h h]h }(hj]3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjL3ubh)}(hhh]j )}(hsg_tableh]hsg_table}(hjn3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjk3ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjp3modnameN classnameNjj)}j]j3#c.dma_buf_unmap_attachment_unlockedasbuh1hhjL3ubj)}(h h]h }(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjL3ubjd)}(hjgh]h*}(hj3hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjL3ubj )}(hsg_tableh]hsg_table}(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjL3ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj2ubj)}(h!enum dma_data_direction directionh](j)}(hj+h]henum}(hj3hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj3ubj)}(h h]h }(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj3ubh)}(hhh]j )}(hdma_data_directionh]hdma_data_direction}(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj3ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj3modnameN classnameNjj)}j]j3#c.dma_buf_unmap_attachment_unlockedasbuh1hhj3ubj)}(h h]h }(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj3ubj )}(h directionh]h direction}(hj 4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj3ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj2ubeh}(h]h ]h"]h$]h&]jjuh1jhj2hhhj2hM(ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj2hhhj2hM(ubah}(h]j2ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj2hM(hj2hhubjA )}(hhh]h)}(hunmaps and decreases usecount of the buffer;might deallocate the scatterlist associated. Is a wrapper for unmap_dma_buf() of dma_buf_ops.h]hunmaps and decreases usecount of the buffer;might deallocate the scatterlist associated. Is a wrapper for unmap_dma_buf() of dma_buf_ops.}(hj44hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM(hj14hhubah}(h]h ]h"]h$]h&]uh1j@ hj2hhhj2hM(ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jL4jc jL4jd je jf uh1jhhhjhNhNubjh )}(hX=**Parameters** ``struct dma_buf_attachment *attach`` [in] attachment to unmap buffer from ``struct sg_table *sg_table`` [in] scatterlist info of the buffer to unmap ``enum dma_data_direction direction`` [in] direction of DMA transfer **Description** Unlocked variant of dma_buf_unmap_attachment().h](h)}(h**Parameters**h]jr )}(hjV4h]h Parameters}(hjX4hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjT4ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM,hjP4ubj )}(hhh](j )}(hN``struct dma_buf_attachment *attach`` [in] attachment to unmap buffer from h](j )}(h%``struct dma_buf_attachment *attach``h]j)}(hju4h]h!struct dma_buf_attachment *attach}(hjw4hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjs4ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM+hjo4ubj )}(hhh]h)}(h'[in] attachment to unmap buffer fromh]h'[in] attachment to unmap buffer from}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj4hM+hj4ubah}(h]h ]h"]h$]h&]uh1j hjo4ubeh}(h]h ]h"]h$]h&]uh1j hj4hM+hjl4ubj )}(hN``struct sg_table *sg_table`` [in] scatterlist info of the buffer to unmap h](j )}(h``struct sg_table *sg_table``h]j)}(hj4h]hstruct sg_table *sg_table}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj4ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM,hj4ubj )}(hhh]h)}(h/[in] scatterlist info of the buffer to unmaph]h/[in] scatterlist info of the buffer to unmap}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj4hM,hj4ubah}(h]h ]h"]h$]h&]uh1j hj4ubeh}(h]h ]h"]h$]h&]uh1j hj4hM,hjl4ubj )}(hH``enum dma_data_direction direction`` [in] direction of DMA transfer h](j )}(h%``enum dma_data_direction direction``h]j)}(hj4h]h!enum dma_data_direction direction}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj4ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM-hj4ubj )}(hhh]h)}(h![in] direction of DMA transferh]h![in] direction of DMA transfer}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj4hM-hj4ubah}(h]h ]h"]h$]h&]uh1j hj4ubeh}(h]h ]h"]h$]h&]uh1j hj4hM-hjl4ubeh}(h]h ]h"]h$]h&]uh1j hjP4ubh)}(h**Description**h]jr )}(hj"5h]h Description}(hj$5hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj 5ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM/hjP4ubh)}(h/Unlocked variant of dma_buf_unmap_attachment().h]h/Unlocked variant of dma_buf_unmap_attachment().}(hj85hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM.hjP4ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j%dma_buf_attach_revocable (C function)c.dma_buf_attach_revocablehNtauh1jhjhhhNhNubj)}(hhh](j)}(hAbool dma_buf_attach_revocable (struct dma_buf_attachment *attach)h]j)}(h@bool dma_buf_attach_revocable(struct dma_buf_attachment *attach)h](jM)}(hboolh]hbool}(hjg5hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjc5hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMAubj)}(h h]h }(hjv5hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjc5hhhju5hMAubj )}(hdma_buf_attach_revocableh]j )}(hdma_buf_attach_revocableh]hdma_buf_attach_revocable}(hj5hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj5ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjc5hhhju5hMAubj)}(h#(struct dma_buf_attachment *attach)h]j)}(h!struct dma_buf_attachment *attachh](j)}(hjh]hstruct}(hj5hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj5ubj)}(h h]h }(hj5hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj5ubh)}(hhh]j )}(hdma_buf_attachmenth]hdma_buf_attachment}(hj5hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj5ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj5modnameN classnameNjj)}j]jO)}jGj5sbc.dma_buf_attach_revocableasbuh1hhj5ubj)}(h h]h }(hj5hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj5ubjd)}(hjgh]h*}(hj5hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj5ubj )}(hattachh]hattach}(hj5hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj5ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj5ubah}(h]h ]h"]h$]h&]jjuh1jhjc5hhhju5hMAubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj_5hhhju5hMAubah}(h]jZ5ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhju5hMAhj\5hhubjA )}(hhh]h)}(h8check if a DMA-buf importer implements revoke semantics.h]h8check if a DMA-buf importer implements revoke semantics.}(hj'6hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMAhj$6hhubah}(h]h ]h"]h$]h&]uh1j@ hj\5hhhju5hMAubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j?6jc j?6jd je jf uh1jhhhjhNhNubjh )}(hXR**Parameters** ``struct dma_buf_attachment *attach`` the DMA-buf attachment to check **Description** Returns true if the DMA-buf importer can support the revoke sequence explained in dma_buf_invalidate_mappings() within bounded time. Meaning the importer implements invalidate_mappings() and ensures that unmap is called as a result.h](h)}(h**Parameters**h]jr )}(hjI6h]h Parameters}(hjK6hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjG6ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMEhjC6ubj )}(hhh]j )}(hF``struct dma_buf_attachment *attach`` the DMA-buf attachment to check h](j )}(h%``struct dma_buf_attachment *attach``h]j)}(hjh6h]h!struct dma_buf_attachment *attach}(hjj6hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjf6ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMChjb6ubj )}(hhh]h)}(hthe DMA-buf attachment to checkh]hthe DMA-buf attachment to check}(hj6hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj}6hMChj~6ubah}(h]h ]h"]h$]h&]uh1j hjb6ubeh}(h]h ]h"]h$]h&]uh1j hj}6hMChj_6ubah}(h]h ]h"]h$]h&]uh1j hjC6ubh)}(h**Description**h]jr )}(hj6h]h Description}(hj6hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj6ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMEhjC6ubh)}(hReturns true if the DMA-buf importer can support the revoke sequence explained in dma_buf_invalidate_mappings() within bounded time. Meaning the importer implements invalidate_mappings() and ensures that unmap is called as a result.h]hReturns true if the DMA-buf importer can support the revoke sequence explained in dma_buf_invalidate_mappings() within bounded time. Meaning the importer implements invalidate_mappings() and ensures that unmap is called as a result.}(hj6hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMDhjC6ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j(dma_buf_invalidate_mappings (C function)c.dma_buf_invalidate_mappingshNtauh1jhjhhhNhNubj)}(hhh](j)}(h9void dma_buf_invalidate_mappings (struct dma_buf *dmabuf)h]j)}(h8void dma_buf_invalidate_mappings(struct dma_buf *dmabuf)h](jM)}(hvoidh]hvoid}(hj6hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj6hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMRubj)}(h h]h }(hj6hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj6hhhj6hMRubj )}(hdma_buf_invalidate_mappingsh]j )}(hdma_buf_invalidate_mappingsh]hdma_buf_invalidate_mappings}(hj 7hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj7ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj6hhhj6hMRubj)}(h(struct dma_buf *dmabuf)h]j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hj%7hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj!7ubj)}(h h]h }(hj27hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj!7ubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hjC7hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj@7ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjE7modnameN classnameNjj)}j]jO)}jGj 7sbc.dma_buf_invalidate_mappingsasbuh1hhj!7ubj)}(h h]h }(hjc7hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj!7ubjd)}(hjgh]h*}(hjq7hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj!7ubj )}(hdmabufh]hdmabuf}(hj~7hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj!7ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj7ubah}(h]h ]h"]h$]h&]jjuh1jhj6hhhj6hMRubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj6hhhj6hMRubah}(h]j6ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj6hMRhj6hhubjA )}(hhh]h)}(h)notify attachments that DMA-buf is movingh]h)notify attachments that DMA-buf is moving}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMRhj7hhubah}(h]h ]h"]h$]h&]uh1j@ hj6hhhj6hMRubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j7jc j7jd je jf uh1jhhhjhNhNubjh )}(hXy**Parameters** ``struct dma_buf *dmabuf`` [in] buffer which is moving **Description** Informs all attachments that they need to destroy and recreate all their mappings. If the attachment is dynamic then the dynamic importer is expected to invalidate any caches it has of the mapping result and perform a new mapping request before allowing HW to do any further DMA. If the attachment is pinned then this informs the pinned importer that the underlying mapping is no longer available. Pinned importers may take this is as a permanent revocation and never establish new mappings so exporters should not trigger it lightly. Upon return importers may continue to access the DMA-buf memory. The caller must do two additional waits to ensure that the memory is no longer being accessed: 1) Until dma_resv_wait_timeout() retires fences the importer is allowed to fully access the memory. 2) Until the importer calls unmap it is allowed to speculatively read-and-discard the memory. It must not write to the memory. A caller wishing to use dma_buf_invalidate_mappings() to fully stop access to the DMA-buf must wait for both. Dynamic callers can often use just the first. All importers providing a invalidate_mappings() op must ensure that unmap is called within bounded time after the op. Pinned importers that do not support a invalidate_mappings() op will eventually perform unmap when they are done with the buffer, which may be an ubounded time from calling this function. dma_buf_attach_revocable() can be used to prevent such importers from attaching. Importers are free to request a new mapping in parallel as this function returns.h](h)}(h**Parameters**h]jr )}(hj7h]h Parameters}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj7ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMVhj7ubj )}(hhh]j )}(h:``struct dma_buf *dmabuf`` [in] buffer which is moving h](j )}(h``struct dma_buf *dmabuf``h]j)}(hj7h]hstruct dma_buf *dmabuf}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj7ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMThj7ubj )}(hhh]h)}(h[in] buffer which is movingh]h[in] buffer which is moving}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj7hMThj7ubah}(h]h ]h"]h$]h&]uh1j hj7ubeh}(h]h ]h"]h$]h&]uh1j hj7hMThj7ubah}(h]h ]h"]h$]h&]uh1j hj7ubh)}(h**Description**h]jr )}(hj$8h]h Description}(hj&8hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj"8ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMVhj7ubh)}(hXInforms all attachments that they need to destroy and recreate all their mappings. If the attachment is dynamic then the dynamic importer is expected to invalidate any caches it has of the mapping result and perform a new mapping request before allowing HW to do any further DMA.h]hXInforms all attachments that they need to destroy and recreate all their mappings. If the attachment is dynamic then the dynamic importer is expected to invalidate any caches it has of the mapping result and perform a new mapping request before allowing HW to do any further DMA.}(hj:8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMUhj7ubh)}(hIf the attachment is pinned then this informs the pinned importer that the underlying mapping is no longer available. Pinned importers may take this is as a permanent revocation and never establish new mappings so exporters should not trigger it lightly.h]hIf the attachment is pinned then this informs the pinned importer that the underlying mapping is no longer available. Pinned importers may take this is as a permanent revocation and never establish new mappings so exporters should not trigger it lightly.}(hjI8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMZhj7ubh)}(hUpon return importers may continue to access the DMA-buf memory. The caller must do two additional waits to ensure that the memory is no longer being accessed:h]hUpon return importers may continue to access the DMA-buf memory. The caller must do two additional waits to ensure that the memory is no longer being accessed:}(hjX8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM_hj7ubh)}(h1) Until dma_resv_wait_timeout() retires fences the importer is allowed to fully access the memory. 2) Until the importer calls unmap it is allowed to speculatively read-and-discard the memory. It must not write to the memory. h]jm)}(hhh](j)}(h`Until dma_resv_wait_timeout() retires fences the importer is allowed to fully access the memory.h]h)}(h`Until dma_resv_wait_timeout() retires fences the importer is allowed to fully access the memory.h]h`Until dma_resv_wait_timeout() retires fences the importer is allowed to fully access the memory.}(hjr8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMchjn8ubah}(h]h ]h"]h$]h&]uh1jhjk8ubj)}(h|Until the importer calls unmap it is allowed to speculatively read-and-discard the memory. It must not write to the memory. h]h)}(h{Until the importer calls unmap it is allowed to speculatively read-and-discard the memory. It must not write to the memory.h]h{Until the importer calls unmap it is allowed to speculatively read-and-discard the memory. It must not write to the memory.}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMehj8ubah}(h]h ]h"]h$]h&]uh1jhjk8ubeh}(h]h ]h"]h$]h&]jSjTjUhjV)uh1jlhjg8ubah}(h]h ]h"]h$]h&]uh1hhj8hMchj7ubh)}(hA caller wishing to use dma_buf_invalidate_mappings() to fully stop access to the DMA-buf must wait for both. Dynamic callers can often use just the first.h]hA caller wishing to use dma_buf_invalidate_mappings() to fully stop access to the DMA-buf must wait for both. Dynamic callers can often use just the first.}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhhj7ubh)}(huAll importers providing a invalidate_mappings() op must ensure that unmap is called within bounded time after the op.h]huAll importers providing a invalidate_mappings() op must ensure that unmap is called within bounded time after the op.}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMkhj7ubh)}(hX Pinned importers that do not support a invalidate_mappings() op will eventually perform unmap when they are done with the buffer, which may be an ubounded time from calling this function. dma_buf_attach_revocable() can be used to prevent such importers from attaching.h]hX Pinned importers that do not support a invalidate_mappings() op will eventually perform unmap when they are done with the buffer, which may be an ubounded time from calling this function. dma_buf_attach_revocable() can be used to prevent such importers from attaching.}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMnhj7ubh)}(hQImporters are free to request a new mapping in parallel as this function returns.h]hQImporters are free to request a new mapping in parallel as this function returns.}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMshj7ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j%dma_buf_begin_cpu_access (C function)c.dma_buf_begin_cpu_accesshNtauh1jhjhhhNhNubj)}(hhh](j)}(hXint dma_buf_begin_cpu_access (struct dma_buf *dmabuf, enum dma_data_direction direction)h]j)}(hWint dma_buf_begin_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction)h](jM)}(hinth]hint}(hj 9hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj9hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMubj)}(h h]h }(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj9hhhj9hMubj )}(hdma_buf_begin_cpu_accessh]j )}(hdma_buf_begin_cpu_accessh]hdma_buf_begin_cpu_access}(hj*9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj&9ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj9hhhj9hMubj)}(h;(struct dma_buf *dmabuf, enum dma_data_direction direction)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hjF9hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjB9ubj)}(h h]h }(hjS9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjB9ubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hjd9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hja9ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjf9modnameN classnameNjj)}j]jO)}jGj,9sbc.dma_buf_begin_cpu_accessasbuh1hhjB9ubj)}(h h]h }(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjB9ubjd)}(hjgh]h*}(hj9hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjB9ubj )}(hdmabufh]hdmabuf}(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjB9ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj>9ubj)}(h!enum dma_data_direction directionh](j)}(hj+h]henum}(hj9hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj9ubj)}(h h]h }(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj9ubh)}(hhh]j )}(hdma_data_directionh]hdma_data_direction}(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj9ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj9modnameN classnameNjj)}j]j9c.dma_buf_begin_cpu_accessasbuh1hhj9ubj)}(h h]h }(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj9ubj )}(h directionh]h direction}(hj:hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj9ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj>9ubeh}(h]h ]h"]h$]h&]jjuh1jhj9hhhj9hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj9hhhj9hMubah}(h]j8ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj9hMhj8hhubjA )}(hhh]h)}(hMust be called before accessing a dma_buf from the cpu in the kernel context. Calls begin_cpu_access to allow exporter-specific preparations. Coherency is only guaranteed in the specified range for the specified access direction.h]hMust be called before accessing a dma_buf from the cpu in the kernel context. Calls begin_cpu_access to allow exporter-specific preparations. Coherency is only guaranteed in the specified range for the specified access direction.}(hj,:hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj):hhubah}(h]h ]h"]h$]h&]uh1j@ hj8hhhj9hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jD:jc jD:jd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_buf *dmabuf`` [in] buffer to prepare cpu access for. ``enum dma_data_direction direction`` [in] direction of access. **Description** After the cpu access is complete the caller should call dma_buf_end_cpu_access(). Only when cpu access is bracketed by both calls is it guaranteed to be coherent with other DMA access. This function will also wait for any DMA transactions tracked through implicit synchronization in :c:type:`dma_buf.resv `. For DMA transactions with explicit synchronization this function will only ensure cache coherency, callers must ensure synchronization with such DMA transactions on their own. Can return negative error values, returns 0 on success.h](h)}(h**Parameters**h]jr )}(hjN:h]h Parameters}(hjP:hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjL:ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjH:ubj )}(hhh](j )}(hE``struct dma_buf *dmabuf`` [in] buffer to prepare cpu access for. h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjm:h]hstruct dma_buf *dmabuf}(hjo:hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjk:ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjg:ubj )}(hhh]h)}(h)[in] buffer to prepare cpu access for.h]h)[in] buffer to prepare cpu access for.}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj:hMhj:ubah}(h]h ]h"]h$]h&]uh1j hjg:ubeh}(h]h ]h"]h$]h&]uh1j hj:hMhjd:ubj )}(hC``enum dma_data_direction direction`` [in] direction of access. h](j )}(h%``enum dma_data_direction direction``h]j)}(hj:h]h!enum dma_data_direction direction}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj:ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj:ubj )}(hhh]h)}(h[in] direction of access.h]h[in] direction of access.}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj:hMhj:ubah}(h]h ]h"]h$]h&]uh1j hj:ubeh}(h]h ]h"]h$]h&]uh1j hj:hMhjd:ubeh}(h]h ]h"]h$]h&]uh1j hjH:ubh)}(h**Description**h]jr )}(hj:h]h Description}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj:ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjH:ubh)}(hAfter the cpu access is complete the caller should call dma_buf_end_cpu_access(). Only when cpu access is bracketed by both calls is it guaranteed to be coherent with other DMA access.h]hAfter the cpu access is complete the caller should call dma_buf_end_cpu_access(). Only when cpu access is bracketed by both calls is it guaranteed to be coherent with other DMA access.}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjH:ubh)}(hX3This function will also wait for any DMA transactions tracked through implicit synchronization in :c:type:`dma_buf.resv `. For DMA transactions with explicit synchronization this function will only ensure cache coherency, callers must ensure synchronization with such DMA transactions on their own.h](hbThis function will also wait for any DMA transactions tracked through implicit synchronization in }(hj;hhhNhNubh)}(h :c:type:`dma_buf.resv `h]j)}(hj;h]h dma_buf.resv}(hj;hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj;ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_bufuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj;ubh. For DMA transactions with explicit synchronization this function will only ensure cache coherency, callers must ensure synchronization with such DMA transactions on their own.}(hj;hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj-;hMhjH:ubh)}(h7Can return negative error values, returns 0 on success.h]h7Can return negative error values, returns 0 on success.}(hj8;hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjH:ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_buf_end_cpu_access (C function)c.dma_buf_end_cpu_accesshNtauh1jhjhhhNhNubj)}(hhh](j)}(hVint dma_buf_end_cpu_access (struct dma_buf *dmabuf, enum dma_data_direction direction)h]j)}(hUint dma_buf_end_cpu_access(struct dma_buf *dmabuf, enum dma_data_direction direction)h](jM)}(hinth]hint}(hjg;hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjc;hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMubj)}(h h]h }(hjv;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjc;hhhju;hMubj )}(hdma_buf_end_cpu_accessh]j )}(hdma_buf_end_cpu_accessh]hdma_buf_end_cpu_access}(hj;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj;ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjc;hhhju;hMubj)}(h;(struct dma_buf *dmabuf, enum dma_data_direction direction)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hj;hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj;ubj)}(h h]h }(hj;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj;ubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hj;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj;ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj;modnameN classnameNjj)}j]jO)}jGj;sbc.dma_buf_end_cpu_accessasbuh1hhj;ubj)}(h h]h }(hj;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj;ubjd)}(hjgh]h*}(hj;hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj;ubj )}(hdmabufh]hdmabuf}(hj;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj;ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj;ubj)}(h!enum dma_data_direction directionh](j)}(hj+h]henum}(hj<hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj<ubj)}(h h]h }(hj#<hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj<ubh)}(hhh]j )}(hdma_data_directionh]hdma_data_direction}(hj4<hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj1<ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj6<modnameN classnameNjj)}j]j;c.dma_buf_end_cpu_accessasbuh1hhj<ubj)}(h h]h }(hjR<hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj<ubj )}(h directionh]h direction}(hj`<hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj<ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj;ubeh}(h]h ]h"]h$]h&]jjuh1jhjc;hhhju;hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj_;hhhju;hMubah}(h]jZ;ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhju;hMhj\;hhubjA )}(hhh]h)}(hMust be called after accessing a dma_buf from the cpu in the kernel context. Calls end_cpu_access to allow exporter-specific actions. Coherency is only guaranteed in the specified range for the specified access direction.h]hMust be called after accessing a dma_buf from the cpu in the kernel context. Calls end_cpu_access to allow exporter-specific actions. Coherency is only guaranteed in the specified range for the specified access direction.}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj<hhubah}(h]h ]h"]h$]h&]uh1j@ hj\;hhhju;hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j<jc j<jd je jf uh1jhhhjhNhNubjh )}(hX,**Parameters** ``struct dma_buf *dmabuf`` [in] buffer to complete cpu access for. ``enum dma_data_direction direction`` [in] direction of access. **Description** This terminates CPU access started with dma_buf_begin_cpu_access(). Can return negative error values, returns 0 on success.h](h)}(h**Parameters**h]jr )}(hj<h]h Parameters}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj<ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj<ubj )}(hhh](j )}(hF``struct dma_buf *dmabuf`` [in] buffer to complete cpu access for. h](j )}(h``struct dma_buf *dmabuf``h]j)}(hj<h]hstruct dma_buf *dmabuf}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj<ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj<ubj )}(hhh]h)}(h*[in] buffer to complete cpu access for.h]h*[in] buffer to complete cpu access for.}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj<hMhj<ubah}(h]h ]h"]h$]h&]uh1j hj<ubeh}(h]h ]h"]h$]h&]uh1j hj<hMhj<ubj )}(hC``enum dma_data_direction direction`` [in] direction of access. h](j )}(h%``enum dma_data_direction direction``h]j)}(hj=h]h!enum dma_data_direction direction}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj=ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj<ubj )}(hhh]h)}(h[in] direction of access.h]h[in] direction of access.}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj=hMhj=ubah}(h]h ]h"]h$]h&]uh1j hj<ubeh}(h]h ]h"]h$]h&]uh1j hj=hMhj<ubeh}(h]h ]h"]h$]h&]uh1j hj<ubh)}(h**Description**h]jr )}(hj?=h]h Description}(hjA=hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj==ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM hj<ubh)}(hCThis terminates CPU access started with dma_buf_begin_cpu_access().h]hCThis terminates CPU access started with dma_buf_begin_cpu_access().}(hjU=hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj<ubh)}(h7Can return negative error values, returns 0 on success.h]h7Can return negative error values, returns 0 on success.}(hjd=hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM!hj<ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_mmap (C function)c.dma_buf_mmaphNtauh1jhjhhhNhNubj)}(hhh](j)}(hZint dma_buf_mmap (struct dma_buf *dmabuf, struct vm_area_struct *vma, unsigned long pgoff)h]j)}(hYint dma_buf_mmap(struct dma_buf *dmabuf, struct vm_area_struct *vma, unsigned long pgoff)h](jM)}(hinth]hint}(hj=hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj=hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM6ubj)}(h h]h }(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj=hhhj=hM6ubj )}(h dma_buf_mmaph]j )}(h dma_buf_mmaph]h dma_buf_mmap}(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj=ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj=hhhj=hM6ubj)}(hI(struct dma_buf *dmabuf, struct vm_area_struct *vma, unsigned long pgoff)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hj=hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj=ubj)}(h h]h }(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj=ubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj=ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj=modnameN classnameNjj)}j]jO)}jGj=sbc.dma_buf_mmapasbuh1hhj=ubj)}(h h]h }(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj=ubjd)}(hjgh]h*}(hj>hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj=ubj )}(hdmabufh]hdmabuf}(hj)>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj=ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj=ubj)}(hstruct vm_area_struct *vmah](j)}(hjh]hstruct}(hjB>hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj>>ubj)}(h h]h }(hjO>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj>>ubh)}(hhh]j )}(hvm_area_structh]hvm_area_struct}(hj`>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj]>ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjb>modnameN classnameNjj)}j]j >c.dma_buf_mmapasbuh1hhj>>ubj)}(h h]h }(hj~>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj>>ubjd)}(hjgh]h*}(hj>hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj>>ubj )}(hvmah]hvma}(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj>>ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj=ubj)}(hunsigned long pgoffh](jM)}(hunsignedh]hunsigned}(hj>hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj>ubj)}(h h]h }(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj>ubjM)}(hlongh]hlong}(hj>hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj>ubj)}(h h]h }(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj>ubj )}(hpgoffh]hpgoff}(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj>ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj=ubeh}(h]h ]h"]h$]h&]jjuh1jhj=hhhj=hM6ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj=hhhj=hM6ubah}(h]j=ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj=hM6hj=hhubjA )}(hhh]h)}(h,Setup up a userspace mmap with the given vmah]h,Setup up a userspace mmap with the given vma}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM6hj?hhubah}(h]h ]h"]h$]h&]uh1j@ hj=hhhj=hM6ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j,?jc j,?jd je jf uh1jhhhjhNhNubjh )}(hX<**Parameters** ``struct dma_buf *dmabuf`` [in] buffer that should back the vma ``struct vm_area_struct *vma`` [in] vma for the mmap ``unsigned long pgoff`` [in] offset in pages where this mmap should start within the dma-buf buffer. **Description** This function adjusts the passed in vma so that it points at the file of the dma_buf operation. It also adjusts the starting pgoff and does bounds checking on the size of the vma. Then it calls the exporters mmap function to set up the mapping. Can return negative error values, returns 0 on success.h](h)}(h**Parameters**h]jr )}(hj6?h]h Parameters}(hj8?hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj4?ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM:hj0?ubj )}(hhh](j )}(hC``struct dma_buf *dmabuf`` [in] buffer that should back the vma h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjU?h]hstruct dma_buf *dmabuf}(hjW?hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjS?ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM7hjO?ubj )}(hhh]h)}(h'[in] buffer that should back the vmah]h'[in] buffer that should back the vma}(hjn?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjj?hM7hjk?ubah}(h]h ]h"]h$]h&]uh1j hjO?ubeh}(h]h ]h"]h$]h&]uh1j hjj?hM7hjL?ubj )}(h8``struct vm_area_struct *vma`` [in] vma for the mmap h](j )}(h``struct vm_area_struct *vma``h]j)}(hj?h]hstruct vm_area_struct *vma}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj?ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM8hj?ubj )}(hhh]h)}(h[in] vma for the mmaph]h[in] vma for the mmap}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj?hM8hj?ubah}(h]h ]h"]h$]h&]uh1j hj?ubeh}(h]h ]h"]h$]h&]uh1j hj?hM8hjL?ubj )}(hh``unsigned long pgoff`` [in] offset in pages where this mmap should start within the dma-buf buffer. h](j )}(h``unsigned long pgoff``h]j)}(hj?h]hunsigned long pgoff}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj?ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM:hj?ubj )}(hhh]h)}(hO[in] offset in pages where this mmap should start within the dma-buf buffer.h]hO[in] offset in pages where this mmap should start within the dma-buf buffer.}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM9hj?ubah}(h]h ]h"]h$]h&]uh1j hj?ubeh}(h]h ]h"]h$]h&]uh1j hj?hM:hjL?ubeh}(h]h ]h"]h$]h&]uh1j hj0?ubh)}(h**Description**h]jr )}(hj@h]h Description}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj@ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM<hj0?ubh)}(hThis function adjusts the passed in vma so that it points at the file of the dma_buf operation. It also adjusts the starting pgoff and does bounds checking on the size of the vma. Then it calls the exporters mmap function to set up the mapping.h]hThis function adjusts the passed in vma so that it points at the file of the dma_buf operation. It also adjusts the starting pgoff and does bounds checking on the size of the vma. Then it calls the exporters mmap function to set up the mapping.}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM;hj0?ubh)}(h7Can return negative error values, returns 0 on success.h]h7Can return negative error values, returns 0 on success.}(hj(@hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chM@hj0?ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_vmap (C function)c.dma_buf_vmaphNtauh1jhjhhhNhNubj)}(hhh](j)}(h@int dma_buf_vmap (struct dma_buf *dmabuf, struct iosys_map *map)h]j)}(h?int dma_buf_vmap(struct dma_buf *dmabuf, struct iosys_map *map)h](jM)}(hinth]hint}(hjW@hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjS@hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMaubj)}(h h]h }(hjf@hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjS@hhhje@hMaubj )}(h dma_buf_vmaph]j )}(h dma_buf_vmaph]h dma_buf_vmap}(hjx@hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjt@ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjS@hhhje@hMaubj)}(h/(struct dma_buf *dmabuf, struct iosys_map *map)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hj@hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj@ubj)}(h h]h }(hj@hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj@ubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hj@hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj@ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj@modnameN classnameNjj)}j]jO)}jGjz@sbc.dma_buf_vmapasbuh1hhj@ubj)}(h h]h }(hj@hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj@ubjd)}(hjgh]h*}(hj@hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj@ubj )}(hdmabufh]hdmabuf}(hj@hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj@ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj@ubj)}(hstruct iosys_map *maph](j)}(hjh]hstruct}(hjAhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjAubj)}(h h]h }(hjAhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjAubh)}(hhh]j )}(h iosys_maph]h iosys_map}(hj$AhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj!Aubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj&AmodnameN classnameNjj)}j]j@c.dma_buf_vmapasbuh1hhjAubj)}(h h]h }(hjBAhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjAubjd)}(hjgh]h*}(hjPAhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjAubj )}(hmaph]hmap}(hj]AhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjAubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj@ubeh}(h]h ]h"]h$]h&]jjuh1jhjS@hhhje@hMaubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjO@hhhje@hMaubah}(h]jJ@ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhje@hMahjL@hhubjA )}(hhh]h)}(hxCreate virtual mapping for the buffer object into kernel address space. Same restrictions as for vmap and friends apply.h]hxCreate virtual mapping for the buffer object into kernel address space. Same restrictions as for vmap and friends apply.}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMahjAhhubah}(h]h ]h"]h$]h&]uh1j@ hjL@hhhje@hMaubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jAjc jAjd je jf uh1jhhhjhNhNubjh )}(hX%**Parameters** ``struct dma_buf *dmabuf`` [in] buffer to vmap ``struct iosys_map *map`` [out] returns the vmap pointer **Description** This call may fail due to lack of virtual mapping address space. These calls are optional in drivers. The intended use for them is for mapping objects linear in kernel space for high use objects. To ensure coherency users must call dma_buf_begin_cpu_access() and dma_buf_end_cpu_access() around any cpu access performed through this mapping. Returns 0 on success, or a negative errno code otherwise.h](h)}(h**Parameters**h]jr )}(hjAh]h Parameters}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjAubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMehjAubj )}(hhh](j )}(h2``struct dma_buf *dmabuf`` [in] buffer to vmap h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjAh]hstruct dma_buf *dmabuf}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjAubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMchjAubj )}(hhh]h)}(h[in] buffer to vmaph]h[in] buffer to vmap}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjAhMchjAubah}(h]h ]h"]h$]h&]uh1j hjAubeh}(h]h ]h"]h$]h&]uh1j hjAhMchjAubj )}(h;``struct iosys_map *map`` [out] returns the vmap pointer h](j )}(h``struct iosys_map *map``h]j)}(hjBh]hstruct iosys_map *map}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjAubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMdhjAubj )}(hhh]h)}(h [out] returns the vmap pointerh]h [out] returns the vmap pointer}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjBhMdhjBubah}(h]h ]h"]h$]h&]uh1j hjAubeh}(h]h ]h"]h$]h&]uh1j hjBhMdhjAubeh}(h]h ]h"]h$]h&]uh1j hjAubh)}(h**Description**h]jr )}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj:Bubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMfhjAubh)}(hThis call may fail due to lack of virtual mapping address space. These calls are optional in drivers. The intended use for them is for mapping objects linear in kernel space for high use objects.h]hThis call may fail due to lack of virtual mapping address space. These calls are optional in drivers. The intended use for them is for mapping objects linear in kernel space for high use objects.}(hjRBhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMehjAubh)}(hTo ensure coherency users must call dma_buf_begin_cpu_access() and dma_buf_end_cpu_access() around any cpu access performed through this mapping.h]hTo ensure coherency users must call dma_buf_begin_cpu_access() and dma_buf_end_cpu_access() around any cpu access performed through this mapping.}(hjaBhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMihjAubh)}(h9Returns 0 on success, or a negative errno code otherwise.h]h9Returns 0 on success, or a negative errno code otherwise.}(hjpBhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMmhjAubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j"dma_buf_vmap_unlocked (C function)c.dma_buf_vmap_unlockedhNtauh1jhjhhhNhNubj)}(hhh](j)}(hIint dma_buf_vmap_unlocked (struct dma_buf *dmabuf, struct iosys_map *map)h]j)}(hHint dma_buf_vmap_unlocked(struct dma_buf *dmabuf, struct iosys_map *map)h](jM)}(hinth]hint}(hjBhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjBhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMubj)}(h h]h }(hjBhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjBhhhjBhMubj )}(hdma_buf_vmap_unlockedh]j )}(hdma_buf_vmap_unlockedh]hdma_buf_vmap_unlocked}(hjBhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjBubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjBhhhjBhMubj)}(h/(struct dma_buf *dmabuf, struct iosys_map *map)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hjBhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjBubj)}(h h]h }(hjBhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjBubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hjBhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjBubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjBmodnameN classnameNjj)}j]jO)}jGjBsbc.dma_buf_vmap_unlockedasbuh1hhjBubj)}(h h]h }(hjChhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjBubjd)}(hjgh]h*}(hj(ChhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjBubj )}(hdmabufh]hdmabuf}(hj5ChhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjBubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjBubj)}(hstruct iosys_map *maph](j)}(hjh]hstruct}(hjNChhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjJCubj)}(h h]h }(hj[ChhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjJCubh)}(hhh]j )}(h iosys_maph]h iosys_map}(hjlChhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjiCubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjnCmodnameN classnameNjj)}j]jCc.dma_buf_vmap_unlockedasbuh1hhjJCubj)}(h h]h }(hjChhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjJCubjd)}(hjgh]h*}(hjChhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjJCubj )}(hmaph]hmap}(hjChhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjJCubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjBubeh}(h]h ]h"]h$]h&]jjuh1jhjBhhhjBhMubeh}(h]h ]Xh"]h$]h&]jjj2 uh1jj3 j4 hjBhhhjBhMubah}(h]jBah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjBhMhjBhhubjA )}(hhh]h)}(hxCreate virtual mapping for the buffer object into kernel address space. Same restrictions as for vmap and friends apply.h]hxCreate virtual mapping for the buffer object into kernel address space. Same restrictions as for vmap and friends apply.}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjChhubah}(h]h ]h"]h$]h&]uh1j@ hjBhhhjBhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jCjc jCjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_buf *dmabuf`` [in] buffer to vmap ``struct iosys_map *map`` [out] returns the vmap pointer **Description** Unlocked version of dma_buf_vmap() Returns 0 on success, or a negative errno code otherwise.h](h)}(h**Parameters**h]jr )}(hjCh]h Parameters}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjCubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjCubj )}(hhh](j )}(h2``struct dma_buf *dmabuf`` [in] buffer to vmap h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjDh]hstruct dma_buf *dmabuf}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjDubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj Dubj )}(hhh]h)}(h[in] buffer to vmaph]h[in] buffer to vmap}(hj)DhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj%DhMhj&Dubah}(h]h ]h"]h$]h&]uh1j hj Dubeh}(h]h ]h"]h$]h&]uh1j hj%DhMhjDubj )}(h;``struct iosys_map *map`` [out] returns the vmap pointer h](j )}(h``struct iosys_map *map``h]j)}(hjIDh]hstruct iosys_map *map}(hjKDhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjGDubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjCDubj )}(hhh]h)}(h [out] returns the vmap pointerh]h [out] returns the vmap pointer}(hjbDhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj^DhMhj_Dubah}(h]h ]h"]h$]h&]uh1j hjCDubeh}(h]h ]h"]h$]h&]uh1j hj^DhMhjDubeh}(h]h ]h"]h$]h&]uh1j hjCubh)}(h**Description**h]jr )}(hjDh]h Description}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjDubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjCubh)}(h"Unlocked version of dma_buf_vmap()h]h"Unlocked version of dma_buf_vmap()}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjCubh)}(h9Returns 0 on success, or a negative errno code otherwise.h]h9Returns 0 on success, or a negative errno code otherwise.}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjCubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_vunmap (C function)c.dma_buf_vunmaphNtauh1jhjhhhNhNubj)}(hhh](j)}(hCvoid dma_buf_vunmap (struct dma_buf *dmabuf, struct iosys_map *map)h]j)}(hBvoid dma_buf_vunmap(struct dma_buf *dmabuf, struct iosys_map *map)h](jM)}(hvoidh]hvoid}(hjDhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjDhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMubj)}(h h]h }(hjDhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjDhhhjDhMubj )}(hdma_buf_vunmaph]j )}(hdma_buf_vunmaph]hdma_buf_vunmap}(hjDhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjDubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjDhhhjDhMubj)}(h/(struct dma_buf *dmabuf, struct iosys_map *map)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hjEhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjEubj)}(h h]h }(hj"EhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjEubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hj3EhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj0Eubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj5EmodnameN classnameNjj)}j]jO)}jGjDsbc.dma_buf_vunmapasbuh1hhjEubj)}(h h]h }(hjSEhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjEubjd)}(hjgh]h*}(hjaEhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjEubj )}(hdmabufh]hdmabuf}(hjnEhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjEubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj Eubj)}(hstruct iosys_map *maph](j)}(hjh]hstruct}(hjEhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjEubj)}(h h]h }(hjEhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjEubh)}(hhh]j )}(h iosys_maph]h iosys_map}(hjEhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjEubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjEmodnameN classnameNjj)}j]jOEc.dma_buf_vunmapasbuh1hhjEubj)}(h h]h }(hjEhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjEubjd)}(hjgh]h*}(hjEhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjEubj )}(hmaph]hmap}(hjEhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjEubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj Eubeh}(h]h ]h"]h$]h&]jjuh1jhjDhhhjDhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjDhhhjDhMubah}(h]jDah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjDhMhjDhhubjA )}(hhh]h)}(h&Unmap a vmap obtained by dma_buf_vmap.h]h&Unmap a vmap obtained by dma_buf_vmap.}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjFhhubah}(h]h ]h"]h$]h&]uh1j@ hjDhhhjDhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j Fjc j Fjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_buf *dmabuf`` [in] buffer to vunmap ``struct iosys_map *map`` [in] vmap pointer to vunmaph](h)}(h**Parameters**h]jr )}(hj*Fh]h Parameters}(hj,FhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj(Fubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj$Fubj )}(hhh](j )}(h4``struct dma_buf *dmabuf`` [in] buffer to vunmap h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjIFh]hstruct dma_buf *dmabuf}(hjKFhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjGFubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjCFubj )}(hhh]h)}(h[in] buffer to vunmaph]h[in] buffer to vunmap}(hjbFhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj^FhMhj_Fubah}(h]h ]h"]h$]h&]uh1j hjCFubeh}(h]h ]h"]h$]h&]uh1j hj^FhMhj@Fubj )}(h8``struct iosys_map *map`` [in] vmap pointer to vunmaph](j )}(h``struct iosys_map *map``h]j)}(hjFh]hstruct iosys_map *map}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjFubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj|Fubj )}(hhh]h)}(h[in] vmap pointer to vunmaph]h[in] vmap pointer to vunmap}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjFubah}(h]h ]h"]h$]h&]uh1j hj|Fubeh}(h]h ]h"]h$]h&]uh1j hjFhMhj@Fubeh}(h]h ]h"]h$]h&]uh1j hj$Fubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j$dma_buf_vunmap_unlocked (C function)c.dma_buf_vunmap_unlockedhNtauh1jhjhhhNhNubj)}(hhh](j)}(hLvoid dma_buf_vunmap_unlocked (struct dma_buf *dmabuf, struct iosys_map *map)h]j)}(hKvoid dma_buf_vunmap_unlocked(struct dma_buf *dmabuf, struct iosys_map *map)h](jM)}(hvoidh]hvoid}(hjFhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjFhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMubj)}(h h]h }(hjFhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjFhhhjFhMubj )}(hdma_buf_vunmap_unlockedh]j )}(hdma_buf_vunmap_unlockedh]hdma_buf_vunmap_unlocked}(hjFhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjFubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjFhhhjFhMubj)}(h/(struct dma_buf *dmabuf, struct iosys_map *map)h](j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hjGhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjGubj)}(h h]h }(hj&GhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjGubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hj7GhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj4Gubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj9GmodnameN classnameNjj)}j]jO)}jGjFsbc.dma_buf_vunmap_unlockedasbuh1hhjGubj)}(h h]h }(hjWGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjGubjd)}(hjgh]h*}(hjeGhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjGubj )}(hdmabufh]hdmabuf}(hjrGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjGubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjGubj)}(hstruct iosys_map *maph](j)}(hjh]hstruct}(hjGhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjGubj)}(h h]h }(hjGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjGubh)}(hhh]j )}(h iosys_maph]h iosys_map}(hjGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjGubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjGmodnameN classnameNjj)}j]jSGc.dma_buf_vunmap_unlockedasbuh1hhjGubj)}(h h]h }(hjGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjGubjd)}(hjgh]h*}(hjGhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjGubj )}(hmaph]hmap}(hjGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjGubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjGubeh}(h]h ]h"]h$]h&]jjuh1jhjFhhhjFhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjFhhhjFhMubah}(h]jFah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjFhMhjFhhubjA )}(hhh]h)}(h&Unmap a vmap obtained by dma_buf_vmap.h]h&Unmap a vmap obtained by dma_buf_vmap.}(hj HhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj Hhhubah}(h]h ]h"]h$]h&]uh1j@ hjFhhhjFhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j$Hjc j$Hjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_buf *dmabuf`` [in] buffer to vunmap ``struct iosys_map *map`` [in] vmap pointer to vunmaph](h)}(h**Parameters**h]jr )}(hj.Hh]h Parameters}(hj0HhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj,Hubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhj(Hubj )}(hhh](j )}(h4``struct dma_buf *dmabuf`` [in] buffer to vunmap h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjMHh]hstruct dma_buf *dmabuf}(hjOHhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjKHubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjGHubj )}(hhh]h)}(h[in] buffer to vunmaph]h[in] buffer to vunmap}(hjfHhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjbHhMhjcHubah}(h]h ]h"]h$]h&]uh1j hjGHubeh}(h]h ]h"]h$]h&]uh1j hjbHhMhjDHubj )}(h8``struct iosys_map *map`` [in] vmap pointer to vunmaph](j )}(h``struct iosys_map *map``h]j)}(hjHh]hstruct iosys_map *map}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjHubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjHubj )}(hhh]h)}(h[in] vmap pointer to vunmaph]h[in] vmap pointer to vunmap}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:142: ./drivers/dma-buf/dma-buf.chMhjHubah}(h]h ]h"]h$]h&]uh1j hjHubeh}(h]h ]h"]h$]h&]uh1j hjHhMhjDHubeh}(h]h ]h"]h$]h&]uh1j hj(Hubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_ops (C struct) c.dma_buf_opshNtauh1jhjhhhNhNubj)}(hhh](j)}(h dma_buf_opsh]j)}(hstruct dma_buf_opsh](j)}(hjh]hstruct}(hjHhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjHhhh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKubj)}(h h]h }(hjHhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjHhhhjHhKubj )}(h dma_buf_opsh]j )}(hjHh]h dma_buf_ops}(hjIhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjHubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjHhhhjHhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjHhhhjHhKubah}(h]jHah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjHhKhjHhhubjA )}(hhh]h)}(h%operations possible on struct dma_bufh]h%operations possible on struct dma_buf}(hj"IhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK hjIhhubah}(h]h ]h"]h$]h&]uh1j@ hjHhhhjHhKubeh}(h]h ](jstructeh"]h$]h&]ja jjb j:Ijc j:Ijd je jf uh1jhhhjhNhNubjh )}(hXg#**Definition**:: struct dma_buf_ops { int (*attach)(struct dma_buf *, struct dma_buf_attachment *); void (*detach)(struct dma_buf *, struct dma_buf_attachment *); int (*pin)(struct dma_buf_attachment *attach); void (*unpin)(struct dma_buf_attachment *attach); struct sg_table * (*map_dma_buf)(struct dma_buf_attachment *, enum dma_data_direction); void (*unmap_dma_buf)(struct dma_buf_attachment *, struct sg_table *, enum dma_data_direction); void (*release)(struct dma_buf *); int (*begin_cpu_access)(struct dma_buf *, enum dma_data_direction); int (*end_cpu_access)(struct dma_buf *, enum dma_data_direction); int (*mmap)(struct dma_buf *, struct vm_area_struct *vma); int (*vmap)(struct dma_buf *dmabuf, struct iosys_map *map); void (*vunmap)(struct dma_buf *dmabuf, struct iosys_map *map); }; **Members** ``attach`` This is called from dma_buf_attach() to make sure that a given :c:type:`dma_buf_attachment.dev ` can access the provided :c:type:`dma_buf`. Exporters which support buffer objects in special locations like VRAM or device-specific carveout areas should check whether the buffer could be move to system memory (or directly accessed by the provided device), and otherwise need to fail the attach operation. The exporter should also in general check whether the current allocation fulfills the DMA constraints of the new device. If this is not the case, and the allocation cannot be moved, it should also fail the attach operation. Any exporter-private housekeeping data can be stored in the :c:type:`dma_buf_attachment.priv ` pointer. This callback is optional. Returns: 0 on success, negative error code on failure. It might return -EBUSY to signal that backing storage is already allocated and incompatible with the requirements of requesting device. ``detach`` This is called by dma_buf_detach() to release a :c:type:`dma_buf_attachment`. Provided so that exporters can clean up any housekeeping for an :c:type:`dma_buf_attachment`. This callback is optional. ``pin`` This is called by dma_buf_pin() and lets the exporter know that the DMA-buf can't be moved any more. Ideally, the exporter should pin the buffer so that it is generally accessible by all devices. This is called with the :c:type:`dmabuf.resv ` object locked and is mutual exclusive with **cache_sgt_mapping**. This is called automatically for non-dynamic importers from dma_buf_attach(). Note that similar to non-dynamic exporters in their **map_dma_buf** callback the driver must guarantee that the memory is available for use and cleared of any old data by the time this function returns. Drivers which pipeline their buffer moves internally must wait for all moves and clears to complete. Returns: 0 on success, negative error code on failure. ``unpin`` This is called by dma_buf_unpin() and lets the exporter know that the DMA-buf can be moved again. This is called with the dmabuf->resv object locked and is mutual exclusive with **cache_sgt_mapping**. This callback is optional. ``map_dma_buf`` This is called by dma_buf_map_attachment() and is used to map a shared :c:type:`dma_buf` into device address space, and it is mandatory. It can only be called if **attach** has been called successfully. This call may sleep, e.g. when the backing storage first needs to be allocated, or moved to a location suitable for all currently attached devices. Note that any specific buffer attributes required for this function should get added to device_dma_parameters accessible via :c:type:`device.dma_params ` from the :c:type:`dma_buf_attachment`. The **attach** callback should also check these constraints. If this is being called for the first time, the exporter can now choose to scan through the list of attachments for this buffer, collate the requirements of the attached devices, and choose an appropriate backing storage for the buffer. Based on enum dma_data_direction, it might be possible to have multiple users accessing at the same time (for reading, maybe), or any other kind of sharing that the exporter might wish to make available to buffer-users. This is always called with the dmabuf->resv object locked when the dynamic_mapping flag is true. Note that for non-dynamic exporters the driver must guarantee that that the memory is available for use and cleared of any old data by the time this function returns. Drivers which pipeline their buffer moves internally must wait for all moves and clears to complete. Dynamic exporters do not need to follow this rule: For non-dynamic importers the buffer is already pinned through **pin**, which has the same requirements. Dynamic importers otoh are required to obey the dma_resv fences. Returns: A :c:type:`sg_table` scatter list of the backing storage of the DMA buffer, already mapped into the device address space of the :c:type:`device` attached with the provided :c:type:`dma_buf_attachment`. The addresses and lengths in the scatter list are PAGE_SIZE aligned. On failure, returns a negative error value wrapped into a pointer. May also return -EINTR when a signal was received while being blocked. Note that exporters should not try to cache the scatter list, or return the same one for multiple calls. Caching is done either by the DMA-BUF code (for non-dynamic importers) or the importer. Ownership of the scatter list is transferred to the caller, and returned by **unmap_dma_buf**. ``unmap_dma_buf`` This is called by dma_buf_unmap_attachment() and should unmap and release the :c:type:`sg_table` allocated in **map_dma_buf**, and it is mandatory. For static dma_buf handling this might also unpin the backing storage if this is the last mapping of the DMA buffer. ``release`` Called after the last dma_buf_put to release the :c:type:`dma_buf`, and mandatory. ``begin_cpu_access`` This is called from dma_buf_begin_cpu_access() and allows the exporter to ensure that the memory is actually coherent for cpu access. The exporter also needs to ensure that cpu access is coherent for the access direction. The direction can be used by the exporter to optimize the cache flushing, i.e. access with a different direction (read instead of write) might return stale or even bogus data (e.g. when the exporter needs to copy the data to temporary storage). Note that this is both called through the DMA_BUF_IOCTL_SYNC IOCTL command for userspace mappings established through **mmap**, and also for kernel mappings established with **vmap**. This callback is optional. Returns: 0 on success or a negative error code on failure. This can for example fail when the backing storage can't be allocated. Can also return -ERESTARTSYS or -EINTR when the call has been interrupted and needs to be restarted. ``end_cpu_access`` This is called from dma_buf_end_cpu_access() when the importer is done accessing the CPU. The exporter can use this to flush caches and undo anything else done in **begin_cpu_access**. This callback is optional. Returns: 0 on success or a negative error code on failure. Can return -ERESTARTSYS or -EINTR when the call has been interrupted and needs to be restarted. ``mmap`` This callback is used by the dma_buf_mmap() function Note that the mapping needs to be incoherent, userspace is expected to bracket CPU access using the DMA_BUF_IOCTL_SYNC interface. Because dma-buf buffers have invariant size over their lifetime, the dma-buf core checks whether a vma is too large and rejects such mappings. The exporter hence does not need to duplicate this check. Drivers do not need to check this themselves. If an exporter needs to manually flush caches and hence needs to fake coherency for mmap support, it needs to be able to zap all the ptes pointing at the backing storage. Now linux mm needs a struct address_space associated with the struct file stored in vma->vm_file to do that with the function unmap_mapping_range. But the dma_buf framework only backs every dma_buf fd with the anon_file struct file, i.e. all dma_bufs share the same file. Hence exporters need to setup their own file (and address_space) association by setting vma->vm_file and adjusting vma->vm_pgoff in the dma_buf mmap callback. In the specific case of a gem driver the exporter could use the shmem file already provided by gem (and set vm_pgoff = 0). Exporters can then zap ptes by unmapping the corresponding range of the struct address_space associated with their own file. This callback is optional. Returns: 0 on success or a negative error code on failure. ``vmap`` [optional] creates a virtual mapping for the buffer into kernel address space. Same restrictions as for vmap and friends apply. ``vunmap`` [optional] unmaps a vmap from the bufferh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjFIhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjBIubh:}(hjBIhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK$hj>Iubj)}(hX<struct dma_buf_ops { int (*attach)(struct dma_buf *, struct dma_buf_attachment *); void (*detach)(struct dma_buf *, struct dma_buf_attachment *); int (*pin)(struct dma_buf_attachment *attach); void (*unpin)(struct dma_buf_attachment *attach); struct sg_table * (*map_dma_buf)(struct dma_buf_attachment *, enum dma_data_direction); void (*unmap_dma_buf)(struct dma_buf_attachment *, struct sg_table *, enum dma_data_direction); void (*release)(struct dma_buf *); int (*begin_cpu_access)(struct dma_buf *, enum dma_data_direction); int (*end_cpu_access)(struct dma_buf *, enum dma_data_direction); int (*mmap)(struct dma_buf *, struct vm_area_struct *vma); int (*vmap)(struct dma_buf *dmabuf, struct iosys_map *map); void (*vunmap)(struct dma_buf *dmabuf, struct iosys_map *map); };h]hX<struct dma_buf_ops { int (*attach)(struct dma_buf *, struct dma_buf_attachment *); void (*detach)(struct dma_buf *, struct dma_buf_attachment *); int (*pin)(struct dma_buf_attachment *attach); void (*unpin)(struct dma_buf_attachment *attach); struct sg_table * (*map_dma_buf)(struct dma_buf_attachment *, enum dma_data_direction); void (*unmap_dma_buf)(struct dma_buf_attachment *, struct sg_table *, enum dma_data_direction); void (*release)(struct dma_buf *); int (*begin_cpu_access)(struct dma_buf *, enum dma_data_direction); int (*end_cpu_access)(struct dma_buf *, enum dma_data_direction); int (*mmap)(struct dma_buf *, struct vm_area_struct *vma); int (*vmap)(struct dma_buf *dmabuf, struct iosys_map *map); void (*vunmap)(struct dma_buf *dmabuf, struct iosys_map *map); };}hj_Isbah}(h]h ]h"]h$]h&]jjuh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK&hj>Iubh)}(h **Members**h]jr )}(hjpIh]hMembers}(hjrIhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjnIubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK5hj>Iubj )}(hhh](j )}(hX``attach`` This is called from dma_buf_attach() to make sure that a given :c:type:`dma_buf_attachment.dev ` can access the provided :c:type:`dma_buf`. Exporters which support buffer objects in special locations like VRAM or device-specific carveout areas should check whether the buffer could be move to system memory (or directly accessed by the provided device), and otherwise need to fail the attach operation. The exporter should also in general check whether the current allocation fulfills the DMA constraints of the new device. If this is not the case, and the allocation cannot be moved, it should also fail the attach operation. Any exporter-private housekeeping data can be stored in the :c:type:`dma_buf_attachment.priv ` pointer. This callback is optional. Returns: 0 on success, negative error code on failure. It might return -EBUSY to signal that backing storage is already allocated and incompatible with the requirements of requesting device. h](j )}(h ``attach``h]j)}(hjIh]hattach}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjIubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK=hjIubj )}(hhh](h)}(hXThis is called from dma_buf_attach() to make sure that a given :c:type:`dma_buf_attachment.dev ` can access the provided :c:type:`dma_buf`. Exporters which support buffer objects in special locations like VRAM or device-specific carveout areas should check whether the buffer could be move to system memory (or directly accessed by the provided device), and otherwise need to fail the attach operation.h](h?This is called from dma_buf_attach() to make sure that a given }(hjIhhhNhNubh)}(h5:c:type:`dma_buf_attachment.dev `h]j)}(hjIh]hdma_buf_attachment.dev}(hjIhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjIubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_attachmentuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK(hjIubh can access the provided }(hjIhhhNhNubh)}(h:c:type:`dma_buf`h]j)}(hjIh]hdma_buf}(hjIhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjIubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_bufuh1hhjIhK(hjIubhX. Exporters which support buffer objects in special locations like VRAM or device-specific carveout areas should check whether the buffer could be move to system memory (or directly accessed by the provided device), and otherwise need to fail the attach operation.}(hjIhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjIhK(hjIubh)}(hThe exporter should also in general check whether the current allocation fulfills the DMA constraints of the new device. If this is not the case, and the allocation cannot be moved, it should also fail the attach operation.h]hThe exporter should also in general check whether the current allocation fulfills the DMA constraints of the new device. If this is not the case, and the allocation cannot be moved, it should also fail the attach operation.}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK/hjIubh)}(h{Any exporter-private housekeeping data can be stored in the :c:type:`dma_buf_attachment.priv ` pointer.h](h`h]j)}(hjJh]hdma_buf_attachment.priv}(hjJhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjJubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_attachmentuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK4hj Jubh pointer.}(hj JhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj3JhK4hjIubh)}(hThis callback is optional.h]hThis callback is optional.}(hj>JhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK7hjIubh)}(hReturns:h]hReturns:}(hjMJhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK9hjIubh)}(h0 on success, negative error code on failure. It might return -EBUSY to signal that backing storage is already allocated and incompatible with the requirements of requesting device.h]h0 on success, negative error code on failure. It might return -EBUSY to signal that backing storage is already allocated and incompatible with the requirements of requesting device.}(hj\JhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK;hjIubeh}(h]h ]h"]h$]h&]uh1j hjIubeh}(h]h ]h"]h$]h&]uh1j hjIhK=hjIubj )}(h``detach`` This is called by dma_buf_detach() to release a :c:type:`dma_buf_attachment`. Provided so that exporters can clean up any housekeeping for an :c:type:`dma_buf_attachment`. This callback is optional. h](j )}(h ``detach``h]j)}(hj}Jh]hdetach}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj{Jubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKHhjwJubj )}(hhh](h)}(hThis is called by dma_buf_detach() to release a :c:type:`dma_buf_attachment`. Provided so that exporters can clean up any housekeeping for an :c:type:`dma_buf_attachment`.h](h0This is called by dma_buf_detach() to release a }(hjJhhhNhNubh)}(h:c:type:`dma_buf_attachment`h]j)}(hjJh]hdma_buf_attachment}(hjJhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjJubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_attachmentuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKDhjJubhB. Provided so that exporters can clean up any housekeeping for an }(hjJhhhNhNubh)}(h:c:type:`dma_buf_attachment`h]j)}(hjJh]hdma_buf_attachment}(hjJhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjJubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_attachmentuh1hhjJhKDhjJubh.}(hjJhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjJhKDhjJubh)}(hThis callback is optional.h]hThis callback is optional.}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjJhKHhjJubeh}(h]h ]h"]h$]h&]uh1j hjwJubeh}(h]h ]h"]h$]h&]uh1j hjJhKHhjIubj )}(hX``pin`` This is called by dma_buf_pin() and lets the exporter know that the DMA-buf can't be moved any more. Ideally, the exporter should pin the buffer so that it is generally accessible by all devices. This is called with the :c:type:`dmabuf.resv ` object locked and is mutual exclusive with **cache_sgt_mapping**. This is called automatically for non-dynamic importers from dma_buf_attach(). Note that similar to non-dynamic exporters in their **map_dma_buf** callback the driver must guarantee that the memory is available for use and cleared of any old data by the time this function returns. Drivers which pipeline their buffer moves internally must wait for all moves and clears to complete. Returns: 0 on success, negative error code on failure. h](j )}(h``pin``h]j)}(hj Kh]hpin}(hj KhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj Kubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKbhjKubj )}(hhh](h)}(hThis is called by dma_buf_pin() and lets the exporter know that the DMA-buf can't be moved any more. Ideally, the exporter should pin the buffer so that it is generally accessible by all devices.h]hThis is called by dma_buf_pin() and lets the exporter know that the DMA-buf can’t be moved any more. Ideally, the exporter should pin the buffer so that it is generally accessible by all devices.}(hj$KhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKOhj!Kubh)}(hxThis is called with the :c:type:`dmabuf.resv ` object locked and is mutual exclusive with **cache_sgt_mapping**.h](hThis is called with the }(hj3KhhhNhNubh)}(h:c:type:`dmabuf.resv `h]j)}(hj=Kh]h dmabuf.resv}(hj?KhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj;Kubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdmabufuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKThj3Kubh, object locked and is mutual exclusive with }(hj3KhhhNhNubjr )}(h**cache_sgt_mapping**h]hcache_sgt_mapping}(hj_KhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj3Kubh.}(hj3KhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjZKhKThj!Kubh)}(hMThis is called automatically for non-dynamic importers from dma_buf_attach().h]hMThis is called automatically for non-dynamic importers from dma_buf_attach().}(hjwKhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKWhj!Kubh)}(hX/Note that similar to non-dynamic exporters in their **map_dma_buf** callback the driver must guarantee that the memory is available for use and cleared of any old data by the time this function returns. Drivers which pipeline their buffer moves internally must wait for all moves and clears to complete.h](h4Note that similar to non-dynamic exporters in their }(hjKhhhNhNubjr )}(h**map_dma_buf**h]h map_dma_buf}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjKubh callback the driver must guarantee that the memory is available for use and cleared of any old data by the time this function returns. Drivers which pipeline their buffer moves internally must wait for all moves and clears to complete.}(hjKhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKZhj!Kubh)}(hReturns:h]hReturns:}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK`hj!Kubh)}(h-0 on success, negative error code on failure.h]h-0 on success, negative error code on failure.}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj KhKbhj!Kubeh}(h]h ]h"]h$]h&]uh1j hjKubeh}(h]h ]h"]h$]h&]uh1j hj KhKbhjIubj )}(h``unpin`` This is called by dma_buf_unpin() and lets the exporter know that the DMA-buf can be moved again. This is called with the dmabuf->resv object locked and is mutual exclusive with **cache_sgt_mapping**. This callback is optional. h](j )}(h ``unpin``h]j)}(hjKh]hunpin}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjKubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKohjKubj )}(hhh](h)}(haThis is called by dma_buf_unpin() and lets the exporter know that the DMA-buf can be moved again.h]haThis is called by dma_buf_unpin() and lets the exporter know that the DMA-buf can be moved again.}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKihjKubh)}(hfThis is called with the dmabuf->resv object locked and is mutual exclusive with **cache_sgt_mapping**.h](hPThis is called with the dmabuf->resv object locked and is mutual exclusive with }(hjKhhhNhNubjr )}(h**cache_sgt_mapping**h]hcache_sgt_mapping}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjKubh.}(hjKhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKlhjKubh)}(hThis callback is optional.h]hThis callback is optional.}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjKhKohjKubeh}(h]h ]h"]h$]h&]uh1j hjKubeh}(h]h ]h"]h$]h&]uh1j hjKhKohjIubj )}(hXU ``map_dma_buf`` This is called by dma_buf_map_attachment() and is used to map a shared :c:type:`dma_buf` into device address space, and it is mandatory. It can only be called if **attach** has been called successfully. This call may sleep, e.g. when the backing storage first needs to be allocated, or moved to a location suitable for all currently attached devices. Note that any specific buffer attributes required for this function should get added to device_dma_parameters accessible via :c:type:`device.dma_params ` from the :c:type:`dma_buf_attachment`. The **attach** callback should also check these constraints. If this is being called for the first time, the exporter can now choose to scan through the list of attachments for this buffer, collate the requirements of the attached devices, and choose an appropriate backing storage for the buffer. Based on enum dma_data_direction, it might be possible to have multiple users accessing at the same time (for reading, maybe), or any other kind of sharing that the exporter might wish to make available to buffer-users. This is always called with the dmabuf->resv object locked when the dynamic_mapping flag is true. Note that for non-dynamic exporters the driver must guarantee that that the memory is available for use and cleared of any old data by the time this function returns. Drivers which pipeline their buffer moves internally must wait for all moves and clears to complete. Dynamic exporters do not need to follow this rule: For non-dynamic importers the buffer is already pinned through **pin**, which has the same requirements. Dynamic importers otoh are required to obey the dma_resv fences. Returns: A :c:type:`sg_table` scatter list of the backing storage of the DMA buffer, already mapped into the device address space of the :c:type:`device` attached with the provided :c:type:`dma_buf_attachment`. The addresses and lengths in the scatter list are PAGE_SIZE aligned. On failure, returns a negative error value wrapped into a pointer. May also return -EINTR when a signal was received while being blocked. Note that exporters should not try to cache the scatter list, or return the same one for multiple calls. Caching is done either by the DMA-BUF code (for non-dynamic importers) or the importer. Ownership of the scatter list is transferred to the caller, and returned by **unmap_dma_buf**. h](j )}(h``map_dma_buf``h]j)}(hj?Lh]h map_dma_buf}(hjALhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj=Lubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhj9Lubj )}(hhh](h)}(hThis is called by dma_buf_map_attachment() and is used to map a shared :c:type:`dma_buf` into device address space, and it is mandatory. It can only be called if **attach** has been called successfully.h](hGThis is called by dma_buf_map_attachment() and is used to map a shared }(hjXLhhhNhNubh)}(h:c:type:`dma_buf`h]j)}(hjbLh]hdma_buf}(hjdLhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj`Lubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_bufuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKvhjXLubhJ into device address space, and it is mandatory. It can only be called if }(hjXLhhhNhNubjr )}(h **attach**h]hattach}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjXLubh has been called successfully.}(hjXLhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjLhKvhjULubh)}(hThis call may sleep, e.g. when the backing storage first needs to be allocated, or moved to a location suitable for all currently attached devices.h]hThis call may sleep, e.g. when the backing storage first needs to be allocated, or moved to a location suitable for all currently attached devices.}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKzhjULubh)}(hXNote that any specific buffer attributes required for this function should get added to device_dma_parameters accessible via :c:type:`device.dma_params ` from the :c:type:`dma_buf_attachment`. The **attach** callback should also check these constraints.h](h}Note that any specific buffer attributes required for this function should get added to device_dma_parameters accessible via }(hjLhhhNhNubh)}(h$:c:type:`device.dma_params `h]j)}(hjLh]hdevice.dma_params}(hjLhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjLubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdeviceuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK~hjLubh from the }(hjLhhhNhNubh)}(h:c:type:`dma_buf_attachment`h]j)}(hjLh]hdma_buf_attachment}(hjLhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjLubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_attachmentuh1hhjLhK~hjLubh. The }(hjLhhhNhNubjr )}(h **attach**h]hattach}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjLubh. callback should also check these constraints.}(hjLhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjLhK~hjULubh)}(hIf this is being called for the first time, the exporter can now choose to scan through the list of attachments for this buffer, collate the requirements of the attached devices, and choose an appropriate backing storage for the buffer.h]hIf this is being called for the first time, the exporter can now choose to scan through the list of attachments for this buffer, collate the requirements of the attached devices, and choose an appropriate backing storage for the buffer.}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjULubh)}(hBased on enum dma_data_direction, it might be possible to have multiple users accessing at the same time (for reading, maybe), or any other kind of sharing that the exporter might wish to make available to buffer-users.h]hBased on enum dma_data_direction, it might be possible to have multiple users accessing at the same time (for reading, maybe), or any other kind of sharing that the exporter might wish to make available to buffer-users.}(hj!MhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjULubh)}(h`This is always called with the dmabuf->resv object locked when the dynamic_mapping flag is true.h]h`This is always called with the dmabuf->resv object locked when the dynamic_mapping flag is true.}(hj0MhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjULubh)}(hXNote that for non-dynamic exporters the driver must guarantee that that the memory is available for use and cleared of any old data by the time this function returns. Drivers which pipeline their buffer moves internally must wait for all moves and clears to complete. Dynamic exporters do not need to follow this rule: For non-dynamic importers the buffer is already pinned through **pin**, which has the same requirements. Dynamic importers otoh are required to obey the dma_resv fences.h](hXNote that for non-dynamic exporters the driver must guarantee that that the memory is available for use and cleared of any old data by the time this function returns. Drivers which pipeline their buffer moves internally must wait for all moves and clears to complete. Dynamic exporters do not need to follow this rule: For non-dynamic importers the buffer is already pinned through }(hj?MhhhNhNubjr )}(h**pin**h]hpin}(hjGMhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj?Mubhc, which has the same requirements. Dynamic importers otoh are required to obey the dma_resv fences.}(hj?MhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjULubh)}(hReturns:h]hReturns:}(hj`MhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjULubh)}(hXA :c:type:`sg_table` scatter list of the backing storage of the DMA buffer, already mapped into the device address space of the :c:type:`device` attached with the provided :c:type:`dma_buf_attachment`. The addresses and lengths in the scatter list are PAGE_SIZE aligned.h](hA }(hjoMhhhNhNubh)}(h:c:type:`sg_table`h]j)}(hjyMh]hsg_table}(hj{MhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjwMubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjsg_tableuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjoMubhl scatter list of the backing storage of the DMA buffer, already mapped into the device address space of the }(hjoMhhhNhNubh)}(h:c:type:`device`h]j)}(hjMh]hdevice}(hjMhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjMubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdeviceuh1hhjMhKhjoMubh attached with the provided }(hjoMhhhNhNubh)}(h:c:type:`dma_buf_attachment`h]j)}(hjMh]hdma_buf_attachment}(hjMhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjMubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_attachmentuh1hhjMhKhjoMubhF. The addresses and lengths in the scatter list are PAGE_SIZE aligned.}(hjoMhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjMhKhjULubh)}(hOn failure, returns a negative error value wrapped into a pointer. May also return -EINTR when a signal was received while being blocked.h]hOn failure, returns a negative error value wrapped into a pointer. May also return -EINTR when a signal was received while being blocked.}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjULubh)}(hXNote that exporters should not try to cache the scatter list, or return the same one for multiple calls. Caching is done either by the DMA-BUF code (for non-dynamic importers) or the importer. Ownership of the scatter list is transferred to the caller, and returned by **unmap_dma_buf**.h](hX Note that exporters should not try to cache the scatter list, or return the same one for multiple calls. Caching is done either by the DMA-BUF code (for non-dynamic importers) or the importer. Ownership of the scatter list is transferred to the caller, and returned by }(hjMhhhNhNubjr )}(h**unmap_dma_buf**h]h unmap_dma_buf}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjMubh.}(hjMhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjULubeh}(h]h ]h"]h$]h&]uh1j hj9Lubeh}(h]h ]h"]h$]h&]uh1j hjTLhKhjIubj )}(hX``unmap_dma_buf`` This is called by dma_buf_unmap_attachment() and should unmap and release the :c:type:`sg_table` allocated in **map_dma_buf**, and it is mandatory. For static dma_buf handling this might also unpin the backing storage if this is the last mapping of the DMA buffer. h](j )}(h``unmap_dma_buf``h]j)}(hj)Nh]h unmap_dma_buf}(hj+NhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj'Nubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhj#Nubj )}(hhh]h)}(hXThis is called by dma_buf_unmap_attachment() and should unmap and release the :c:type:`sg_table` allocated in **map_dma_buf**, and it is mandatory. For static dma_buf handling this might also unpin the backing storage if this is the last mapping of the DMA buffer.h](hNThis is called by dma_buf_unmap_attachment() and should unmap and release the }(hjBNhhhNhNubh)}(h:c:type:`sg_table`h]j)}(hjLNh]hsg_table}(hjNNhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjJNubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjsg_tableuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjBNubh allocated in }(hjBNhhhNhNubjr )}(h**map_dma_buf**h]h map_dma_buf}(hjnNhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjBNubh, and it is mandatory. For static dma_buf handling this might also unpin the backing storage if this is the last mapping of the DMA buffer.}(hjBNhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjiNhKhj?Nubah}(h]h ]h"]h$]h&]uh1j hj#Nubeh}(h]h ]h"]h$]h&]uh1j hj>NhKhjIubj )}(h_``release`` Called after the last dma_buf_put to release the :c:type:`dma_buf`, and mandatory. h](j )}(h ``release``h]j)}(hjNh]hrelease}(hjNhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjNubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjNubj )}(hhh]h)}(hRCalled after the last dma_buf_put to release the :c:type:`dma_buf`, and mandatory.h](h1Called after the last dma_buf_put to release the }(hjNhhhNhNubh)}(h:c:type:`dma_buf`h]j)}(hjNh]hdma_buf}(hjNhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjNubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_bufuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjNubh, and mandatory.}(hjNhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjNhKhjNubah}(h]h ]h"]h$]h&]uh1j hjNubeh}(h]h ]h"]h$]h&]uh1j hjNhKhjIubj )}(hX``begin_cpu_access`` This is called from dma_buf_begin_cpu_access() and allows the exporter to ensure that the memory is actually coherent for cpu access. The exporter also needs to ensure that cpu access is coherent for the access direction. The direction can be used by the exporter to optimize the cache flushing, i.e. access with a different direction (read instead of write) might return stale or even bogus data (e.g. when the exporter needs to copy the data to temporary storage). Note that this is both called through the DMA_BUF_IOCTL_SYNC IOCTL command for userspace mappings established through **mmap**, and also for kernel mappings established with **vmap**. This callback is optional. Returns: 0 on success or a negative error code on failure. This can for example fail when the backing storage can't be allocated. Can also return -ERESTARTSYS or -EINTR when the call has been interrupted and needs to be restarted. h](j )}(h``begin_cpu_access``h]j)}(hjNh]hbegin_cpu_access}(hjNhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjNubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjNubj )}(hhh](h)}(hXThis is called from dma_buf_begin_cpu_access() and allows the exporter to ensure that the memory is actually coherent for cpu access. The exporter also needs to ensure that cpu access is coherent for the access direction. The direction can be used by the exporter to optimize the cache flushing, i.e. access with a different direction (read instead of write) might return stale or even bogus data (e.g. when the exporter needs to copy the data to temporary storage).h]hXThis is called from dma_buf_begin_cpu_access() and allows the exporter to ensure that the memory is actually coherent for cpu access. The exporter also needs to ensure that cpu access is coherent for the access direction. The direction can be used by the exporter to optimize the cache flushing, i.e. access with a different direction (read instead of write) might return stale or even bogus data (e.g. when the exporter needs to copy the data to temporary storage).}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhj Oubh)}(hNote that this is both called through the DMA_BUF_IOCTL_SYNC IOCTL command for userspace mappings established through **mmap**, and also for kernel mappings established with **vmap**.h](hvNote that this is both called through the DMA_BUF_IOCTL_SYNC IOCTL command for userspace mappings established through }(hjOhhhNhNubjr )}(h**mmap**h]hmmap}(hj%OhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjOubh0, and also for kernel mappings established with }(hjOhhhNhNubjr )}(h**vmap**h]hvmap}(hj7OhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjOubh.}(hjOhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhj Oubh)}(hThis callback is optional.h]hThis callback is optional.}(hjPOhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhj Oubh)}(hReturns:h]hReturns:}(hj_OhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhj Oubh)}(h0 on success or a negative error code on failure. This can for example fail when the backing storage can't be allocated. Can also return -ERESTARTSYS or -EINTR when the call has been interrupted and needs to be restarted.h]h0 on success or a negative error code on failure. This can for example fail when the backing storage can’t be allocated. Can also return -ERESTARTSYS or -EINTR when the call has been interrupted and needs to be restarted.}(hjnOhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhj Oubeh}(h]h ]h"]h$]h&]uh1j hjNubeh}(h]h ]h"]h$]h&]uh1j hj OhKhjIubj )}(hX``end_cpu_access`` This is called from dma_buf_end_cpu_access() when the importer is done accessing the CPU. The exporter can use this to flush caches and undo anything else done in **begin_cpu_access**. This callback is optional. Returns: 0 on success or a negative error code on failure. Can return -ERESTARTSYS or -EINTR when the call has been interrupted and needs to be restarted. h](j )}(h``end_cpu_access``h]j)}(hjOh]hend_cpu_access}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjOubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjOubj )}(hhh](h)}(hThis is called from dma_buf_end_cpu_access() when the importer is done accessing the CPU. The exporter can use this to flush caches and undo anything else done in **begin_cpu_access**.h](hThis is called from dma_buf_end_cpu_access() when the importer is done accessing the CPU. The exporter can use this to flush caches and undo anything else done in }(hjOhhhNhNubjr )}(h**begin_cpu_access**h]hbegin_cpu_access}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjOubh.}(hjOhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjOubh)}(hThis callback is optional.h]hThis callback is optional.}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjOubh)}(hReturns:h]hReturns:}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjOubh)}(h0 on success or a negative error code on failure. Can return -ERESTARTSYS or -EINTR when the call has been interrupted and needs to be restarted.h]h0 on success or a negative error code on failure. Can return -ERESTARTSYS or -EINTR when the call has been interrupted and needs to be restarted.}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjOubeh}(h]h ]h"]h$]h&]uh1j hjOubeh}(h]h ]h"]h$]h&]uh1j hjOhKhjIubj )}(hXf``mmap`` This callback is used by the dma_buf_mmap() function Note that the mapping needs to be incoherent, userspace is expected to bracket CPU access using the DMA_BUF_IOCTL_SYNC interface. Because dma-buf buffers have invariant size over their lifetime, the dma-buf core checks whether a vma is too large and rejects such mappings. The exporter hence does not need to duplicate this check. Drivers do not need to check this themselves. If an exporter needs to manually flush caches and hence needs to fake coherency for mmap support, it needs to be able to zap all the ptes pointing at the backing storage. Now linux mm needs a struct address_space associated with the struct file stored in vma->vm_file to do that with the function unmap_mapping_range. But the dma_buf framework only backs every dma_buf fd with the anon_file struct file, i.e. all dma_bufs share the same file. Hence exporters need to setup their own file (and address_space) association by setting vma->vm_file and adjusting vma->vm_pgoff in the dma_buf mmap callback. In the specific case of a gem driver the exporter could use the shmem file already provided by gem (and set vm_pgoff = 0). Exporters can then zap ptes by unmapping the corresponding range of the struct address_space associated with their own file. This callback is optional. Returns: 0 on success or a negative error code on failure. h](j )}(h``mmap``h]j)}(hjPh]hmmap}(hj PhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjPubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjPubj )}(hhh](h)}(h4This callback is used by the dma_buf_mmap() functionh]h4This callback is used by the dma_buf_mmap() function}(hj!PhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjPubh)}(hNote that the mapping needs to be incoherent, userspace is expected to bracket CPU access using the DMA_BUF_IOCTL_SYNC interface.h]hNote that the mapping needs to be incoherent, userspace is expected to bracket CPU access using the DMA_BUF_IOCTL_SYNC interface.}(hj0PhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjPubh)}(hBecause dma-buf buffers have invariant size over their lifetime, the dma-buf core checks whether a vma is too large and rejects such mappings. The exporter hence does not need to duplicate this check. Drivers do not need to check this themselves.h]hBecause dma-buf buffers have invariant size over their lifetime, the dma-buf core checks whether a vma is too large and rejects such mappings. The exporter hence does not need to duplicate this check. Drivers do not need to check this themselves.}(hj?PhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjPubh)}(hXIf an exporter needs to manually flush caches and hence needs to fake coherency for mmap support, it needs to be able to zap all the ptes pointing at the backing storage. Now linux mm needs a struct address_space associated with the struct file stored in vma->vm_file to do that with the function unmap_mapping_range. But the dma_buf framework only backs every dma_buf fd with the anon_file struct file, i.e. all dma_bufs share the same file.h]hXIf an exporter needs to manually flush caches and hence needs to fake coherency for mmap support, it needs to be able to zap all the ptes pointing at the backing storage. Now linux mm needs a struct address_space associated with the struct file stored in vma->vm_file to do that with the function unmap_mapping_range. But the dma_buf framework only backs every dma_buf fd with the anon_file struct file, i.e. all dma_bufs share the same file.}(hjNPhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhKhjPubh)}(hXHence exporters need to setup their own file (and address_space) association by setting vma->vm_file and adjusting vma->vm_pgoff in the dma_buf mmap callback. In the specific case of a gem driver the exporter could use the shmem file already provided by gem (and set vm_pgoff = 0). Exporters can then zap ptes by unmapping the corresponding range of the struct address_space associated with their own file.h]hXHence exporters need to setup their own file (and address_space) association by setting vma->vm_file and adjusting vma->vm_pgoff in the dma_buf mmap callback. In the specific case of a gem driver the exporter could use the shmem file already provided by gem (and set vm_pgoff = 0). Exporters can then zap ptes by unmapping the corresponding range of the struct address_space associated with their own file.}(hj]PhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjPubh)}(hThis callback is optional.h]hThis callback is optional.}(hjlPhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM hjPubh)}(hReturns:h]hReturns:}(hj{PhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjPubh)}(h10 on success or a negative error code on failure.h]h10 on success or a negative error code on failure.}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjPhMhjPubeh}(h]h ]h"]h$]h&]uh1j hjPubeh}(h]h ]h"]h$]h&]uh1j hjPhMhjIubj )}(h``vmap`` [optional] creates a virtual mapping for the buffer into kernel address space. Same restrictions as for vmap and friends apply. h](j )}(h``vmap``h]j)}(hjPh]hvmap}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjPubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK#hjPubj )}(hhh]h)}(h[optional] creates a virtual mapping for the buffer into kernel address space. Same restrictions as for vmap and friends apply.h]h[optional] creates a virtual mapping for the buffer into kernel address space. Same restrictions as for vmap and friends apply.}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK"hjPubah}(h]h ]h"]h$]h&]uh1j hjPubeh}(h]h ]h"]h$]h&]uh1j hjPhK#hjIubj )}(h3``vunmap`` [optional] unmaps a vmap from the bufferh](j )}(h ``vunmap``h]j)}(hjPh]hvunmap}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjPubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK#hjPubj )}(hhh]h)}(h([optional] unmaps a vmap from the bufferh]h([optional] unmaps a vmap from the buffer}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK$hjPubah}(h]h ]h"]h$]h&]uh1j hjPubeh}(h]h ]h"]h$]h&]uh1j hjPhK#hjIubeh}(h]h ]h"]h$]h&]uh1j hj>Iubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf (C struct) c.dma_bufhNtauh1jhjhhhNhNubj)}(hhh](j)}(hdma_bufh]j)}(hstruct dma_bufh](j)}(hjh]hstruct}(hj>QhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj:Qhhh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhK*ubj)}(h h]h }(hjLQhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj:QhhhjKQhK*ubj )}(hdma_bufh]j )}(hj8Qh]hdma_buf}(hj^QhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjZQubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj:QhhhjKQhK*ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj6QhhhjKQhK*ubah}(h]j1Qah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjKQhK*hj3QhhubjA )}(hhh]h)}(hshared buffer objecth]hshared buffer object}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj}Qhhubah}(h]h ]h"]h$]h&]uh1j@ hj3QhhhjKQhK*ubeh}(h]h ](jstructeh"]h$]h&]ja jjb jQjc jQjd je jf uh1jhhhjhNhNubjh )}(hX**Definition**:: struct dma_buf { size_t size; struct file *file; struct list_head attachments; const struct dma_buf_ops *ops; unsigned vmapping_counter; struct iosys_map vmap_ptr; const char *exp_name; const char *name; spinlock_t name_lock; struct module *owner; struct list_head list_node; void *priv; struct dma_resv *resv; wait_queue_head_t poll; struct dma_buf_poll_cb_t { struct dma_fence_cb cb; wait_queue_head_t *poll; __poll_t active; } cb_in, cb_out; }; **Members** ``size`` Size of the buffer; invariant over the lifetime of the buffer. ``file`` File pointer used for sharing buffers across, and for refcounting. See dma_buf_get() and dma_buf_put(). ``attachments`` List of dma_buf_attachment that denotes all devices attached, protected by :c:type:`dma_resv` lock **resv**. ``ops`` dma_buf_ops associated with this buffer object. ``vmapping_counter`` Used internally to refcnt the vmaps returned by dma_buf_vmap(). Protected by **resv**. ``vmap_ptr`` The current vmap ptr if **vmapping_counter** > 0. Protected by **resv**. ``exp_name`` Name of the exporter; useful for debugging. Must not be NULL ``name`` Userspace-provided name. Default value is NULL. If not NULL, length cannot be longer than DMA_BUF_NAME_LEN, including NIL char. Useful for accounting and debugging. Read/Write accesses are protected by **name_lock** See the IOCTLs DMA_BUF_SET_NAME or DMA_BUF_SET_NAME_A/B ``name_lock`` Spinlock to protect name access for read access. ``owner`` Pointer to exporter module; used for refcounting when exporter is a kernel module. ``list_node`` node for dma_buf accounting and debugging. ``priv`` exporter specific private data for this buffer object. ``resv`` Reservation object linked to this dma-buf. IMPLICIT SYNCHRONIZATION RULES: Drivers which support implicit synchronization of buffer access as e.g. exposed in `Implicit Fence Poll Support`_ must follow the below rules. - Drivers must add a read fence through dma_resv_add_fence() with the DMA_RESV_USAGE_READ flag for anything the userspace API considers a read access. This highly depends upon the API and window system. - Similarly drivers must add a write fence through dma_resv_add_fence() with the DMA_RESV_USAGE_WRITE flag for anything the userspace API considers write access. - Drivers may just always add a write fence, since that only causes unnecessary synchronization, but no correctness issues. - Some drivers only expose a synchronous userspace API with no pipelining across drivers. These do not set any fences for their access. An example here is v4l. - Driver should use dma_resv_usage_rw() when retrieving fences as dependency for implicit synchronization. DYNAMIC IMPORTER RULES: Dynamic importers, see dma_buf_attachment_is_dynamic(), have additional constraints on how they set up fences: - Dynamic importers must obey the write fences and wait for them to signal before allowing access to the buffer's underlying storage through the device. - Dynamic importers should set fences for any access that they can't disable immediately from their :c:type:`dma_buf_attach_ops.invalidate_mappings ` callback. IMPORTANT: All drivers and memory management related functions must obey the struct dma_resv rules, specifically the rules for updating and obeying fences. See enum dma_resv_usage for further descriptions. ``poll`` for userspace poll support ``cb_in`` for userspace poll support ``cb_out`` for userspace poll supporth](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjQubh:}(hjQhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjQubj)}(hXstruct dma_buf { size_t size; struct file *file; struct list_head attachments; const struct dma_buf_ops *ops; unsigned vmapping_counter; struct iosys_map vmap_ptr; const char *exp_name; const char *name; spinlock_t name_lock; struct module *owner; struct list_head list_node; void *priv; struct dma_resv *resv; wait_queue_head_t poll; struct dma_buf_poll_cb_t { struct dma_fence_cb cb; wait_queue_head_t *poll; __poll_t active; } cb_in, cb_out; };h]hXstruct dma_buf { size_t size; struct file *file; struct list_head attachments; const struct dma_buf_ops *ops; unsigned vmapping_counter; struct iosys_map vmap_ptr; const char *exp_name; const char *name; spinlock_t name_lock; struct module *owner; struct list_head list_node; void *priv; struct dma_resv *resv; wait_queue_head_t poll; struct dma_buf_poll_cb_t { struct dma_fence_cb cb; wait_queue_head_t *poll; __poll_t active; } cb_in, cb_out; };}hjQsbah}(h]h ]h"]h$]h&]jjuh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM!hjQubh)}(h **Members**h]jr )}(hjQh]hMembers}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjQubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM7hjQubj )}(hhh](j )}(hH``size`` Size of the buffer; invariant over the lifetime of the buffer. h](j )}(h``size``h]j)}(hjQh]hsize}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjQubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM)hjQubj )}(hhh]h)}(h>Size of the buffer; invariant over the lifetime of the buffer.h]h>Size of the buffer; invariant over the lifetime of the buffer.}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjRhM)hjRubah}(h]h ]h"]h$]h&]uh1j hjQubeh}(h]h ]h"]h$]h&]uh1j hjRhM)hjQubj )}(hq``file`` File pointer used for sharing buffers across, and for refcounting. See dma_buf_get() and dma_buf_put(). h](j )}(h``file``h]j)}(hj&Rh]hfile}(hj(RhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj$Rubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM1hj Rubj )}(hhh]h)}(hgFile pointer used for sharing buffers across, and for refcounting. See dma_buf_get() and dma_buf_put().h]hgFile pointer used for sharing buffers across, and for refcounting. See dma_buf_get() and dma_buf_put().}(hj?RhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM0hj 0. Protected by **resv**. h](j )}(h ``vmap_ptr``h]j)}(hjTSh]hvmap_ptr}(hjVShhhNhNubah}(h]h ]h"]h$]h&]uh1jhjRSubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMKhjNSubj )}(hhh]h)}(hHThe current vmap ptr if **vmapping_counter** > 0. Protected by **resv**.h](hThe current vmap ptr if }(hjmShhhNhNubjr )}(h**vmapping_counter**h]hvmapping_counter}(hjuShhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjmSubh > 0. Protected by }(hjmShhhNhNubjr )}(h**resv**h]hresv}(hjShhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjmSubh.}(hjmShhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjiShMKhjjSubah}(h]h ]h"]h$]h&]uh1j hjNSubeh}(h]h ]h"]h$]h&]uh1j hjiShMKhjQubj )}(hJ``exp_name`` Name of the exporter; useful for debugging. Must not be NULL h](j )}(h ``exp_name``h]j)}(hjSh]hexp_name}(hjShhhNhNubah}(h]h ]h"]h$]h&]uh1jhjSubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMQhjSubj )}(hhh]h)}(hTubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMchj:Tubj )}(hhh]h)}(h0Spinlock to protect name access for read access.h]h0Spinlock to protect name access for read access.}(hjYThhhNhNubah}(h]h ]h"]h$]h&]uh1hhjUThMchjVTubah}(h]h ]h"]h$]h&]uh1j hj:Tubeh}(h]h ]h"]h$]h&]uh1j hjUThMchjQubj )}(h]``owner`` Pointer to exporter module; used for refcounting when exporter is a kernel module. h](j )}(h ``owner``h]j)}(hjyTh]howner}(hj{ThhhNhNubah}(h]h ]h"]h$]h&]uh1jhjwTubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhhjsTubj )}(hhh]h)}(hRPointer to exporter module; used for refcounting when exporter is a kernel module.h]hRPointer to exporter module; used for refcounting when exporter is a kernel module.}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMghjTubah}(h]h ]h"]h$]h&]uh1j hjsTubeh}(h]h ]h"]h$]h&]uh1j hjThMhhjQubj )}(h9``list_node`` node for dma_buf accounting and debugging. h](j )}(h ``list_node``h]j)}(hjTh]h list_node}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1jhjTubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMnhjTubj )}(hhh]h)}(h*node for dma_buf accounting and debugging.h]h*node for dma_buf accounting and debugging.}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1hhjThMnhjTubah}(h]h ]h"]h$]h&]uh1j hjTubeh}(h]h ]h"]h$]h&]uh1j hjThMnhjQubj )}(h@``priv`` exporter specific private data for this buffer object. h](j )}(h``priv``h]j)}(hjTh]hpriv}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1jhjTubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMqhjTubj )}(hhh]h)}(h6exporter specific private data for this buffer object.h]h6exporter specific private data for this buffer object.}(hjUhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjUhMqhjUubah}(h]h ]h"]h$]h&]uh1j hjTubeh}(h]h ]h"]h$]h&]uh1j hjUhMqhjQubj )}(hX``resv`` Reservation object linked to this dma-buf. IMPLICIT SYNCHRONIZATION RULES: Drivers which support implicit synchronization of buffer access as e.g. exposed in `Implicit Fence Poll Support`_ must follow the below rules. - Drivers must add a read fence through dma_resv_add_fence() with the DMA_RESV_USAGE_READ flag for anything the userspace API considers a read access. This highly depends upon the API and window system. - Similarly drivers must add a write fence through dma_resv_add_fence() with the DMA_RESV_USAGE_WRITE flag for anything the userspace API considers write access. - Drivers may just always add a write fence, since that only causes unnecessary synchronization, but no correctness issues. - Some drivers only expose a synchronous userspace API with no pipelining across drivers. These do not set any fences for their access. An example here is v4l. - Driver should use dma_resv_usage_rw() when retrieving fences as dependency for implicit synchronization. DYNAMIC IMPORTER RULES: Dynamic importers, see dma_buf_attachment_is_dynamic(), have additional constraints on how they set up fences: - Dynamic importers must obey the write fences and wait for them to signal before allowing access to the buffer's underlying storage through the device. - Dynamic importers should set fences for any access that they can't disable immediately from their :c:type:`dma_buf_attach_ops.invalidate_mappings ` callback. IMPORTANT: All drivers and memory management related functions must obey the struct dma_resv rules, specifically the rules for updating and obeying fences. See enum dma_resv_usage for further descriptions. h](j )}(h``resv``h]j)}(hj%Uh]hresv}(hj'UhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj#Uubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjUubj )}(hhh](h)}(h*Reservation object linked to this dma-buf.h]h*Reservation object linked to this dma-buf.}(hj>UhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMuhj;Uubh)}(hIMPLICIT SYNCHRONIZATION RULES:h]hIMPLICIT SYNCHRONIZATION RULES:}(hjMUhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMwhj;Uubh)}(hDrivers which support implicit synchronization of buffer access as e.g. exposed in `Implicit Fence Poll Support`_ must follow the below rules.h](hSDrivers which support implicit synchronization of buffer access as e.g. exposed in }(hj\UhhhNhNubj)}(h`Implicit Fence Poll Support`_h]hImplicit Fence Poll Support}(hjdUhhhNhNubah}(h]h ]h"]h$]h&]nameImplicit Fence Poll Supportjjuh1jhj\UjKubh must follow the below rules.}(hj\UhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMyhj;Uubh)}(hhh](j)}(hDrivers must add a read fence through dma_resv_add_fence() with the DMA_RESV_USAGE_READ flag for anything the userspace API considers a read access. This highly depends upon the API and window system. h]h)}(hDrivers must add a read fence through dma_resv_add_fence() with the DMA_RESV_USAGE_READ flag for anything the userspace API considers a read access. This highly depends upon the API and window system.h]hDrivers must add a read fence through dma_resv_add_fence() with the DMA_RESV_USAGE_READ flag for anything the userspace API considers a read access. This highly depends upon the API and window system.}(hjUhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM}hjUubah}(h]h ]h"]h$]h&]uh1jhjUubj)}(hSimilarly drivers must add a write fence through dma_resv_add_fence() with the DMA_RESV_USAGE_WRITE flag for anything the userspace API considers write access. h]h)}(hSimilarly drivers must add a write fence through dma_resv_add_fence() with the DMA_RESV_USAGE_WRITE flag for anything the userspace API considers write access.h]hSimilarly drivers must add a write fence through dma_resv_add_fence() with the DMA_RESV_USAGE_WRITE flag for anything the userspace API considers write access.}(hjUhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjUubah}(h]h ]h"]h$]h&]uh1jhjUubj)}(hzDrivers may just always add a write fence, since that only causes unnecessary synchronization, but no correctness issues. h]h)}(hyDrivers may just always add a write fence, since that only causes unnecessary synchronization, but no correctness issues.h]hyDrivers may just always add a write fence, since that only causes unnecessary synchronization, but no correctness issues.}(hjUhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjUubah}(h]h ]h"]h$]h&]uh1jhjUubj)}(hSome drivers only expose a synchronous userspace API with no pipelining across drivers. These do not set any fences for their access. An example here is v4l. h]h)}(hSome drivers only expose a synchronous userspace API with no pipelining across drivers. These do not set any fences for their access. An example here is v4l.h]hSome drivers only expose a synchronous userspace API with no pipelining across drivers. These do not set any fences for their access. An example here is v4l.}(hjUhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjUubah}(h]h ]h"]h$]h&]uh1jhjUubj)}(hiDriver should use dma_resv_usage_rw() when retrieving fences as dependency for implicit synchronization. h]h)}(hhDriver should use dma_resv_usage_rw() when retrieving fences as dependency for implicit synchronization.h]hhDriver should use dma_resv_usage_rw() when retrieving fences as dependency for implicit synchronization.}(hjUhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjUubah}(h]h ]h"]h$]h&]uh1jhjUubeh}(h]h ]h"]h$]h&]jRjSuh1hhjUhM}hj;Uubh)}(hDYNAMIC IMPORTER RULES:h]hDYNAMIC IMPORTER RULES:}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj;Uubh)}(hnDynamic importers, see dma_buf_attachment_is_dynamic(), have additional constraints on how they set up fences:h]hnDynamic importers, see dma_buf_attachment_is_dynamic(), have additional constraints on how they set up fences:}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj;Uubh)}(hhh](j)}(hDynamic importers must obey the write fences and wait for them to signal before allowing access to the buffer's underlying storage through the device. h]h)}(hDynamic importers must obey the write fences and wait for them to signal before allowing access to the buffer's underlying storage through the device.h]hDynamic importers must obey the write fences and wait for them to signal before allowing access to the buffer’s underlying storage through the device.}(hj*VhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj&Vubah}(h]h ]h"]h$]h&]uh1jhj#Vubj)}(hDynamic importers should set fences for any access that they can't disable immediately from their :c:type:`dma_buf_attach_ops.invalidate_mappings ` callback. h]h)}(hDynamic importers should set fences for any access that they can't disable immediately from their :c:type:`dma_buf_attach_ops.invalidate_mappings ` callback.h](hdDynamic importers should set fences for any access that they can’t disable immediately from their }(hjCVhhhNhNubh)}(hE:c:type:`dma_buf_attach_ops.invalidate_mappings `h]j)}(hjMVh]h&dma_buf_attach_ops.invalidate_mappings}(hjOVhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjKVubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_attach_opsuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjCVubh callback.}(hjCVhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjjVhMhj?Vubah}(h]h ]h"]h$]h&]uh1jhj#Vubeh}(h]h ]h"]h$]h&]jRjSuh1hhj8VhMhj;Uubh)}(h IMPORTANT:h]h IMPORTANT:}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj;Uubh)}(hAll drivers and memory management related functions must obey the struct dma_resv rules, specifically the rules for updating and obeying fences. See enum dma_resv_usage for further descriptions.h]hAll drivers and memory management related functions must obey the struct dma_resv rules, specifically the rules for updating and obeying fences. See enum dma_resv_usage for further descriptions.}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj;Uubeh}(h]h ]h"]h$]h&]uh1j hjUubeh}(h]h ]h"]h$]h&]uh1j hj:UhMhjQubj )}(h$``poll`` for userspace poll support h](j )}(h``poll``h]j)}(hjVh]hpoll}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjVubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjVubj )}(hhh]h)}(hfor userspace poll supporth]hfor userspace poll support}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjVhMhjVubah}(h]h ]h"]h$]h&]uh1j hjVubeh}(h]h ]h"]h$]h&]uh1j hjVhMhjQubj )}(h%``cb_in`` for userspace poll support h](j )}(h ``cb_in``h]j)}(hjVh]hcb_in}(hjVhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjVubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjVubj )}(hhh]h)}(hfor userspace poll supporth]hfor userspace poll support}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjVhMhjWubah}(h]h ]h"]h$]h&]uh1j hjVubeh}(h]h ]h"]h$]h&]uh1j hjVhMhjQubj )}(h%``cb_out`` for userspace poll supporth](j )}(h ``cb_out``h]j)}(hj#Wh]hcb_out}(hj%WhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj!Wubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjWubj )}(hhh]h)}(hfor userspace poll supporth]hfor userspace poll support}(hj`.h](h-Device DMA access is handled by the separate }(hjWhhhNhNubh)}(h8:c:type:`struct dma_buf_attachment `h]j)}(hjWh]hstruct dma_buf_attachment}(hjWhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjWubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_attachmentuh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM#hjWubh.}(hjWhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjWhM#hjhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_attach_ops (C struct)c.dma_buf_attach_opshNtauh1jhjhhhNhNubj)}(hhh](j)}(hdma_buf_attach_opsh]j)}(hstruct dma_buf_attach_opsh](j)}(hjh]hstruct}(hjWhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjWhhh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM(ubj)}(h h]h }(hjWhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjWhhhjWhM(ubj )}(hdma_buf_attach_opsh]j )}(hjWh]hdma_buf_attach_ops}(hjXhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjXubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjWhhhjWhM(ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjWhhhjWhM(ubah}(h]jWah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjWhM(hjWhhubjA )}(hhh]h)}(h%importer operations for an attachmenth]h%importer operations for an attachment}(hj'XhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj$Xhhubah}(h]h ]h"]h$]h&]uh1j@ hjWhhhjWhM(ubeh}(h]h ](jstructeh"]h$]h&]ja jjb j?Xjc j?Xjd je jf uh1jhhhjhNhNubjh )}(hX6**Definition**:: struct dma_buf_attach_ops { bool allow_peer2peer; void (*invalidate_mappings)(struct dma_buf_attachment *attach); }; **Members** ``allow_peer2peer`` If this is set to true the importer must be able to handle peer resources without struct pages. ``invalidate_mappings`` [optional] notification that the DMA-buf is moving If this callback is provided the framework can avoid pinning the backing store while mappings exists. This callback is called with the lock of the reservation object associated with the dma_buf held and the mapping function must be called with this lock held as well. This makes sure that no mapping is created concurrently with an ongoing move operation. See the kdoc for dma_buf_invalidate_mappings() for details on the required behavior.h](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjKXhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjGXubh:}(hjGXhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjCXubj)}(h|struct dma_buf_attach_ops { bool allow_peer2peer; void (*invalidate_mappings)(struct dma_buf_attachment *attach); };h]h|struct dma_buf_attach_ops { bool allow_peer2peer; void (*invalidate_mappings)(struct dma_buf_attachment *attach); };}hjdXsbah}(h]h ]h"]h$]h&]jjuh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjCXubh)}(h **Members**h]jr )}(hjuXh]hMembers}(hjwXhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjsXubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjCXubj )}(hhh](j )}(ht``allow_peer2peer`` If this is set to true the importer must be able to handle peer resources without struct pages. h](j )}(h``allow_peer2peer``h]j)}(hjXh]hallow_peer2peer}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjXubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjXubj )}(hhh]h)}(h_If this is set to true the importer must be able to handle peer resources without struct pages.h]h_If this is set to true the importer must be able to handle peer resources without struct pages.}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjXubah}(h]h ]h"]h$]h&]uh1j hjXubeh}(h]h ]h"]h$]h&]uh1j hjXhMhjXubj )}(hX``invalidate_mappings`` [optional] notification that the DMA-buf is moving If this callback is provided the framework can avoid pinning the backing store while mappings exists. This callback is called with the lock of the reservation object associated with the dma_buf held and the mapping function must be called with this lock held as well. This makes sure that no mapping is created concurrently with an ongoing move operation. See the kdoc for dma_buf_invalidate_mappings() for details on the required behavior.h](j )}(h``invalidate_mappings``h]j)}(hjXh]hinvalidate_mappings}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjXubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjXubj )}(hhh](h)}(h2[optional] notification that the DMA-buf is movingh]h2[optional] notification that the DMA-buf is moving}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjXubh)}(heIf this callback is provided the framework can avoid pinning the backing store while mappings exists.h]heIf this callback is provided the framework can avoid pinning the backing store while mappings exists.}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjXubh)}(hThis callback is called with the lock of the reservation object associated with the dma_buf held and the mapping function must be called with this lock held as well. This makes sure that no mapping is created concurrently with an ongoing move operation.h]hThis callback is called with the lock of the reservation object associated with the dma_buf held and the mapping function must be called with this lock held as well. This makes sure that no mapping is created concurrently with an ongoing move operation.}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjXubh)}(hTSee the kdoc for dma_buf_invalidate_mappings() for details on the required behavior.h]hTSee the kdoc for dma_buf_invalidate_mappings() for details on the required behavior.}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjXhMhjXubeh}(h]h ]h"]h$]h&]uh1j hjXubeh}(h]h ]h"]h$]h&]uh1j hjXhMhjXubeh}(h]h ]h"]h$]h&]uh1j hjCXubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubh)}(h**Description**h]jr )}(hj=Yh]h Description}(hj?YhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj;Yubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjhhubh)}(h2Attachment operations implemented by the importer.h]h2Attachment operations implemented by the importer.}(hjSYhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_attachment (C struct)c.dma_buf_attachmenthNtauh1jhjhhhNhNubj)}(hhh](j)}(hdma_buf_attachmenth]j)}(hstruct dma_buf_attachmenth](j)}(hjh]hstruct}(hj{YhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwYhhh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMubj)}(h h]h }(hjYhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjwYhhhjYhMubj )}(hdma_buf_attachmenth]j )}(hjuYh]hdma_buf_attachment}(hjYhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjYubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjwYhhhjYhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjsYhhhjYhMubah}(h]jnYah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjYhMhjpYhhubjA )}(hhh]h)}(h#holds device-buffer attachment datah]h#holds device-buffer attachment data}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjYhhubah}(h]h ]h"]h$]h&]uh1j@ hjpYhhhjYhMubeh}(h]h ](jstructeh"]h$]h&]ja jjb jYjc jYjd je jf uh1jhhhjhNhNubjh )}(hX**Definition**:: struct dma_buf_attachment { struct dma_buf *dmabuf; struct device *dev; struct list_head node; bool peer2peer; const struct dma_buf_attach_ops *importer_ops; void *importer_priv; void *priv; }; **Members** ``dmabuf`` buffer for this attachment. ``dev`` device attached to the buffer. ``node`` list of dma_buf_attachment, protected by dma_resv lock of the dmabuf. ``peer2peer`` true if the importer can handle peer resources without pages. ``importer_ops`` importer operations for this attachment, if provided dma_buf_map/unmap_attachment() must be called with the dma_resv lock held. ``importer_priv`` importer specific attachment data. ``priv`` exporter specific attachment data.h](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjYubh:}(hjYhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjYubj)}(hstruct dma_buf_attachment { struct dma_buf *dmabuf; struct device *dev; struct list_head node; bool peer2peer; const struct dma_buf_attach_ops *importer_ops; void *importer_priv; void *priv; };h]hstruct dma_buf_attachment { struct dma_buf *dmabuf; struct device *dev; struct list_head node; bool peer2peer; const struct dma_buf_attach_ops *importer_ops; void *importer_priv; void *priv; };}hjYsbah}(h]h ]h"]h$]h&]jjuh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjYubh)}(h **Members**h]jr )}(hj Zh]hMembers}(hj ZhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj Zubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjYubj )}(hhh](j )}(h'``dmabuf`` buffer for this attachment. h](j )}(h ``dmabuf``h]j)}(hj*Zh]hdmabuf}(hj,ZhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj(Zubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj$Zubj )}(hhh]h)}(hbuffer for this attachment.h]hbuffer for this attachment.}(hjCZhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj?ZhMhj@Zubah}(h]h ]h"]h$]h&]uh1j hj$Zubeh}(h]h ]h"]h$]h&]uh1j hj?ZhMhj!Zubj )}(h'``dev`` device attached to the buffer. h](j )}(h``dev``h]j)}(hjcZh]hdev}(hjeZhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjaZubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj]Zubj )}(hhh]h)}(hdevice attached to the buffer.h]hdevice attached to the buffer.}(hj|ZhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjxZhMhjyZubah}(h]h ]h"]h$]h&]uh1j hj]Zubeh}(h]h ]h"]h$]h&]uh1j hjxZhMhj!Zubj )}(hO``node`` list of dma_buf_attachment, protected by dma_resv lock of the dmabuf. h](j )}(h``node``h]j)}(hjZh]hnode}(hjZhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjZubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjZubj )}(hhh]h)}(hElist of dma_buf_attachment, protected by dma_resv lock of the dmabuf.h]hElist of dma_buf_attachment, protected by dma_resv lock of the dmabuf.}(hjZhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjZhMhjZubah}(h]h ]h"]h$]h&]uh1j hjZubeh}(h]h ]h"]h$]h&]uh1j hjZhMhj!Zubj )}(hL``peer2peer`` true if the importer can handle peer resources without pages. h](j )}(h ``peer2peer``h]j)}(hjZh]h peer2peer}(hjZhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjZubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjZubj )}(hhh]h)}(h=true if the importer can handle peer resources without pages.h]h=true if the importer can handle peer resources without pages.}(hjZhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjZhMhjZubah}(h]h ]h"]h$]h&]uh1j hjZubeh}(h]h ]h"]h$]h&]uh1j hjZhMhj!Zubj )}(h``importer_ops`` importer operations for this attachment, if provided dma_buf_map/unmap_attachment() must be called with the dma_resv lock held. h](j )}(h``importer_ops``h]j)}(hj[h]h importer_ops}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj [ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj[ubj )}(hhh]h)}(himporter operations for this attachment, if provided dma_buf_map/unmap_attachment() must be called with the dma_resv lock held.h]himporter operations for this attachment, if provided dma_buf_map/unmap_attachment() must be called with the dma_resv lock held.}(hj'[hhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj$[ubah}(h]h ]h"]h$]h&]uh1j hj[ubeh}(h]h ]h"]h$]h&]uh1j hj#[hMhj!Zubj )}(h5``importer_priv`` importer specific attachment data. h](j )}(h``importer_priv``h]j)}(hjH[h]h importer_priv}(hjJ[hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjF[ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjB[ubj )}(hhh]h)}(h"importer specific attachment data.h]h"importer specific attachment data.}(hja[hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj][hMhj^[ubah}(h]h ]h"]h$]h&]uh1j hjB[ubeh}(h]h ]h"]h$]h&]uh1j hj][hMhj!Zubj )}(h+``priv`` exporter specific attachment data.h](j )}(h``priv``h]j)}(hj[h]hpriv}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj[ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj{[ubj )}(hhh]h)}(h"exporter specific attachment data.h]h"exporter specific attachment data.}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj[ubah}(h]h ]h"]h$]h&]uh1j hj{[ubeh}(h]h ]h"]h$]h&]uh1j hj[hMhj!Zubeh}(h]h ]h"]h$]h&]uh1j hjYubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubh)}(h**Description**h]jr )}(hj[h]h Description}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj[ubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjhhubh)}(hThis structure holds the attachment information between the dma_buf buffer and its user device(s). The list contains one attachment struct per device attached to the buffer.h]hThis structure holds the attachment information between the dma_buf buffer and its user device(s). The list contains one attachment struct per device attached to the buffer.}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjhhubh)}(hAn attachment is created by calling dma_buf_attach(), and released again by calling dma_buf_detach(). The DMA mapping itself needed to initiate a transfer is created by dma_buf_map_attachment() and freed again by calling dma_buf_unmap_attachment().h]hAn attachment is created by calling dma_buf_attach(), and released again by calling dma_buf_detach(). The DMA mapping itself needed to initiate a transfer is created by dma_buf_map_attachment() and freed again by calling dma_buf_unmap_attachment().}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_export_info (C struct)c.dma_buf_export_infohNtauh1jhjhhhNhNubj)}(hhh](j)}(hdma_buf_export_infoh]j)}(hstruct dma_buf_export_infoh](j)}(hjh]hstruct}(hj\hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj \hhh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMubj)}(h h]h }(hj\hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj \hhhj\hMubj )}(hdma_buf_export_infoh]j )}(hj \h]hdma_buf_export_info}(hj1\hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj-\ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj \hhhj\hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj \hhhj\hMubah}(h]j\ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj\hMhj\hhubjA )}(hhh]h)}(h,holds information needed to export a dma_bufh]h,holds information needed to export a dma_buf}(hjS\hhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjP\hhubah}(h]h ]h"]h$]h&]uh1j@ hj\hhhj\hMubeh}(h]h ](jstructeh"]h$]h&]ja jjb jk\jc jk\jd je jf uh1jhhhjhNhNubjh )}(hX**Definition**:: struct dma_buf_export_info { const char *exp_name; struct module *owner; const struct dma_buf_ops *ops; size_t size; int flags; struct dma_resv *resv; void *priv; }; **Members** ``exp_name`` name of the exporter - useful for debugging. ``owner`` pointer to exporter module - used for refcounting kernel module ``ops`` Attach allocator-defined dma buf ops to the new buffer ``size`` Size of the buffer - invariant over the lifetime of the buffer ``flags`` mode flags for the file ``resv`` reservation-object, NULL to allocate default one ``priv`` Attach private data of allocator to this bufferh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjw\hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjs\ubh:}(hjs\hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjo\ubj)}(hstruct dma_buf_export_info { const char *exp_name; struct module *owner; const struct dma_buf_ops *ops; size_t size; int flags; struct dma_resv *resv; void *priv; };h]hstruct dma_buf_export_info { const char *exp_name; struct module *owner; const struct dma_buf_ops *ops; size_t size; int flags; struct dma_resv *resv; void *priv; };}hj\sbah}(h]h ]h"]h$]h&]jjuh1jh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjo\ubh)}(h **Members**h]jr )}(hj\h]hMembers}(hj\hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj\ubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjo\ubj )}(hhh](j )}(h:``exp_name`` name of the exporter - useful for debugging. h](j )}(h ``exp_name``h]j)}(hj\h]hexp_name}(hj\hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj\ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj\ubj )}(hhh]h)}(h,name of the exporter - useful for debugging.h]h,name of the exporter - useful for debugging.}(hj\hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj\hMhj\ubah}(h]h ]h"]h$]h&]uh1j hj\ubeh}(h]h ]h"]h$]h&]uh1j hj\hMhj\ubj )}(hJ``owner`` pointer to exporter module - used for refcounting kernel module h](j )}(h ``owner``h]j)}(hj\h]howner}(hj\hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj\ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj\ubj )}(hhh]h)}(h?pointer to exporter module - used for refcounting kernel moduleh]h?pointer to exporter module - used for refcounting kernel module}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj]hMhj]ubah}(h]h ]h"]h$]h&]uh1j hj\ubeh}(h]h ]h"]h$]h&]uh1j hj]hMhj\ubj )}(h?``ops`` Attach allocator-defined dma buf ops to the new buffer h](j )}(h``ops``h]j)}(hj2]h]hops}(hj4]hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj0]ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj,]ubj )}(hhh]h)}(h6Attach allocator-defined dma buf ops to the new bufferh]h6Attach allocator-defined dma buf ops to the new buffer}(hjK]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjG]hMhjH]ubah}(h]h ]h"]h$]h&]uh1j hj,]ubeh}(h]h ]h"]h$]h&]uh1j hjG]hMhj\ubj )}(hH``size`` Size of the buffer - invariant over the lifetime of the buffer h](j )}(h``size``h]j)}(hjk]h]hsize}(hjm]hhhNhNubah}(h]h ]h"]h$]h&]uh1jhji]ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhje]ubj )}(hhh]h)}(h>Size of the buffer - invariant over the lifetime of the bufferh]h>Size of the buffer - invariant over the lifetime of the buffer}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj]hMhj]ubah}(h]h ]h"]h$]h&]uh1j hje]ubeh}(h]h ]h"]h$]h&]uh1j hj]hMhj\ubj )}(h"``flags`` mode flags for the file h](j )}(h ``flags``h]j)}(hj]h]hflags}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj]ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj]ubj )}(hhh]h)}(hmode flags for the fileh]hmode flags for the file}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj]hMhj]ubah}(h]h ]h"]h$]h&]uh1j hj]ubeh}(h]h ]h"]h$]h&]uh1j hj]hMhj\ubj )}(h:``resv`` reservation-object, NULL to allocate default one h](j )}(h``resv``h]j)}(hj]h]hresv}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj]ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj]ubj )}(hhh]h)}(h0reservation-object, NULL to allocate default oneh]h0reservation-object, NULL to allocate default one}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj]hMhj]ubah}(h]h ]h"]h$]h&]uh1j hj]ubeh}(h]h ]h"]h$]h&]uh1j hj]hMhj\ubj )}(h8``priv`` Attach private data of allocator to this bufferh](j )}(h``priv``h]j)}(hj^h]hpriv}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj^ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj^ubj )}(hhh]h)}(h/Attach private data of allocator to this bufferh]h/Attach private data of allocator to this buffer}(hj/^hhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj,^ubah}(h]h ]h"]h$]h&]uh1j hj^ubeh}(h]h ]h"]h$]h&]uh1j hj+^hMhj\ubeh}(h]h ]h"]h$]h&]uh1j hjo\ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubh)}(h**Description**h]jr )}(hjY^h]h Description}(hj[^hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjW^ubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjhhubh)}(hdThis structure holds the information required to export the buffer. Used with dma_buf_export() only.h]hdThis structure holds the information required to export the buffer. Used with dma_buf_export() only.}(hjo^hhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhjhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j$DEFINE_DMA_BUF_EXPORT_INFO (C macro)c.DEFINE_DMA_BUF_EXPORT_INFOhNtauh1jhjhhhNhNubj)}(hhh](j)}(hDEFINE_DMA_BUF_EXPORT_INFOh]j)}(hDEFINE_DMA_BUF_EXPORT_INFOh]j )}(hDEFINE_DMA_BUF_EXPORT_INFOh]j )}(hj^h]hDEFINE_DMA_BUF_EXPORT_INFO}(hj^hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj^ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj^hhh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMubah}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj^hhhj^hMubah}(h]j^ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj^hMhj^hhubjA )}(hhh]h}(h]h ]h"]h$]h&]uh1j@ hj^hhhj^hMubeh}(h]h ](jmacroeh"]h$]h&]ja jjb j^jc j^jd je jf uh1jhhhjhNhNubh)}(h%``DEFINE_DMA_BUF_EXPORT_INFO (name)``h]j)}(hj^h]h!DEFINE_DMA_BUF_EXPORT_INFO (name)}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj^ubah}(h]h ]h"]h$]Oh&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM hjhhubh)}(hhelper macro for exporters h]h)}(hhelper macro for exportersh]hhelper macro for exporters}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj^ubah}(h]h ]h"]h$]h&]uh1hhj^hMhjhhubjh )}(h**Parameters** ``name`` export-info name **Description** DEFINE_DMA_BUF_EXPORT_INFO macro defines the :c:type:`struct dma_buf_export_info `, zeroes it out and pre-populates exp_name in it.h](h)}(h**Parameters**h]jr )}(hj_h]h Parameters}(hj_hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj_ubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM hj^ubj )}(hhh]j )}(h``name`` export-info name h](j )}(h``name``h]j)}(hj!_h]hname}(hj#_hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj_ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj_ubj )}(hhh]h)}(hexport-info nameh]hexport-info name}(hj:_hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj6_hMhj7_ubah}(h]h ]h"]h$]h&]uh1j hj_ubeh}(h]h ]h"]h$]h&]uh1j hj6_hMhj_ubah}(h]h ]h"]h$]h&]uh1j hj^ubh)}(h**Description**h]jr )}(hj\_h]h Description}(hj^_hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjZ_ubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM hj^ubh)}(hDEFINE_DMA_BUF_EXPORT_INFO macro defines the :c:type:`struct dma_buf_export_info `, zeroes it out and pre-populates exp_name in it.h](h-DEFINE_DMA_BUF_EXPORT_INFO macro defines the }(hjr_hhhNhNubh)}(h::c:type:`struct dma_buf_export_info `h]j)}(hj|_h]hstruct dma_buf_export_info}(hj~_hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjz_ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_buf_export_infouh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM hjr_ubh1, zeroes it out and pre-populates exp_name in it.}(hjr_hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj_hM hj^ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jget_dma_buf (C function) c.get_dma_bufhNtauh1jhjhhhNhNubj)}(hhh](j)}(h)void get_dma_buf (struct dma_buf *dmabuf)h]j)}(h(void get_dma_buf(struct dma_buf *dmabuf)h](jM)}(hvoidh]hvoid}(hj_hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj_hhh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMubj)}(h h]h }(hj_hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj_hhhj_hMubj )}(h get_dma_bufh]j )}(h get_dma_bufh]h get_dma_buf}(hj_hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj_ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj_hhhj_hMubj)}(h(struct dma_buf *dmabuf)h]j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hj`hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj_ubj)}(h h]h }(hj`hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj_ubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hj`hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj`ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj!`modnameN classnameNjj)}j]jO)}jGj_sb c.get_dma_bufasbuh1hhj_ubj)}(h h]h }(hj?`hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj_ubjd)}(hjgh]h*}(hjM`hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj_ubj )}(hdmabufh]hdmabuf}(hjZ`hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj_ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj_ubah}(h]h ]h"]h$]h&]jjuh1jhj_hhhj_hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj_hhhj_hMubah}(h]j_ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj_hMhj_hhubjA )}(hhh]h)}(h!convenience wrapper for get_file.h]h!convenience wrapper for get_file.}(hj`hhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj`hhubah}(h]h ]h"]h$]h&]uh1j@ hj_hhhj_hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j`jc j`jd je jf uh1jhhhjhNhNubjh )}(hXe**Parameters** ``struct dma_buf *dmabuf`` [in] pointer to dma_buf **Description** Increments the reference count on the dma-buf, needed in case of drivers that either need to create additional references to the dmabuf on the kernel side. For example, an exporter that needs to keep a dmabuf ptr so that subsequent exports don't create a new dmabuf.h](h)}(h**Parameters**h]jr )}(hj`h]h Parameters}(hj`hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj`ubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj`ubj )}(hhh]j )}(h6``struct dma_buf *dmabuf`` [in] pointer to dma_buf h](j )}(h``struct dma_buf *dmabuf``h]j)}(hj`h]hstruct dma_buf *dmabuf}(hj`hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj`ubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj`ubj )}(hhh]h)}(h[in] pointer to dma_bufh]h[in] pointer to dma_buf}(hj`hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj`hMhj`ubah}(h]h ]h"]h$]h&]uh1j hj`ubeh}(h]h ]h"]h$]h&]uh1j hj`hMhj`ubah}(h]h ]h"]h$]h&]uh1j hj`ubh)}(h**Description**h]jr )}(hjah]h Description}(hjahhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj`ubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj`ubh)}(hX Increments the reference count on the dma-buf, needed in case of drivers that either need to create additional references to the dmabuf on the kernel side. For example, an exporter that needs to keep a dmabuf ptr so that subsequent exports don't create a new dmabuf.h]hX Increments the reference count on the dma-buf, needed in case of drivers that either need to create additional references to the dmabuf on the kernel side. For example, an exporter that needs to keep a dmabuf ptr so that subsequent exports don’t create a new dmabuf.}(hjahhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhMhj`ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_buf_is_dynamic (C function)c.dma_buf_is_dynamichNtauh1jhjhhhNhNubj)}(hhh](j)}(h0bool dma_buf_is_dynamic (struct dma_buf *dmabuf)h]j)}(h/bool dma_buf_is_dynamic(struct dma_buf *dmabuf)h](jM)}(hji5h]hbool}(hjEahhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjAahhh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM ubj)}(h h]h }(hjSahhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjAahhhjRahM ubj )}(hdma_buf_is_dynamich]j )}(hdma_buf_is_dynamich]hdma_buf_is_dynamic}(hjeahhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjaaubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjAahhhjRahM ubj)}(h(struct dma_buf *dmabuf)h]j)}(hstruct dma_buf *dmabufh](j)}(hjh]hstruct}(hjahhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj}aubj)}(h h]h }(hjahhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj}aubh)}(hhh]j )}(hdma_bufh]hdma_buf}(hjahhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjaubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjamodnameN classnameNjj)}j]jO)}jGjgasbc.dma_buf_is_dynamicasbuh1hhj}aubj)}(h h]h }(hjahhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj}aubjd)}(hjgh]h*}(hjahhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj}aubj )}(hdmabufh]hdmabuf}(hjahhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj}aubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjyaubah}(h]h ]h"]h$]h&]jjuh1jhjAahhhjRahM ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj=ahhhjRahM ubah}(h]j8aah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjRahM hj:ahhubjA )}(hhh]h)}(h)check if a DMA-buf uses dynamic mappings.h]h)check if a DMA-buf uses dynamic mappings.}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM hjbhhubah}(h]h ]h"]h$]h&]uh1j@ hj:ahhhjRahM ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jbjc jbjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_buf *dmabuf`` the DMA-buf to check **Description** Returns true if a DMA-buf exporter wants to be called with the dma_resv locked for the map/unmap callbacks, false if it doesn't wants to be called with the lock held.h](h)}(h**Parameters**h]jr )}(hj&bh]h Parameters}(hj(bhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj$bubah}(h]h ]h"]h$]h&]uh1hh[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM$hj bubj )}(hhh]j )}(h0``struct dma_buf *dmabuf`` the DMA-buf to check h](j )}(h``struct dma_buf *dmabuf``h]j)}(hjEbh]hstruct dma_buf *dmabuf}(hjGbhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjCbubah}(h]h ]h"]h$]h&]uh1j h[/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:145: ./include/linux/dma-buf.hhM!hj?bubj )}(hhh]h)}(hthe DMA-buf to checkh]hthe DMA-buf to check}(hj^bhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjZbhM!hj[bubah}(h]h ]h"]h$]h&]uh1j hj?bubeh}(h]h ]h"]h$]h&]uh1j hjZbhM!hj )j? huh1jhjchKhjbhhubjA )}(hhh]h)}(hinitialize a reservation objecth]hinitialize a reservation object}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjchhubah}(h]h ]h"]h$]h&]uh1j@ hjbhhhjchKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jcjc jcjd je jf uh1jhhhjbhNhNubjh )}(hA**Parameters** ``struct dma_resv *obj`` the reservation objecth](h)}(h**Parameters**h]jr )}(hjch]h Parameters}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjcubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjcubj )}(hhh]j )}(h/``struct dma_resv *obj`` the reservation objecth](j )}(h``struct dma_resv *obj``h]j)}(hjdh]hstruct dma_resv *obj}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjdubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjcubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjdubah}(h]h ]h"]h$]h&]uh1j hjcubeh}(h]h ]h"]h$]h&]uh1j hjdhKhjcubah}(h]h ]h"]h$]h&]uh1j hjcubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_fini (C function)c.dma_resv_finihNtauh1jhjbhhhNhNubj)}(hhh](j)}(h)void dma_resv_fini (struct dma_resv *obj)h]j)}(h(void dma_resv_fini(struct dma_resv *obj)h](jM)}(hvoidh]hvoid}(hj_dhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj[dhhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKubj)}(h h]h }(hjndhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj[dhhhjmdhKubj )}(h dma_resv_finih]j )}(h dma_resv_finih]h dma_resv_fini}(hjdhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj|dubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj[dhhhjmdhKubj)}(h(struct dma_resv *obj)h]j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjdhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjdubj)}(h h]h }(hjdhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjdubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjdhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjdubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjdmodnameN classnameNjj)}j]jO)}jGjdsbc.dma_resv_finiasbuh1hhjdubj)}(h h]h }(hjdhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjdubjd)}(hjgh]h*}(hjdhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjdubj )}(hobjh]hobj}(hjdhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjdubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjdubah}(h]h ]h"]h$]h&]jjuh1jhj[dhhhjmdhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjWdhhhjmdhKubah}(h]jRdah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjmdhKhjTdhhubjA )}(hhh]h)}(hdestroys a reservation objecth]hdestroys a reservation object}(hjehhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjehhubah}(h]h ]h"]h$]h&]uh1j@ hjTdhhhjmdhKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j7ejc j7ejd je jf uh1jhhhjbhNhNubjh )}(hA**Parameters** ``struct dma_resv *obj`` the reservation objecth](h)}(h**Parameters**h]jr )}(hjAeh]h Parameters}(hjCehhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj?eubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhj;eubj )}(hhh]j )}(h/``struct dma_resv *obj`` the reservation objecth](j )}(h``struct dma_resv *obj``h]j)}(hj`eh]hstruct dma_resv *obj}(hjbehhhNhNubah}(h]h ]h"]h$]h&]uh1jhj^eubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjZeubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjyehhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjveubah}(h]h ]h"]h$]h&]uh1j hjZeubeh}(h]h ]h"]h$]h&]uh1j hjuehKhjWeubah}(h]h ]h"]h$]h&]uh1j hj;eubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j$dma_resv_reserve_fences (C function)c.dma_resv_reserve_fenceshNtauh1jhjbhhhNhNubj)}(hhh](j)}(hKint dma_resv_reserve_fences (struct dma_resv *obj, unsigned int num_fences)h]j)}(hJint dma_resv_reserve_fences(struct dma_resv *obj, unsigned int num_fences)h](jM)}(hinth]hint}(hjehhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjehhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKubj)}(h h]h }(hjehhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjehhhjehKubj )}(hdma_resv_reserve_fencesh]j )}(hdma_resv_reserve_fencesh]hdma_resv_reserve_fences}(hjehhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjeubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjehhhjehKubj)}(h/(struct dma_resv *obj, unsigned int num_fences)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjehhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjeubj)}(h h]h }(hjfhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjeubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjfhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjfubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjfmodnameN classnameNjj)}j]jO)}jGjesbc.dma_resv_reserve_fencesasbuh1hhjeubj)}(h h]h }(hj5fhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjeubjd)}(hjgh]h*}(hjCfhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjeubj )}(hobjh]hobj}(hjPfhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjeubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjeubj)}(hunsigned int num_fencesh](jM)}(hunsignedh]hunsigned}(hjifhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjefubj)}(h h]h }(hjwfhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjefubjM)}(hinth]hint}(hjfhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjefubj)}(h h]h }(hjfhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjefubj )}(h num_fencesh]h num_fences}(hjfhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjefubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjeubeh}(h]h ]h"]h$]h&]jjuh1jhjehhhjehKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjehhhjehKubah}(h]jeah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjehKhjehhubjA )}(hhh]h)}(h1Reserve space to add fences to a dma_resv object.h]h1Reserve space to add fences to a dma_resv object.}(hjfhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjfhhubah}(h]h ]h"]h$]h&]uh1j@ hjehhhjehKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jfjc jfjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv *obj`` reservation object ``unsigned int num_fences`` number of fences we want to add **Description** Should be called before dma_resv_add_fence(). Must be called with **obj** locked through dma_resv_lock(). Note that the preallocated slots need to be re-reserved if **obj** is unlocked at any time before calling dma_resv_add_fence(). This is validated when CONFIG_DEBUG_MUTEXES is enabled. RETURNS Zero for success, or -errnoh](h)}(h**Parameters**h]jr )}(hjfh]h Parameters}(hjfhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjfubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjfubj )}(hhh](j )}(h,``struct dma_resv *obj`` reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hj gh]hstruct dma_resv *obj}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1jhj gubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjgubj )}(hhh]h)}(hreservation objecth]hreservation object}(hj%ghhhNhNubah}(h]h ]h"]h$]h&]uh1hhj!ghKhj"gubah}(h]h ]h"]h$]h&]uh1j hjgubeh}(h]h ]h"]h$]h&]uh1j hj!ghKhjgubj )}(h<``unsigned int num_fences`` number of fences we want to add h](j )}(h``unsigned int num_fences``h]j)}(hjEgh]hunsigned int num_fences}(hjGghhhNhNubah}(h]h ]h"]h$]h&]uh1jhjCgubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhj?gubj )}(hhh]h)}(hnumber of fences we want to addh]hnumber of fences we want to add}(hj^ghhhNhNubah}(h]h ]h"]h$]h&]uh1hhjZghKhj[gubah}(h]h ]h"]h$]h&]uh1j hj?gubeh}(h]h ]h"]h$]h&]uh1j hjZghKhjgubeh}(h]h ]h"]h$]h&]uh1j hjfubh)}(h**Description**h]jr )}(hjgh]h Description}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj~gubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjfubh)}(hjShould be called before dma_resv_add_fence(). Must be called with **obj** locked through dma_resv_lock().h](hCShould be called before dma_resv_add_fence(). Must be called with }(hjghhhNhNubjr )}(h**obj**h]hobj}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjgubh locked through dma_resv_lock().}(hjghhhNhNubeh}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjfubh)}(hNote that the preallocated slots need to be re-reserved if **obj** is unlocked at any time before calling dma_resv_add_fence(). This is validated when CONFIG_DEBUG_MUTEXES is enabled.h](h;Note that the preallocated slots need to be re-reserved if }(hjghhhNhNubjr )}(h**obj**h]hobj}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjgubhu is unlocked at any time before calling dma_resv_add_fence(). This is validated when CONFIG_DEBUG_MUTEXES is enabled.}(hjghhhNhNubeh}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjfubh)}(h#RETURNS Zero for success, or -errnoh]h#RETURNS Zero for success, or -errno}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chKhjfubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j&dma_resv_reset_max_fences (C function)c.dma_resv_reset_max_fenceshNtauh1jhjbhhhNhNubj)}(hhh](j)}(h5void dma_resv_reset_max_fences (struct dma_resv *obj)h]j)}(h4void dma_resv_reset_max_fences(struct dma_resv *obj)h](jM)}(hvoidh]hvoid}(hjhhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hjhhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhhjhhMubj )}(hdma_resv_reset_max_fencesh]j )}(hdma_resv_reset_max_fencesh]hdma_resv_reset_max_fences}(hj(hhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj$hubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhhjhhMubj)}(h(struct dma_resv *obj)h]j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjDhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj@hubj)}(h h]h }(hjQhhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj@hubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjbhhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj_hubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjdhmodnameN classnameNjj)}j]jO)}jGj*hsbc.dma_resv_reset_max_fencesasbuh1hhj@hubj)}(h h]h }(hjhhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj@hubjd)}(hjgh]h*}(hjhhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj@hubj )}(hobjh]hobj}(hjhhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj@hubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj )j? huh1jhjhhMhjghhubjA )}(hhh]h)}(hreset fences for debuggingh]hreset fences for debugging}(hjhhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjhhhubah}(h]h ]h"]h$]h&]uh1j@ hjghhhjhhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jhjc jhjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv *obj`` the dma_resv object to reset **Description** Reset the number of pre-reserved fence slots to test that drivers do correct slot allocation using dma_resv_reserve_fences(). See also :c:type:`dma_resv_list.max_fences `.h](h)}(h**Parameters**h]jr )}(hjhh]h Parameters}(hjhhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjhubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjhubj )}(hhh]j )}(h6``struct dma_resv *obj`` the dma_resv object to reset h](j )}(h``struct dma_resv *obj``h]j)}(hjih]hstruct dma_resv *obj}(hj ihhhNhNubah}(h]h ]h"]h$]h&]uh1jhjiubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjiubj )}(hhh]h)}(hthe dma_resv object to reseth]hthe dma_resv object to reset}(hj!ihhhNhNubah}(h]h ]h"]h$]h&]uh1hhjihMhjiubah}(h]h ]h"]h$]h&]uh1j hjiubeh}(h]h ]h"]h$]h&]uh1j hjihMhjhubah}(h]h ]h"]h$]h&]uh1j hjhubh)}(h**Description**h]jr )}(hjCih]h Description}(hjEihhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjAiubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjhubh)}(hReset the number of pre-reserved fence slots to test that drivers do correct slot allocation using dma_resv_reserve_fences(). See also :c:type:`dma_resv_list.max_fences `.h](hReset the number of pre-reserved fence slots to test that drivers do correct slot allocation using dma_resv_reserve_fences(). See also }(hjYihhhNhNubh)}(h2:c:type:`dma_resv_list.max_fences `h]j)}(hjcih]hdma_resv_list.max_fences}(hjeihhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjaiubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_resv_listuh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjYiubh.}(hjYihhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjihMhjhubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_add_fence (C function)c.dma_resv_add_fencehNtauh1jhjbhhhNhNubj)}(hhh](j)}(hbvoid dma_resv_add_fence (struct dma_resv *obj, struct dma_fence *fence, enum dma_resv_usage usage)h]j)}(havoid dma_resv_add_fence(struct dma_resv *obj, struct dma_fence *fence, enum dma_resv_usage usage)h](jM)}(hvoidh]hvoid}(hjihhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjihhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hjihhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjihhhjihMubj )}(hdma_resv_add_fenceh]j )}(hdma_resv_add_fenceh]hdma_resv_add_fence}(hjihhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjiubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjihhhjihMubj)}(hJ(struct dma_resv *obj, struct dma_fence *fence, enum dma_resv_usage usage)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjihhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjiubj)}(h h]h }(hjihhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjiubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjjmodnameN classnameNjj)}j]jO)}jGjisbc.dma_resv_add_fenceasbuh1hhjiubj)}(h h]h }(hj&jhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjiubjd)}(hjgh]h*}(hj4jhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjiubj )}(hobjh]hobj}(hjAjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjiubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjiubj)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjZjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjVjubj)}(h h]h }(hjgjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjVjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjxjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjujubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjzjmodnameN classnameNjj)}j]j"jc.dma_resv_add_fenceasbuh1hhjVjubj)}(h h]h }(hjjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjVjubjd)}(hjgh]h*}(hjjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjVjubj )}(hfenceh]hfence}(hjjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjVjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjiubj)}(henum dma_resv_usage usageh](j)}(hj+h]henum}(hjjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjjubj)}(h h]h }(hjjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjjubh)}(hhh]j )}(hdma_resv_usageh]hdma_resv_usage}(hjjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjjmodnameN classnameNjj)}j]j"jc.dma_resv_add_fenceasbuh1hhjjubj)}(h h]h }(hjkhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjjubj )}(husageh]husage}(hjkhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjiubeh}(h]h ]h"]h$]h&]jjuh1jhjihhhjihMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjihhhjihMubah}(h]jiah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjihMhjihhubjA )}(hhh]h)}(hAdd a fence to the dma_resv objh]hAdd a fence to the dma_resv obj}(hj>khhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj;khhubah}(h]h ]h"]h$]h&]uh1j@ hjihhhjihMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jVkjc jVkjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv *obj`` the reservation object ``struct dma_fence *fence`` the fence to add ``enum dma_resv_usage usage`` how the fence is used, see enum dma_resv_usage **Description** Add a fence to a slot, **obj** must be locked with dma_resv_lock(), and dma_resv_reserve_fences() has been called. See also :c:type:`dma_resv.fence ` for a discussion of the semantics.h](h)}(h**Parameters**h]jr )}(hj`kh]h Parameters}(hjbkhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj^kubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjZkubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjkh]hstruct dma_resv *obj}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj}kubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjykubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjkhMhjkubah}(h]h ]h"]h$]h&]uh1j hjykubeh}(h]h ]h"]h$]h&]uh1j hjkhMhjvkubj )}(h-``struct dma_fence *fence`` the fence to add h](j )}(h``struct dma_fence *fence``h]j)}(hjkh]hstruct dma_fence *fence}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjkubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjkubj )}(hhh]h)}(hthe fence to addh]hthe fence to add}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjkhMhjkubah}(h]h ]h"]h$]h&]uh1j hjkubeh}(h]h ]h"]h$]h&]uh1j hjkhMhjvkubj )}(hM``enum dma_resv_usage usage`` how the fence is used, see enum dma_resv_usage h](j )}(h``enum dma_resv_usage usage``h]j)}(hjkh]henum dma_resv_usage usage}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjkubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjkubj )}(hhh]h)}(h.how the fence is used, see enum dma_resv_usageh]h.how the fence is used, see enum dma_resv_usage}(hj lhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjlhMhjlubah}(h]h ]h"]h$]h&]uh1j hjkubeh}(h]h ]h"]h$]h&]uh1j hjlhMhjvkubeh}(h]h ]h"]h$]h&]uh1j hjZkubh)}(h**Description**h]jr )}(hj,lh]h Description}(hj.lhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj*lubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjZkubh)}(hrAdd a fence to a slot, **obj** must be locked with dma_resv_lock(), and dma_resv_reserve_fences() has been called.h](hAdd a fence to a slot, }(hjBlhhhNhNubjr )}(h**obj**h]hobj}(hjJlhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjBlubhT must be locked with dma_resv_lock(), and dma_resv_reserve_fences() has been called.}(hjBlhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjZkubh)}(hOSee also :c:type:`dma_resv.fence ` for a discussion of the semantics.h](h See also }(hjclhhhNhNubh)}(h#:c:type:`dma_resv.fence `h]j)}(hjmlh]hdma_resv.fence}(hjolhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjklubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_resvuh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjclubh# for a discussion of the semantics.}(hjclhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjlhMhjZkubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j$dma_resv_replace_fences (C function)c.dma_resv_replace_fenceshNtauh1jhjbhhhNhNubj)}(hhh](j)}(hvoid dma_resv_replace_fences (struct dma_resv *obj, uint64_t context, struct dma_fence *replacement, enum dma_resv_usage usage)h]j)}(h~void dma_resv_replace_fences(struct dma_resv *obj, uint64_t context, struct dma_fence *replacement, enum dma_resv_usage usage)h](jM)}(hvoidh]hvoid}(hjlhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjlhhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMJubj)}(h h]h }(hjlhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjlhhhjlhMJubj )}(hdma_resv_replace_fencesh]j )}(hdma_resv_replace_fencesh]hdma_resv_replace_fences}(hjlhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjlubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjlhhhjlhMJubj)}(hb(struct dma_resv *obj, uint64_t context, struct dma_fence *replacement, enum dma_resv_usage usage)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjlhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjlubj)}(h h]h }(hjlhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjlubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjmhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj mubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmmodnameN classnameNjj)}j]jO)}jGjlsbc.dma_resv_replace_fencesasbuh1hhjlubj)}(h h]h }(hj0mhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjlubjd)}(hjgh]h*}(hj>mhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjlubj )}(hobjh]hobj}(hjKmhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjlubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjlubj)}(huint64_t contexth](h)}(hhh]j )}(huint64_th]huint64_t}(hjgmhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjdmubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjimmodnameN classnameNjj)}j]j,mc.dma_resv_replace_fencesasbuh1hhj`mubj)}(h h]h }(hjmhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj`mubj )}(hcontexth]hcontext}(hjmhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj`mubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjlubj)}(hstruct dma_fence *replacementh](j)}(hjh]hstruct}(hjmhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjmubj)}(h h]h }(hjmhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjmubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjmhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjmubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmmodnameN classnameNjj)}j]j,mc.dma_resv_replace_fencesasbuh1hhjmubj)}(h h]h }(hjmhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjmubjd)}(hjgh]h*}(hjmhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjmubj )}(h replacementh]h replacement}(hjnhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjmubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjlubj)}(henum dma_resv_usage usageh](j)}(hj+h]henum}(hjnhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjnubj)}(h h]h }(hj)nhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjnubh)}(hhh]j )}(hdma_resv_usageh]hdma_resv_usage}(hj:nhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj7nubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj )j? huh1jhjlhMJhjlhhubjA )}(hhh]h)}(h"replace fences in the dma_resv objh]h"replace fences in the dma_resv obj}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMJhjnhhubah}(h]h ]h"]h$]h&]uh1j@ hjlhhhjlhMJubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jnjc jnjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv *obj`` the reservation object ``uint64_t context`` the context of the fences to replace ``struct dma_fence *replacement`` the new fence to use instead ``enum dma_resv_usage usage`` how the new fence is used, see enum dma_resv_usage **Description** Replace fences with a specified context with a new fence. Only valid if the operation represented by the original fence has no longer access to the resources represented by the dma_resv object when the new fence completes. And example for using this is replacing a preemption fence with a page table update fence which makes the resource inaccessible.h](h)}(h**Parameters**h]jr )}(hjnh]h Parameters}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjnubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMNhjnubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjnh]hstruct dma_resv *obj}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjnubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMKhjnubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjnhMKhjnubah}(h]h ]h"]h$]h&]uh1j hjnubeh}(h]h ]h"]h$]h&]uh1j hjnhMKhjnubj )}(h:``uint64_t context`` the context of the fences to replace h](j )}(h``uint64_t context``h]j)}(hj oh]huint64_t context}(hj ohhhNhNubah}(h]h ]h"]h$]h&]uh1jhjoubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMLhjoubj )}(hhh]h)}(h$the context of the fences to replaceh]h$the context of the fences to replace}(hj#ohhhNhNubah}(h]h ]h"]h$]h&]uh1hhjohMLhj oubah}(h]h ]h"]h$]h&]uh1j hjoubeh}(h]h ]h"]h$]h&]uh1j hjohMLhjnubj )}(h?``struct dma_fence *replacement`` the new fence to use instead h](j )}(h!``struct dma_fence *replacement``h]j)}(hjCoh]hstruct dma_fence *replacement}(hjEohhhNhNubah}(h]h ]h"]h$]h&]uh1jhjAoubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMMhj=oubj )}(hhh]h)}(hthe new fence to use insteadh]hthe new fence to use instead}(hj\ohhhNhNubah}(h]h ]h"]h$]h&]uh1hhjXohMMhjYoubah}(h]h ]h"]h$]h&]uh1j hj=oubeh}(h]h ]h"]h$]h&]uh1j hjXohMMhjnubj )}(hQ``enum dma_resv_usage usage`` how the new fence is used, see enum dma_resv_usage h](j )}(h``enum dma_resv_usage usage``h]j)}(hj|oh]henum dma_resv_usage usage}(hj~ohhhNhNubah}(h]h ]h"]h$]h&]uh1jhjzoubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMNhjvoubj )}(hhh]h)}(h2how the new fence is used, see enum dma_resv_usageh]h2how the new fence is used, see enum dma_resv_usage}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1hhjohMNhjoubah}(h]h ]h"]h$]h&]uh1j hjvoubeh}(h]h ]h"]h$]h&]uh1j hjohMNhjnubeh}(h]h ]h"]h$]h&]uh1j hjnubh)}(h**Description**h]jr )}(hjoh]h Description}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjoubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMPhjnubh)}(hReplace fences with a specified context with a new fence. Only valid if the operation represented by the original fence has no longer access to the resources represented by the dma_resv object when the new fence completes.h]hReplace fences with a specified context with a new fence. Only valid if the operation represented by the original fence has no longer access to the resources represented by the dma_resv object when the new fence completes.}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMOhjnubh)}(hAnd example for using this is replacing a preemption fence with a page table update fence which makes the resource inaccessible.h]hAnd example for using this is replacing a preemption fence with a page table update fence which makes the resource inaccessible.}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMShjnubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j)dma_resv_iter_first_unlocked (C function)c.dma_resv_iter_first_unlockedhNtauh1jhjbhhhNhNubj)}(hhh](j)}(hNstruct dma_fence * dma_resv_iter_first_unlocked (struct dma_resv_iter *cursor)h]j)}(hLstruct dma_fence *dma_resv_iter_first_unlocked(struct dma_resv_iter *cursor)h](j)}(hjh]hstruct}(hj phhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjphhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hjphhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjphhhjphMubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj*phhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj'pubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj,pmodnameN classnameNjj)}j]jO)}jGdma_resv_iter_first_unlockedsbc.dma_resv_iter_first_unlockedasbuh1hhjphhhjphMubj)}(h h]h }(hjKphhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjphhhjphMubjd)}(hjgh]h*}(hjYphhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjphhhjphMubj )}(hdma_resv_iter_first_unlockedh]j )}(hjHph]hdma_resv_iter_first_unlocked}(hjjphhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjfpubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjphhhjphMubj)}(h(struct dma_resv_iter *cursor)h]j)}(hstruct dma_resv_iter *cursorh](j)}(hjh]hstruct}(hjphhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjpubj)}(h h]h }(hjphhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjpubh)}(hhh]j )}(h dma_resv_iterh]h dma_resv_iter}(hjphhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjpubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjpmodnameN classnameNjj)}j]jFpc.dma_resv_iter_first_unlockedasbuh1hhjpubj)}(h h]h }(hjphhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjpubjd)}(hjgh]h*}(hjphhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjpubj )}(hcursorh]hcursor}(hjphhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjpubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj}pubah}(h]h ]h"]h$]h&]jjuh1jhjphhhjphMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjphhhjphMubah}(h]joah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjphMhjphhubjA )}(hhh]h)}(h(first fence in an unlocked dma_resv obj.h]h(first fence in an unlocked dma_resv obj.}(hjqhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjqhhubah}(h]h ]h"]h$]h&]uh1j@ hjphhhjphMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jqjc jqjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv_iter *cursor`` the cursor with the current position **Description** Subsequent fences are iterated with dma_resv_iter_next_unlocked(). Beware that the iterator can be restarted. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted(). For this reason prefer the locked dma_resv_iter_first() whenever possible. Returns the first fence from an unlocked dma_resv obj.h](h)}(h**Parameters**h]jr )}(hj(qh]h Parameters}(hj*qhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj&qubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj"qubj )}(hhh]j )}(hF``struct dma_resv_iter *cursor`` the cursor with the current position h](j )}(h ``struct dma_resv_iter *cursor``h]j)}(hjGqh]hstruct dma_resv_iter *cursor}(hjIqhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjEqubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjAqubj )}(hhh]h)}(h$the cursor with the current positionh]h$the cursor with the current position}(hj`qhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj\qhMhj]qubah}(h]h ]h"]h$]h&]uh1j hjAqubeh}(h]h ]h"]h$]h&]uh1j hj\qhMhj>qubah}(h]h ]h"]h$]h&]uh1j hj"qubh)}(h**Description**h]jr )}(hjqh]h Description}(hjqhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjqubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj"qubh)}(hBSubsequent fences are iterated with dma_resv_iter_next_unlocked().h]hBSubsequent fences are iterated with dma_resv_iter_next_unlocked().}(hjqhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj"qubh)}(hBeware that the iterator can be restarted. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted(). For this reason prefer the locked dma_resv_iter_first() whenever possible.h]hBeware that the iterator can be restarted. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted(). For this reason prefer the locked dma_resv_iter_first() whenever possible.}(hjqhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj"qubh)}(h6Returns the first fence from an unlocked dma_resv obj.h]h6Returns the first fence from an unlocked dma_resv obj.}(hjqhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj"qubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j(dma_resv_iter_next_unlocked (C function)c.dma_resv_iter_next_unlockedhNtauh1jhjbhhhNhNubj)}(hhh](j)}(hMstruct dma_fence * dma_resv_iter_next_unlocked (struct dma_resv_iter *cursor)h]j)}(hKstruct dma_fence *dma_resv_iter_next_unlocked(struct dma_resv_iter *cursor)h](j)}(hjh]hstruct}(hjqhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjqhhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hjqhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjqhhhjqhMubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjrhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjrubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjrmodnameN classnameNjj)}j]jO)}jGdma_resv_iter_next_unlockedsbc.dma_resv_iter_next_unlockedasbuh1hhjqhhhjqhMubj)}(h h]h }(hj%rhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjqhhhjqhMubjd)}(hjgh]h*}(hj3rhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjqhhhjqhMubj )}(hdma_resv_iter_next_unlockedh]j )}(hj"rh]hdma_resv_iter_next_unlocked}(hjDrhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj@rubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjqhhhjqhMubj)}(h(struct dma_resv_iter *cursor)h]j)}(hstruct dma_resv_iter *cursorh](j)}(hjh]hstruct}(hj_rhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[rubj)}(h h]h }(hjlrhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj[rubh)}(hhh]j )}(h dma_resv_iterh]h dma_resv_iter}(hj}rhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjzrubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjrmodnameN classnameNjj)}j]j rc.dma_resv_iter_next_unlockedasbuh1hhj[rubj)}(h h]h }(hjrhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj[rubjd)}(hjgh]h*}(hjrhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj[rubj )}(hcursorh]hcursor}(hjrhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj[rubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjWrubah}(h]h ]h"]h$]h&]jjuh1jhjqhhhjqhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjqhhhjqhMubah}(h]jqah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjqhMhjqhhubjA )}(hhh]h)}(h'next fence in an unlocked dma_resv obj.h]h'next fence in an unlocked dma_resv obj.}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjrhhubah}(h]h ]h"]h$]h&]uh1j@ hjqhhhjqhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jrjc jrjd je jf uh1jhhhjbhNhNubjh )}(hX~**Parameters** ``struct dma_resv_iter *cursor`` the cursor with the current position **Description** Beware that the iterator can be restarted. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted(). For this reason prefer the locked dma_resv_iter_next() whenever possible. Returns the next fence from an unlocked dma_resv obj.h](h)}(h**Parameters**h]jr )}(hjsh]h Parameters}(hjshhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjsubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjrubj )}(hhh]j )}(hF``struct dma_resv_iter *cursor`` the cursor with the current position h](j )}(h ``struct dma_resv_iter *cursor``h]j)}(hj!sh]hstruct dma_resv_iter *cursor}(hj#shhhNhNubah}(h]h ]h"]h$]h&]uh1jhjsubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjsubj )}(hhh]h)}(h$the cursor with the current positionh]h$the cursor with the current position}(hj:shhhNhNubah}(h]h ]h"]h$]h&]uh1hhj6shMhj7subah}(h]h ]h"]h$]h&]uh1j hjsubeh}(h]h ]h"]h$]h&]uh1j hj6shMhjsubah}(h]h ]h"]h$]h&]uh1j hjrubh)}(h**Description**h]jr )}(hj\sh]h Description}(hj^shhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjZsubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjrubh)}(hBeware that the iterator can be restarted. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted(). For this reason prefer the locked dma_resv_iter_next() whenever possible.h]hBeware that the iterator can be restarted. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted(). For this reason prefer the locked dma_resv_iter_next() whenever possible.}(hjrshhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.c hMhjrubh)}(h5Returns the next fence from an unlocked dma_resv obj.h]h5Returns the next fence from an unlocked dma_resv obj.}(hjshhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjrubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j dma_resv_iter_first (C function)c.dma_resv_iter_firsthNtauh1jhjbhhhNhNubj)}(hhh](j)}(hEstruct dma_fence * dma_resv_iter_first (struct dma_resv_iter *cursor)h]j)}(hCstruct dma_fence *dma_resv_iter_first(struct dma_resv_iter *cursor)h](j)}(hjh]hstruct}(hjshhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjshhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hjshhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjshhhjshMubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjshhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjsubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjsmodnameN classnameNjj)}j]jO)}jGdma_resv_iter_firstsbc.dma_resv_iter_firstasbuh1hhjshhhjshMubj)}(h h]h }(hjshhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjshhhjshMubjd)}(hjgh]h*}(hjshhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjshhhjshMubj )}(hdma_resv_iter_firsth]j )}(hjsh]hdma_resv_iter_first}(hjthhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj tubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjshhhjshMubj)}(h(struct dma_resv_iter *cursor)h]j)}(hstruct dma_resv_iter *cursorh](j)}(hjh]hstruct}(hj*thhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj&tubj)}(h h]h }(hj7thhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj&tubh)}(hhh]j )}(h dma_resv_iterh]h dma_resv_iter}(hjHthhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjEtubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjJtmodnameN classnameNjj)}j]jsc.dma_resv_iter_firstasbuh1hhj&tubj)}(h h]h }(hjfthhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj&tubjd)}(hjgh]h*}(hjtthhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj&tubj )}(hcursorh]hcursor}(hjthhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj&tubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj"tubah}(h]h ]h"]h$]h&]jjuh1jhjshhhjshMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjshhhjshMubah}(h]jsah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjshMhjshhubjA )}(hhh]h)}(h)first fence from a locked dma_resv objecth]h)first fence from a locked dma_resv object}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjthhubah}(h]h ]h"]h$]h&]uh1j@ hjshhhjshMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jtjc jtjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv_iter *cursor`` cursor to record the current position **Description** Subsequent fences are iterated with dma_resv_iter_next_unlocked(). Return the first fence in the dma_resv object while holding the :c:type:`dma_resv.lock `.h](h)}(h**Parameters**h]jr )}(hjth]h Parameters}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjtubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjtubj )}(hhh]j )}(hG``struct dma_resv_iter *cursor`` cursor to record the current position h](j )}(h ``struct dma_resv_iter *cursor``h]j)}(hjth]hstruct dma_resv_iter *cursor}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1jhjtubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjtubj )}(hhh]h)}(h%cursor to record the current positionh]h%cursor to record the current position}(hjuhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjuhMhjuubah}(h]h ]h"]h$]h&]uh1j hjtubeh}(h]h ]h"]h$]h&]uh1j hjuhMhjtubah}(h]h ]h"]h$]h&]uh1j hjtubh)}(h**Description**h]jr )}(hj'uh]h Description}(hj)uhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj%uubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjtubh)}(hBSubsequent fences are iterated with dma_resv_iter_next_unlocked().h]hBSubsequent fences are iterated with dma_resv_iter_next_unlocked().}(hj=uhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjtubh)}(hcReturn the first fence in the dma_resv object while holding the :c:type:`dma_resv.lock `.h](h@Return the first fence in the dma_resv object while holding the }(hjLuhhhNhNubh)}(h":c:type:`dma_resv.lock `h]j)}(hjVuh]h dma_resv.lock}(hjXuhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjTuubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_resvuh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjLuubh.}(hjLuhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjsuhMhjtubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_iter_next (C function)c.dma_resv_iter_nexthNtauh1jhjbhhhNhNubj)}(hhh](j)}(hDstruct dma_fence * dma_resv_iter_next (struct dma_resv_iter *cursor)h]j)}(hBstruct dma_fence *dma_resv_iter_next(struct dma_resv_iter *cursor)h](j)}(hjh]hstruct}(hjuhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjuhhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hjuhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjuhhhjuhMubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjuhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjuubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjumodnameN classnameNjj)}j]jO)}jGdma_resv_iter_nextsbc.dma_resv_iter_nextasbuh1hhjuhhhjuhMubj)}(h h]h }(hjuhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjuhhhjuhMubjd)}(hjgh]h*}(hjuhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjuhhhjuhMubj )}(hdma_resv_iter_nexth]j )}(hjuh]hdma_resv_iter_next}(hjuhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjuubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjuhhhjuhMubj)}(h(struct dma_resv_iter *cursor)h]j)}(hstruct dma_resv_iter *cursorh](j)}(hjh]hstruct}(hjvhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjvubj)}(h h]h }(hj%vhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjvubh)}(hhh]j )}(h dma_resv_iterh]h dma_resv_iter}(hj6vhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj3vubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj8vmodnameN classnameNjj)}j]juc.dma_resv_iter_nextasbuh1hhjvubj)}(h h]h }(hjTvhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjvubjd)}(hjgh]h*}(hjbvhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjvubj )}(hcursorh]hcursor}(hjovhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjvubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjvubah}(h]h ]h"]h$]h&]jjuh1jhjuhhhjuhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjuhhhjuhMubah}(h]juah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjuhMhjuhhubjA )}(hhh]h)}(h(next fence from a locked dma_resv objecth]h(next fence from a locked dma_resv object}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjvhhubah}(h]h ]h"]h$]h&]uh1j@ hjuhhhjuhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jvjc jvjd je jf uh1jhhhjbhNhNubjh )}(h**Parameters** ``struct dma_resv_iter *cursor`` cursor to record the current position **Description** Return the next fences from the dma_resv object while holding the :c:type:`dma_resv.lock `.h](h)}(h**Parameters**h]jr )}(hjvh]h Parameters}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjvubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjvubj )}(hhh]j )}(hG``struct dma_resv_iter *cursor`` cursor to record the current position h](j )}(h ``struct dma_resv_iter *cursor``h]j)}(hjvh]hstruct dma_resv_iter *cursor}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjvubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjvubj )}(hhh]h)}(h%cursor to record the current positionh]h%cursor to record the current position}(hjvhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjvhMhjvubah}(h]h ]h"]h$]h&]uh1j hjvubeh}(h]h ]h"]h$]h&]uh1j hjvhMhjvubah}(h]h ]h"]h$]h&]uh1j hjvubh)}(h**Description**h]jr )}(hjwh]h Description}(hjwhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjwubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjvubh)}(heReturn the next fences from the dma_resv object while holding the :c:type:`dma_resv.lock `.h](hBReturn the next fences from the dma_resv object while holding the }(hj+whhhNhNubh)}(h":c:type:`dma_resv.lock `h]j)}(hj5wh]h dma_resv.lock}(hj7whhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj3wubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_resvuh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj+wubh.}(hj+whhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjRwhMhjvubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j!dma_resv_copy_fences (C function)c.dma_resv_copy_fenceshNtauh1jhjbhhhNhNubj)}(hhh](j)}(hEint dma_resv_copy_fences (struct dma_resv *dst, struct dma_resv *src)h]j)}(hDint dma_resv_copy_fences(struct dma_resv *dst, struct dma_resv *src)h](jM)}(hinth]hint}(hj}whhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjywhhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hjwhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjywhhhjwhMubj )}(hdma_resv_copy_fencesh]j )}(hdma_resv_copy_fencesh]hdma_resv_copy_fences}(hjwhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjwubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjywhhhjwhMubj)}(h,(struct dma_resv *dst, struct dma_resv *src)h](j)}(hstruct dma_resv *dsth](j)}(hjh]hstruct}(hjwhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjwubj)}(h h]h }(hjwhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjwubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjwhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjwubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjwmodnameN classnameNjj)}j]jO)}jGjwsbc.dma_resv_copy_fencesasbuh1hhjwubj)}(h h]h }(hjwhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjwubjd)}(hjgh]h*}(hjxhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjwubj )}(hdsth]hdst}(hjxhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjwubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjwubj)}(hstruct dma_resv *srch](j)}(hjh]hstruct}(hj,xhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj(xubj)}(h h]h }(hj9xhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj(xubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjJxhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjGxubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjLxmodnameN classnameNjj)}j]jwc.dma_resv_copy_fencesasbuh1hhj(xubj)}(h h]h }(hjhxhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj(xubjd)}(hjgh]h*}(hjvxhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj(xubj )}(hsrch]hsrc}(hjxhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj(xubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjwubeh}(h]h ]h"]h$]h&]jjuh1jhjywhhhjwhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjuwhhhjwhMubah}(h]jpwah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjwhMhjrwhhubjA )}(hhh]h)}(h Copy all fences from src to dst.h]h Copy all fences from src to dst.}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjxhhubah}(h]h ]h"]h$]h&]uh1j@ hjrwhhhjwhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jxjc jxjd je jf uh1jhhhjbhNhNubjh )}(h**Parameters** ``struct dma_resv *dst`` the destination reservation object ``struct dma_resv *src`` the source reservation object **Description** Copy all fences from src to dst. dst-lock must be held.h](h)}(h**Parameters**h]jr )}(hjxh]h Parameters}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjxubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjxubj )}(hhh](j )}(h<``struct dma_resv *dst`` the destination reservation object h](j )}(h``struct dma_resv *dst``h]j)}(hjxh]hstruct dma_resv *dst}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjxubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjxubj )}(hhh]h)}(h"the destination reservation objecth]h"the destination reservation object}(hjyhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjyhMhjyubah}(h]h ]h"]h$]h&]uh1j hjxubeh}(h]h ]h"]h$]h&]uh1j hjyhMhjxubj )}(h7``struct dma_resv *src`` the source reservation object h](j )}(h``struct dma_resv *src``h]j)}(hj'yh]hstruct dma_resv *src}(hj)yhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj%yubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj!yubj )}(hhh]h)}(hthe source reservation objecth]hthe source reservation object}(hj@yhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj )j? huh1jhjyhM.hjyhhubjA )}(hhh]h)}(h;Get an object's fences fences without update side lock heldh]h=Get an object’s fences fences without update side lock held}(hj{hhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chM.hj{hhubah}(h]h ]h"]h$]h&]uh1j@ hjyhhhjyhM.ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j{jc j{jd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv *obj`` the reservation object ``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage. ``unsigned int *num_fences`` the number of fences returned ``struct dma_fence ***fences`` the array of fence ptrs returned (array is krealloc'd to the required size, and must be freed by caller) **Description** Retrieve all fences from the reservation object. Returns either zero or -ENOMEM.h](h)}(h**Parameters**h]jr )}(hj{h]h Parameters}(hj{hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj{ubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chM2hj{ubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hj{h]hstruct dma_resv *obj}(hj{hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj{ubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chM0hj{ubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hj |hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj|hM0hj |ubah}(h]h ]h"]h$]h&]uh1j hj{ubeh}(h]h ]h"]h$]h&]uh1j hj|hM0hj{ubj )}(hY``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage. h](j )}(h``enum dma_resv_usage usage``h]j)}(hj,|h]henum dma_resv_usage usage}(hj.|hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj*|ubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chM1hj&|ubj )}(hhh]h)}(h:controls which fences to include, see enum dma_resv_usage.h]h:controls which fences to include, see enum dma_resv_usage.}(hjE|hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjA|hM1hjB|ubah}(h]h ]h"]h$]h&]uh1j hj&|ubeh}(h]h ]h"]h$]h&]uh1j hjA|hM1hj{ubj )}(h;``unsigned int *num_fences`` the number of fences returned h](j )}(h``unsigned int *num_fences``h]j)}(hje|h]hunsigned int *num_fences}(hjg|hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjc|ubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chM2hj_|ubj )}(hhh]h)}(hthe number of fences returnedh]hthe number of fences returned}(hj~|hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjz|hM2hj{|ubah}(h]h ]h"]h$]h&]uh1j hj_|ubeh}(h]h ]h"]h$]h&]uh1j hjz|hM2hj{ubj )}(h``struct dma_fence ***fences`` the array of fence ptrs returned (array is krealloc'd to the required size, and must be freed by caller) h](j )}(h``struct dma_fence ***fences``h]j)}(hj|h]hstruct dma_fence ***fences}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj|ubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chM4hj|ubj )}(hhh]h)}(hhthe array of fence ptrs returned (array is krealloc'd to the required size, and must be freed by caller)h]hjthe array of fence ptrs returned (array is krealloc’d to the required size, and must be freed by caller)}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chM3hj|ubah}(h]h ]h"]h$]h&]uh1j hj|ubeh}(h]h ]h"]h$]h&]uh1j hj|hM4hj{ubeh}(h]h ]h"]h$]h&]uh1j hj{ubh)}(h**Description**h]jr )}(hj|h]h Description}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj|ubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chM6hj{ubh)}(hPRetrieve all fences from the reservation object. Returns either zero or -ENOMEM.h]hPRetrieve all fences from the reservation object. Returns either zero or -ENOMEM.}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chM5hj{ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_resv_get_singleton (C function)c.dma_resv_get_singletonhNtauh1jhjbhhhNhNubj)}(hhh](j)}(hfint dma_resv_get_singleton (struct dma_resv *obj, enum dma_resv_usage usage, struct dma_fence **fence)h]j)}(heint dma_resv_get_singleton(struct dma_resv *obj, enum dma_resv_usage usage, struct dma_fence **fence)h](jM)}(hinth]hint}(hj}hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj}hhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMeubj)}(h h]h }(hj.}hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj}hhhj-}hMeubj )}(hdma_resv_get_singletonh]j )}(hdma_resv_get_singletonh]hdma_resv_get_singleton}(hj@}hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj<}ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj}hhhj-}hMeubj)}(hK(struct dma_resv *obj, enum dma_resv_usage usage, struct dma_fence **fence)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hj\}hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjX}ubj)}(h h]h }(hji}hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjX}ubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjz}hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjw}ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj|}modnameN classnameNjj)}j]jO)}jGjB}sbc.dma_resv_get_singletonasbuh1hhjX}ubj)}(h h]h }(hj}hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjX}ubjd)}(hjgh]h*}(hj}hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjX}ubj )}(hobjh]hobj}(hj}hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjX}ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjT}ubj)}(henum dma_resv_usage usageh](j)}(hj+h]henum}(hj}hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj}ubj)}(h h]h }(hj}hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj}ubh)}(hhh]j )}(hdma_resv_usageh]hdma_resv_usage}(hj}hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj}ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj}modnameN classnameNjj)}j]j}c.dma_resv_get_singletonasbuh1hhj}ubj)}(h h]h }(hj ~hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj}ubj )}(husageh]husage}(hj~hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj}ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjT}ubj)}(hstruct dma_fence **fenceh](j)}(hjh]hstruct}(hj1~hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj-~ubj)}(h h]h }(hj>~hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj-~ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjO~hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjL~ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjQ~modnameN classnameNjj)}j]j}c.dma_resv_get_singletonasbuh1hhj-~ubj)}(h h]h }(hjm~hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj-~ubjd)}(hjgh]h*}(hj{~hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj-~ubjd)}(hjgh]h*}(hj~hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj-~ubj )}(hfenceh]hfence}(hj~hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj-~ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjT}ubeh}(h]h ]h"]h$]h&]jjuh1jhj}hhhj-}hMeubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj}hhhj-}hMeubah}(h]j}ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj-}hMehj}hhubjA )}(hhh]h)}(h%Get a single fence for all the fencesh]h%Get a single fence for all the fences}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMehj~hhubah}(h]h ]h"]h$]h&]uh1j@ hj}hhhj-}hMeubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j~jc j~jd je jf uh1jhhhjbhNhNubjh )}(hX1**Parameters** ``struct dma_resv *obj`` the reservation object ``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage. ``struct dma_fence **fence`` the resulting fence **Description** Get a single fence representing all the fences inside the resv object. Returns either 0 for success or -ENOMEM. Warning: This can't be used like this when adding the fence back to the resv object since that can lead to stack corruption when finalizing the dma_fence_array. Returns 0 on success and negative error values on failure.h](h)}(h**Parameters**h]jr )}(hj~h]h Parameters}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj~ubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMihj~ubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjh]hstruct dma_resv *obj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj~ubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMfhj~ubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMfhjubah}(h]h ]h"]h$]h&]uh1j hj~ubeh}(h]h ]h"]h$]h&]uh1j hjhMfhj~ubj )}(hY``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage. h](j )}(h``enum dma_resv_usage usage``h]j)}(hj9h]henum dma_resv_usage usage}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj7ubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMghj3ubj )}(hhh]h)}(h:controls which fences to include, see enum dma_resv_usage.h]h:controls which fences to include, see enum dma_resv_usage.}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjNhMghjOubah}(h]h ]h"]h$]h&]uh1j hj3ubeh}(h]h ]h"]h$]h&]uh1j hjNhMghj~ubj )}(h1``struct dma_fence **fence`` the resulting fence h](j )}(h``struct dma_fence **fence``h]j)}(hjrh]hstruct dma_fence **fence}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1jhjpubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhhjlubj )}(hhh]h)}(hthe resulting fenceh]hthe resulting fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhhjubah}(h]h ]h"]h$]h&]uh1j hjlubeh}(h]h ]h"]h$]h&]uh1j hjhMhhj~ubeh}(h]h ]h"]h$]h&]uh1j hj~ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMjhj~ubh)}(hoGet a single fence representing all the fences inside the resv object. Returns either 0 for success or -ENOMEM.h]hoGet a single fence representing all the fences inside the resv object. Returns either 0 for success or -ENOMEM.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMihj~ubh)}(hWarning: This can't be used like this when adding the fence back to the resv object since that can lead to stack corruption when finalizing the dma_fence_array.h]hWarning: This can’t be used like this when adding the fence back to the resv object since that can lead to stack corruption when finalizing the dma_fence_array.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMlhj~ubh)}(h:Returns 0 on success and negative error values on failure.h]h:Returns 0 on success and negative error values on failure.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMphj~ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j"dma_resv_wait_timeout (C function)c.dma_resv_wait_timeouthNtauh1jhjbhhhNhNubj)}(hhh](j)}(hnlong dma_resv_wait_timeout (struct dma_resv *obj, enum dma_resv_usage usage, bool intr, unsigned long timeout)h]j)}(hmlong dma_resv_wait_timeout(struct dma_resv *obj, enum dma_resv_usage usage, bool intr, unsigned long timeout)h](jM)}(hlongh]hlong}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj hhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj hhhjhMubj )}(hdma_resv_wait_timeouth]j )}(hdma_resv_wait_timeouth]hdma_resv_wait_timeout}(hj1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj-ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj hhhjhMubj)}(hS(struct dma_resv *obj, enum dma_resv_usage usage, bool intr, unsigned long timeout)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjMhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjIubj)}(h h]h }(hjZhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjIubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjkhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjhubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmmodnameN classnameNjj)}j]jO)}jGj3sbc.dma_resv_wait_timeoutasbuh1hhjIubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjIubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjIubj )}(hobjh]hobj}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjIubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjEubj)}(henum dma_resv_usage usageh](j)}(hj+h]henum}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj̀hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_resv_usageh]hdma_resv_usage}(hj݀hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjڀubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj߀modnameN classnameNjj)}j]jc.dma_resv_wait_timeoutasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(husageh]husage}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjEubj)}(h bool intrh](jM)}(hji5h]hbool}(hj"hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hj/hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hintrh]hintr}(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjEubj)}(hunsigned long timeouth](jM)}(hunsignedh]hunsigned}(hjVhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjRubj)}(h h]h }(hjdhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjRubjM)}(hlongh]hlong}(hjrhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjRubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjRubj )}(htimeouth]htimeout}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjRubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjEubeh}(h]h ]h"]h$]h&]jjuh1jhj hhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h$Wait on reservation's objects fencesh]h&Wait on reservation’s objects fences}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jЁjc jЁjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv *obj`` the reservation object ``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage. ``bool intr`` if true, do interruptible wait ``unsigned long timeout`` timeout value in jiffies or zero to return immediately **Description** Callers are not required to hold specific locks, but maybe hold dma_resv_lock() already RETURNS Returns -ERESTARTSYS if interrupted, 0 if the wait timed out, or greater than zero on success.h](h)}(h**Parameters**h]jr )}(hjځh]h Parameters}(hj܁hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj؁ubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjԁubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjh]hstruct dma_resv *obj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubj )}(hY``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage. h](j )}(h``enum dma_resv_usage usage``h]j)}(hj2h]henum dma_resv_usage usage}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj0ubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj,ubj )}(hhh]h)}(h:controls which fences to include, see enum dma_resv_usage.h]h:controls which fences to include, see enum dma_resv_usage.}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjGhMhjHubah}(h]h ]h"]h$]h&]uh1j hj,ubeh}(h]h ]h"]h$]h&]uh1j hjGhMhjubj )}(h-``bool intr`` if true, do interruptible wait h](j )}(h ``bool intr``h]j)}(hjkh]h bool intr}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjiubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjeubj )}(hhh]h)}(hif true, do interruptible waith]hif true, do interruptible wait}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjeubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubj )}(hQ``unsigned long timeout`` timeout value in jiffies or zero to return immediately h](j )}(h``unsigned long timeout``h]j)}(hjh]hunsigned long timeout}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjubj )}(hhh]h)}(h6timeout value in jiffies or zero to return immediatelyh]h6timeout value in jiffies or zero to return immediately}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubeh}(h]h ]h"]h$]h&]uh1j hjԁubh)}(h**Description**h]jr )}(hj߂h]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj݂ubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjԁubh)}(hCallers are not required to hold specific locks, but maybe hold dma_resv_lock() already RETURNS Returns -ERESTARTSYS if interrupted, 0 if the wait timed out, or greater than zero on success.h]hCallers are not required to hold specific locks, but maybe hold dma_resv_lock() already RETURNS Returns -ERESTARTSYS if interrupted, 0 if the wait timed out, or greater than zero on success.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjԁubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j"dma_resv_set_deadline (C function)c.dma_resv_set_deadlinehNtauh1jhjbhhhNhNubj)}(hhh](j)}(h^void dma_resv_set_deadline (struct dma_resv *obj, enum dma_resv_usage usage, ktime_t deadline)h]j)}(h]void dma_resv_set_deadline(struct dma_resv *obj, enum dma_resv_usage usage, ktime_t deadline)h](jM)}(hvoidh]hvoid}(hj$hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj hhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj hhhj2hMubj )}(hdma_resv_set_deadlineh]j )}(hdma_resv_set_deadlineh]hdma_resv_set_deadline}(hjEhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjAubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj hhhj2hMubj)}(hC(struct dma_resv *obj, enum dma_resv_usage usage, ktime_t deadline)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjahhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj]ubj)}(h h]h }(hjnhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj]ubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj|ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjGsbc.dma_resv_set_deadlineasbuh1hhj]ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj]ubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj]ubj )}(hobjh]hobj}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj]ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjYubj)}(henum dma_resv_usage usageh](j)}(hj+h]henum}(hjӃhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjσubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjσubh)}(hhh]j )}(hdma_resv_usageh]hdma_resv_usage}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_resv_set_deadlineasbuh1hhjσubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjσubj )}(husageh]husage}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjσubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjYubj)}(hktime_t deadlineh](h)}(hhh]j )}(hktime_th]hktime_t}(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj6ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj;modnameN classnameNjj)}j]jc.dma_resv_set_deadlineasbuh1hhj2ubj)}(h h]h }(hjWhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj2ubj )}(hdeadlineh]hdeadline}(hjehhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj2ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjYubeh}(h]h ]h"]h$]h&]jjuh1jhj hhhj2hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhj2hMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj2hMhjhhubjA )}(hhh]h)}(h.Set a deadline on reservation's objects fencesh]h0Set a deadline on reservation’s objects fences}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhj2hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(hXS**Parameters** ``struct dma_resv *obj`` the reservation object ``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage. ``ktime_t deadline`` the requested deadline (MONOTONIC) **Description** May be called without holding the dma_resv lock. Sets **deadline** on all fences filtered by **usage**.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjЄh]hstruct dma_resv *obj}(hj҄hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj΄ubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjʄubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjʄubeh}(h]h ]h"]h$]h&]uh1j hjhMhjDŽubj )}(hY``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage. h](j )}(h``enum dma_resv_usage usage``h]j)}(hj h]henum dma_resv_usage usage}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjubj )}(hhh]h)}(h:controls which fences to include, see enum dma_resv_usage.h]h:controls which fences to include, see enum dma_resv_usage.}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjDŽubj )}(h8``ktime_t deadline`` the requested deadline (MONOTONIC) h](j )}(h``ktime_t deadline``h]j)}(hjBh]hktime_t deadline}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj@ubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj<ubj )}(hhh]h)}(h"the requested deadline (MONOTONIC)h]h"the requested deadline (MONOTONIC)}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjWhMhjXubah}(h]h ]h"]h$]h&]uh1j hj<ubeh}(h]h ]h"]h$]h&]uh1j hjWhMhjDŽubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj}h]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj{ubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjubh)}(hhMay be called without holding the dma_resv lock. Sets **deadline** on all fences filtered by **usage**.h](h7May be called without holding the dma_resv lock. Sets }(hjhhhNhNubjr )}(h **deadline**h]hdeadline}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh on all fences filtered by }(hjhhhNhNubjr )}(h **usage**h]husage}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_resv_test_signaled (C function)c.dma_resv_test_signaledhNtauh1jhjbhhhNhNubj)}(hhh](j)}(hMbool dma_resv_test_signaled (struct dma_resv *obj, enum dma_resv_usage usage)h]j)}(hLbool dma_resv_test_signaled(struct dma_resv *obj, enum dma_resv_usage usage)h](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(hdma_resv_test_signaledh]j )}(hdma_resv_test_signaledh]hdma_resv_test_signaled}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(h1(struct dma_resv *obj, enum dma_resv_usage usage)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hj"hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj/hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hj@hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj=ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjBmodnameN classnameNjj)}j]jO)}jGjsbc.dma_resv_test_signaledasbuh1hhjubj)}(h h]h }(hj`hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjnhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hobjh]hobj}(hj{hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(henum dma_resv_usage usageh](j)}(hj+h]henum}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_resv_usageh]hdma_resv_usage}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]j\c.dma_resv_test_signaledasbuh1hhjubj)}(h h]h }(hjІhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(husageh]husage}(hjކhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjޅhhhjhMubah}(h]jمah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjۅhhubjA )}(hhh]h)}(h9Test if a reservation object's fences have been signaled.h]h;Test if a reservation object’s fences have been signaled.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjۅhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j jc j jd je jf uh1jhhhjbhNhNubjh )}(hX;**Parameters** ``struct dma_resv *obj`` the reservation object ``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage. **Description** Callers are not required to hold specific locks, but maybe hold dma_resv_lock() already. RETURNS True if all fences signaled, else false.h](h)}(h**Parameters**h]jr )}(hj*h]h Parameters}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj(ubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj$ubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjIh]hstruct dma_resv *obj}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjGubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjCubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj^hMhj_ubah}(h]h ]h"]h$]h&]uh1j hjCubeh}(h]h ]h"]h$]h&]uh1j hj^hMhj@ubj )}(hY``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage. h](j )}(h``enum dma_resv_usage usage``h]j)}(hjh]henum dma_resv_usage usage}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj|ubj )}(hhh]h)}(h:controls which fences to include, see enum dma_resv_usage.h]h:controls which fences to include, see enum dma_resv_usage.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hj|ubeh}(h]h ]h"]h$]h&]uh1j hjhMhj@ubeh}(h]h ]h"]h$]h&]uh1j hj$ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj$ubh)}(hXCallers are not required to hold specific locks, but maybe hold dma_resv_lock() already.h]hXCallers are not required to hold specific locks, but maybe hold dma_resv_lock() already.}(hjӇhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj$ubh)}(hRETURNSh]hRETURNS}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj$ubh)}(h(True if all fences signaled, else false.h]h(True if all fences signaled, else false.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhj$ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_describe (C function)c.dma_resv_describehNtauh1jhjbhhhNhNubj)}(hhh](j)}(hCvoid dma_resv_describe (struct dma_resv *obj, struct seq_file *seq)h]j)}(hBvoid dma_resv_describe(struct dma_resv *obj, struct seq_file *seq)h](jM)}(hvoidh]hvoid}(hj hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMubj)}(h h]h }(hj/hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhj.hMubj )}(hdma_resv_describeh]j )}(hdma_resv_describeh]hdma_resv_describe}(hjAhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj=ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhj.hMubj)}(h,(struct dma_resv *obj, struct seq_file *seq)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hj]hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjYubj)}(h h]h }(hjjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjYubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hj{hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjxubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj}modnameN classnameNjj)}j]jO)}jGjCsbc.dma_resv_describeasbuh1hhjYubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjYubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjYubj )}(hobjh]hobj}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjYubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjUubj)}(hstruct seq_file *seqh](j)}(hjh]hstruct}(hjψhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjˈubj)}(h h]h }(hj܈hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjˈubh)}(hhh]j )}(hseq_fileh]hseq_file}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_resv_describeasbuh1hhjˈubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjˈubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjˈubj )}(hseqh]hseq}(hj&hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjˈubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjUubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhj.hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhj.hMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj.hMhjhhubjA )}(hhh]h)}(h1Dump description of the resv object into seq_fileh]h1Dump description of the resv object into seq_file}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjMhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhj.hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jhjc jhjd je jf uh1jhhhjbhNhNubjh )}(h**Parameters** ``struct dma_resv *obj`` the reservation object ``struct seq_file *seq`` the seq_file to dump the description into **Description** Dump a textual description of the fences inside an dma_resv object into the seq_file.h](h)}(h**Parameters**h]jr )}(hjrh]h Parameters}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjpubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjlubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjh]hstruct dma_resv *obj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubj )}(hC``struct seq_file *seq`` the seq_file to dump the description into h](j )}(h``struct seq_file *seq``h]j)}(hjʉh]hstruct seq_file *seq}(hj̉hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjȉubah}(h]h ]h"]h$]h&]uh1j h^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjĉubj )}(hhh]h)}(h)the seq_file to dump the description intoh]h)the seq_file to dump the description into}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj߉hMhjubah}(h]h ]h"]h$]h&]uh1j hjĉubeh}(h]h ]h"]h$]h&]uh1j hj߉hMhjubeh}(h]h ]h"]h$]h&]uh1j hjlubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjlubh)}(hUDump a textual description of the fences inside an dma_resv object into the seq_file.h]hUDump a textual description of the fences inside an dma_resv object into the seq_file.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh^/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:154: ./drivers/dma-buf/dma-resv.chMhjlubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_usage (C enum)c.dma_resv_usagehNtauh1jhjbhhhNhNubj)}(hhh](j)}(hdma_resv_usageh]j)}(henum dma_resv_usageh](j)}(hj+h]henum}(hjJhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjFhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKubj)}(h h]h }(hjXhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjFhhhjWhKubj )}(hdma_resv_usageh]j )}(hjDh]hdma_resv_usage}(hjjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjfubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjFhhhjWhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjBhhhjWhKubah}(h]j=ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjWhKhj?hhubjA )}(hhh]h)}(h+how the fences from a dma_resv obj are usedh]h+how the fences from a dma_resv obj are used}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhK5hjhhubah}(h]h ]h"]h$]h&]uh1j@ hj?hhhjWhKubeh}(h]h ](jenumeh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(hX**Constants** ``DMA_RESV_USAGE_KERNEL`` For in kernel memory management only. This should only be used for things like copying or clearing memory with a DMA hardware engine for the purpose of kernel memory management. Drivers *always* must wait for those fences before accessing the resource protected by the dma_resv object. The only exception for that is when the resource is known to be locked down in place by pinning it previously. ``DMA_RESV_USAGE_WRITE`` Implicit write synchronization. This should only be used for userspace command submissions which add an implicit write dependency. ``DMA_RESV_USAGE_READ`` Implicit read synchronization. This should only be used for userspace command submissions which add an implicit read dependency. ``DMA_RESV_USAGE_BOOKKEEP`` No implicit sync. This should be used by submissions which don't want to participate in any implicit synchronization. The most common cases are preemption fences, page table updates, TLB flushes as well as explicitly synced user submissions. Explicitly synced user submissions can be promoted to DMA_RESV_USAGE_READ or DMA_RESV_USAGE_WRITE as needed using dma_buf_import_sync_file() when implicit synchronization should become necessary after initial adding of the fence.h](h)}(h **Constants**h]jr )}(hjh]h Constants}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhK9hjubj )}(hhh](j )}(hX``DMA_RESV_USAGE_KERNEL`` For in kernel memory management only. This should only be used for things like copying or clearing memory with a DMA hardware engine for the purpose of kernel memory management. Drivers *always* must wait for those fences before accessing the resource protected by the dma_resv object. The only exception for that is when the resource is known to be locked down in place by pinning it previously. h](j )}(h``DMA_RESV_USAGE_KERNEL``h]j)}(hj͊h]hDMA_RESV_USAGE_KERNEL}(hjϊhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjˊubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKEhjNJubj )}(hhh](h)}(h%For in kernel memory management only.h]h%For in kernel memory management only.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubh)}(hDrivers *always* must wait for those fences before accessing the resource protected by the dma_resv object. The only exception for that is when the resource is known to be locked down in place by pinning it previously.h](hDrivers }(hjhhhNhNubhemphasis)}(h*always*h]halways}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j hjubh must wait for those fences before accessing the resource protected by the dma_resv object. The only exception for that is when the resource is known to be locked down in place by pinning it previously.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKBhjubeh}(h]h ]h"]h$]h&]uh1j hjNJubeh}(h]h ]h"]h$]h&]uh1j hjhKEhjĊubj )}(h``DMA_RESV_USAGE_WRITE`` Implicit write synchronization. This should only be used for userspace command submissions which add an implicit write dependency. h](j )}(h``DMA_RESV_USAGE_WRITE``h]j)}(hj9h]hDMA_RESV_USAGE_WRITE}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj7ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKKhj3ubj )}(hhh](h)}(hImplicit write synchronization.h]hImplicit write synchronization.}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKHhjOubh)}(hbThis should only be used for userspace command submissions which add an implicit write dependency.h]hbThis should only be used for userspace command submissions which add an implicit write dependency.}(hjahhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKJhjOubeh}(h]h ]h"]h$]h&]uh1j hj3ubeh}(h]h ]h"]h$]h&]uh1j hjNhKKhjĊubj )}(h``DMA_RESV_USAGE_READ`` Implicit read synchronization. This should only be used for userspace command submissions which add an implicit read dependency. h](j )}(h``DMA_RESV_USAGE_READ``h]j)}(hjh]hDMA_RESV_USAGE_READ}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKQhj|ubj )}(hhh](h)}(hImplicit read synchronization.h]hImplicit read synchronization.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKNhjubh)}(haThis should only be used for userspace command submissions which add an implicit read dependency.h]haThis should only be used for userspace command submissions which add an implicit read dependency.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKPhjubeh}(h]h ]h"]h$]h&]uh1j hj|ubeh}(h]h ]h"]h$]h&]uh1j hjhKQhjĊubj )}(hX``DMA_RESV_USAGE_BOOKKEEP`` No implicit sync. This should be used by submissions which don't want to participate in any implicit synchronization. The most common cases are preemption fences, page table updates, TLB flushes as well as explicitly synced user submissions. Explicitly synced user submissions can be promoted to DMA_RESV_USAGE_READ or DMA_RESV_USAGE_WRITE as needed using dma_buf_import_sync_file() when implicit synchronization should become necessary after initial adding of the fence.h](j )}(h``DMA_RESV_USAGE_BOOKKEEP``h]j)}(hjˋh]hDMA_RESV_USAGE_BOOKKEEP}(hj͋hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjɋubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhK^hjŋubj )}(hhh](h)}(hNo implicit sync.h]hNo implicit sync.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKThjubh)}(hcThis should be used by submissions which don't want to participate in any implicit synchronization.h]heThis should be used by submissions which don’t want to participate in any implicit synchronization.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKVhjubh)}(h{The most common cases are preemption fences, page table updates, TLB flushes as well as explicitly synced user submissions.h]h{The most common cases are preemption fences, page table updates, TLB flushes as well as explicitly synced user submissions.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKYhjubh)}(hExplicitly synced user submissions can be promoted to DMA_RESV_USAGE_READ or DMA_RESV_USAGE_WRITE as needed using dma_buf_import_sync_file() when implicit synchronization should become necessary after initial adding of the fence.h]hExplicitly synced user submissions can be promoted to DMA_RESV_USAGE_READ or DMA_RESV_USAGE_WRITE as needed using dma_buf_import_sync_file() when implicit synchronization should become necessary after initial adding of the fence.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhK\hjubeh}(h]h ]h"]h$]h&]uh1j hjŋubeh}(h]h ]h"]h$]h&]uh1j hjhK^hjĊubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubh)}(h**Description**h]jr )}(hj;h]h Description}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj9ubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKahjbhhubh)}(hvThis enum describes the different use cases for a dma_resv object and controls which fences are returned when queried.h]hvThis enum describes the different use cases for a dma_resv object and controls which fences are returned when queried.}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhK6hjbhhubh)}(hAn important fact is that there is the order KERNEL )j? huh1jhjhKxhjhhubjA )}(hhh]h)}(hhelper for implicit synch]hhelper for implicit sync}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKxhjUhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhKxubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jpjc jpjd je jf uh1jhhhjbhNhNubjh )}(h**Parameters** ``bool write`` true if we create a new implicit sync write **Description** This returns the implicit synchronization usage for write or read accesses, see enum dma_resv_usage and :c:type:`dma_buf.resv `.h](h)}(h**Parameters**h]jr )}(hjzh]h Parameters}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjxubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhK|hjtubj )}(hhh]j )}(h;``bool write`` true if we create a new implicit sync write h](j )}(h``bool write``h]j)}(hjh]h bool write}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKyhjubj )}(hhh]h)}(h+true if we create a new implicit sync writeh]h+true if we create a new implicit sync write}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKyhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKyhjubah}(h]h ]h"]h$]h&]uh1j hjtubh)}(h**Description**h]jr )}(hjԍh]h Description}(hj֍hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjҍubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhK{hjtubh)}(hThis returns the implicit synchronization usage for write or read accesses, see enum dma_resv_usage and :c:type:`dma_buf.resv `.h](hhThis returns the implicit synchronization usage for write or read accesses, see enum dma_resv_usage and }(hjhhhNhNubh)}(h :c:type:`dma_buf.resv `h]j)}(hjh]h dma_buf.resv}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_bufuh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKzhjubh.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKzhjtubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv (C struct) c.dma_resvhNtauh1jhjbhhhNhNubj)}(hhh](j)}(hdma_resvh]j)}(hstruct dma_resvh](j)}(hjh]hstruct}(hj<hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj8hhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKubj)}(h h]h }(hjJhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj8hhhjIhKubj )}(hdma_resvh]j )}(hj6h]hdma_resv}(hj\hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjXubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj8hhhjIhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj4hhhjIhKubah}(h]j/ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjIhKhj1hhubjA )}(hhh]h)}(h0a reservation object manages fences for a bufferh]h0a reservation object manages fences for a buffer}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhj{hhubah}(h]h ]h"]h$]h&]uh1j@ hj1hhhjIhKubeh}(h]h ](jstructeh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(hX**Definition**:: struct dma_resv { struct ww_mutex lock; struct dma_resv_list *fences; }; **Members** ``lock`` Update side lock. Don't use directly, instead use the wrapper functions like dma_resv_lock() and dma_resv_unlock(). Drivers which use the reservation object to manage memory dynamically also use this lock to protect buffer object state like placement, allocation policies or throughout command submission. ``fences`` Array of fences which where added to the dma_resv object A new fence is added by calling dma_resv_add_fence(). Since this often needs to be done past the point of no return in command submission it cannot fail, and therefore sufficient slots need to be reserved by calling dma_resv_reserve_fences().h](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubj)}(hPstruct dma_resv { struct ww_mutex lock; struct dma_resv_list *fences; };h]hPstruct dma_resv { struct ww_mutex lock; struct dma_resv_list *fences; };}hjsbah}(h]h ]h"]h$]h&]jjuh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubh)}(h **Members**h]jr )}(hj̎h]hMembers}(hjΎhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjʎubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubj )}(hhh](j )}(hX<``lock`` Update side lock. Don't use directly, instead use the wrapper functions like dma_resv_lock() and dma_resv_unlock(). Drivers which use the reservation object to manage memory dynamically also use this lock to protect buffer object state like placement, allocation policies or throughout command submission. h](j )}(h``lock``h]j)}(hjh]hlock}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubj )}(hhh](h)}(hsUpdate side lock. Don't use directly, instead use the wrapper functions like dma_resv_lock() and dma_resv_unlock().h]huUpdate side lock. Don’t use directly, instead use the wrapper functions like dma_resv_lock() and dma_resv_unlock().}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubh)}(hDrivers which use the reservation object to manage memory dynamically also use this lock to protect buffer object state like placement, allocation policies or throughout command submission.h]hDrivers which use the reservation object to manage memory dynamically also use this lock to protect buffer object state like placement, allocation policies or throughout command submission.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubj )}(hX7``fences`` Array of fences which where added to the dma_resv object A new fence is added by calling dma_resv_add_fence(). Since this often needs to be done past the point of no return in command submission it cannot fail, and therefore sufficient slots need to be reserved by calling dma_resv_reserve_fences().h](j )}(h ``fences``h]j)}(hj4h]hfences}(hj6hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj2ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhj.ubj )}(hhh](h)}(h8Array of fences which where added to the dma_resv objecth]h8Array of fences which where added to the dma_resv object}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjJubh)}(hA new fence is added by calling dma_resv_add_fence(). Since this often needs to be done past the point of no return in command submission it cannot fail, and therefore sufficient slots need to be reserved by calling dma_resv_reserve_fences().h]hA new fence is added by calling dma_resv_add_fence(). Since this often needs to be done past the point of no return in command submission it cannot fail, and therefore sufficient slots need to be reserved by calling dma_resv_reserve_fences().}(hj\hhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjJubeh}(h]h ]h"]h$]h&]uh1j hj.ubeh}(h]h ]h"]h$]h&]uh1j hjIhKhjubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjbhhubh)}(hSThis is a container for dma_fence objects which needs to handle multiple use cases.h]hSThis is a container for dma_fence objects which needs to handle multiple use cases.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjbhhubh)}(hX One use is to synchronize cross-driver access to a struct dma_buf, either for dynamic buffer management or just to handle implicit synchronization between different users of the buffer in userspace. See :c:type:`dma_buf.resv ` for a more in-depth discussion.h](hOne use is to synchronize cross-driver access to a struct dma_buf, either for dynamic buffer management or just to handle implicit synchronization between different users of the buffer in userspace. See }(hjhhhNhNubh)}(h :c:type:`dma_buf.resv `h]j)}(hjh]h dma_buf.resv}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_bufuh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubh for a more in-depth discussion.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjҏhKhjbhhubh)}(hX?The other major use is to manage access and locking within a driver in a buffer based memory manager. struct ttm_buffer_object is the canonical example here, since this is where reservation objects originated from. But use in drivers is spreading and some drivers also manage struct drm_gem_object with the same scheme.h]hX?The other major use is to manage access and locking within a driver in a buffer based memory manager. struct ttm_buffer_object is the canonical example here, since this is where reservation objects originated from. But use in drivers is spreading and some drivers also manage struct drm_gem_object with the same scheme.}(hjݏhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjbhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_iter (C struct)c.dma_resv_iterhNtauh1jhjbhhhNhNubj)}(hhh](j)}(h dma_resv_iterh]j)}(hstruct dma_resv_iterh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhKubj )}(h dma_resv_iterh]j )}(hjh]h dma_resv_iter}(hj%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj!ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhKubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhKhjhhubjA )}(hhh]h)}(h)current position into the dma_resv fencesh]h)current position into the dma_resv fences}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjDhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhKubeh}(h]h ](jstructeh"]h$]h&]ja jjb j_jc j_jd je jf uh1jhhhjbhNhNubjh )}(hX**Definition**:: struct dma_resv_iter { struct dma_resv *obj; enum dma_resv_usage usage; struct dma_fence *fence; enum dma_resv_usage fence_usage; unsigned int index; struct dma_resv_list *fences; unsigned int num_fences; bool is_restarted; }; **Members** ``obj`` The dma_resv object we iterate over ``usage`` Return fences with this usage or lower. ``fence`` the currently handled fence ``fence_usage`` the usage of the current fence ``index`` index into the shared fences ``fences`` the shared fences; private, *MUST* not dereference ``num_fences`` number of fences ``is_restarted`` true if this is the first returned fenceh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjgubh:}(hjghhhNhNubeh}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjcubj)}(hXstruct dma_resv_iter { struct dma_resv *obj; enum dma_resv_usage usage; struct dma_fence *fence; enum dma_resv_usage fence_usage; unsigned int index; struct dma_resv_list *fences; unsigned int num_fences; bool is_restarted; };h]hXstruct dma_resv_iter { struct dma_resv *obj; enum dma_resv_usage usage; struct dma_fence *fence; enum dma_resv_usage fence_usage; unsigned int index; struct dma_resv_list *fences; unsigned int num_fences; bool is_restarted; };}hjsbah}(h]h ]h"]h$]h&]jjuh1jh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjcubh)}(h **Members**h]jr )}(hjh]hMembers}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjcubj )}(hhh](j )}(h,``obj`` The dma_resv object we iterate over h](j )}(h``obj``h]j)}(hjh]hobj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubj )}(hhh]h)}(h#The dma_resv object we iterate overh]h#The dma_resv object we iterate over}(hj͐hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjɐhKhjʐubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjɐhKhjubj )}(h2``usage`` Return fences with this usage or lower. h](j )}(h ``usage``h]j)}(hjh]husage}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubj )}(hhh]h)}(h'Return fences with this usage or lower.h]h'Return fences with this usage or lower.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubj )}(h&``fence`` the currently handled fence h](j )}(h ``fence``h]j)}(hj&h]hfence}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj$ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhj ubj )}(hhh]h)}(hthe currently handled fenceh]hthe currently handled fence}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj;hKhj<ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj;hKhjubj )}(h/``fence_usage`` the usage of the current fence h](j )}(h``fence_usage``h]j)}(hj_h]h fence_usage}(hjahhhNhNubah}(h]h ]h"]h$]h&]uh1jhj]ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjYubj )}(hhh]h)}(hthe usage of the current fenceh]hthe usage of the current fence}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjthKhjuubah}(h]h ]h"]h$]h&]uh1j hjYubeh}(h]h ]h"]h$]h&]uh1j hjthKhjubj )}(h'``index`` index into the shared fences h](j )}(h ``index``h]j)}(hjh]hindex}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubj )}(hhh]h)}(hindex into the shared fencesh]hindex into the shared fences}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubj )}(h>``fences`` the shared fences; private, *MUST* not dereference h](j )}(h ``fences``h]j)}(hjёh]hfences}(hjӑhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjϑubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjˑubj )}(hhh]h)}(h2the shared fences; private, *MUST* not dereferenceh](hthe shared fences; private, }(hjhhhNhNubj )}(h*MUST*h]hMUST}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j hjubh not dereference}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j hjˑubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubj )}(h ``num_fences`` number of fences h](j )}(h``num_fences``h]j)}(hjh]h num_fences}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubj )}(hhh]h)}(hnumber of fencesh]hnumber of fences}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj1hKhj2ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj1hKhjubj )}(h9``is_restarted`` true if this is the first returned fenceh](j )}(h``is_restarted``h]j)}(hjUh]h is_restarted}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjSubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjOubj )}(hhh]h)}(h(true if this is the first returned fenceh]h(true if this is the first returned fence}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjkubah}(h]h ]h"]h$]h&]uh1j hjOubeh}(h]h ]h"]h$]h&]uh1j hjjhKhjubeh}(h]h ]h"]h$]h&]uh1j hjcubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjbhhubh)}(hKDon't touch this directly in the driver, use the accessor function instead.h]hMDon’t touch this directly in the driver, use the accessor function instead.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjbhhubh)}(h IMPORTANTh]h IMPORTANT}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjbhhubh)}(hWhen using the lockless iterators like dma_resv_iter_next_unlocked() or dma_resv_for_each_fence_unlocked() beware that the iterator can be restarted. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted().h]hWhen using the lockless iterators like dma_resv_iter_next_unlocked() or dma_resv_for_each_fence_unlocked() beware that the iterator can be restarted. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted().}(hj̒hhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjbhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j dma_resv_iter_begin (C function)c.dma_resv_iter_beginhNtauh1jhjbhhhNhNubj)}(hhh](j)}(hhvoid dma_resv_iter_begin (struct dma_resv_iter *cursor, struct dma_resv *obj, enum dma_resv_usage usage)h]j)}(hgvoid dma_resv_iter_begin(struct dma_resv_iter *cursor, struct dma_resv *obj, enum dma_resv_usage usage)h](jM)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhKubj )}(hdma_resv_iter_beginh]j )}(hdma_resv_iter_beginh]hdma_resv_iter_begin}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhKubj)}(hO(struct dma_resv_iter *cursor, struct dma_resv *obj, enum dma_resv_usage usage)h](j)}(hstruct dma_resv_iter *cursorh](j)}(hjh]hstruct}(hj1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj-ubj)}(h h]h }(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj-ubh)}(hhh]j )}(h dma_resv_iterh]h dma_resv_iter}(hjOhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjLubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjQmodnameN classnameNjj)}j]jO)}jGjsbc.dma_resv_iter_beginasbuh1hhj-ubj)}(h h]h }(hjohhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj-ubjd)}(hjgh]h*}(hj}hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj-ubj )}(hcursorh]hcursor}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj-ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj)ubj)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjÓmodnameN classnameNjj)}j]jkc.dma_resv_iter_beginasbuh1hhjubj)}(h h]h }(hjߓhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hobjh]hobj}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj)ubj)}(henum dma_resv_usage usageh](j)}(hj+h]henum}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_resv_usageh]hdma_resv_usage}(hj1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj.ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj3modnameN classnameNjj)}j]jkc.dma_resv_iter_beginasbuh1hhjubj)}(h h]h }(hjOhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(husageh]husage}(hj]hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj)ubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhKubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhKhjhhubjA )}(hhh]h)}(h!initialize a dma_resv_iter objecth]h!initialize a dma_resv_iter object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv_iter *cursor`` The dma_resv_iter object to initialize ``struct dma_resv *obj`` The dma_resv object which we want to iterate over ``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubj )}(hhh](j )}(hH``struct dma_resv_iter *cursor`` The dma_resv_iter object to initialize h](j )}(h ``struct dma_resv_iter *cursor``h]j)}(hjȔh]hstruct dma_resv_iter *cursor}(hjʔhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjƔubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhj”ubj )}(hhh]h)}(h&The dma_resv_iter object to initializeh]h&The dma_resv_iter object to initialize}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjݔhKhjޔubah}(h]h ]h"]h$]h&]uh1j hj”ubeh}(h]h ]h"]h$]h&]uh1j hjݔhKhjubj )}(hK``struct dma_resv *obj`` The dma_resv object which we want to iterate over h](j )}(h``struct dma_resv *obj``h]j)}(hjh]hstruct dma_resv *obj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubj )}(hhh]h)}(h1The dma_resv object which we want to iterate overh]h1The dma_resv object which we want to iterate over}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubj )}(hX``enum dma_resv_usage usage`` controls which fences to include, see enum dma_resv_usage.h](j )}(h``enum dma_resv_usage usage``h]j)}(hj:h]henum dma_resv_usage usage}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj8ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhj4ubj )}(hhh]h)}(h:controls which fences to include, see enum dma_resv_usage.h]h:controls which fences to include, see enum dma_resv_usage.}(hjShhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjPubah}(h]h ]h"]h$]h&]uh1j hj4ubeh}(h]h ]h"]h$]h&]uh1j hjOhKhjubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_iter_end (C function)c.dma_resv_iter_endhNtauh1jhjbhhhNhNubj)}(hhh](j)}(h5void dma_resv_iter_end (struct dma_resv_iter *cursor)h]j)}(h4void dma_resv_iter_end(struct dma_resv_iter *cursor)h](jM)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhKubj )}(hdma_resv_iter_endh]j )}(hdma_resv_iter_endh]hdma_resv_iter_end}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhKubj)}(h(struct dma_resv_iter *cursor)h]j)}(hstruct dma_resv_iter *cursorh](j)}(hjh]hstruct}(hjѕhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj͕ubj)}(h h]h }(hjޕhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj͕ubh)}(hhh]j )}(h dma_resv_iterh]h dma_resv_iter}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsbc.dma_resv_iter_endasbuh1hhj͕ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj͕ubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj͕ubj )}(hcursorh]hcursor}(hj*hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj͕ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjɕubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhKubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhKhjhhubjA )}(hhh]h)}(hcleanup a dma_resv_iter objecth]hcleanup a dma_resv_iter object}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjQhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jljc jljd je jf uh1jhhhjbhNhNubjh )}(h**Parameters** ``struct dma_resv_iter *cursor`` the dma_resv_iter object which should be cleaned up **Description** Make sure that the reference to the fence in the cursor is properly dropped.h](h)}(h**Parameters**h]jr )}(hjvh]h Parameters}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjtubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjpubj )}(hhh]j )}(hU``struct dma_resv_iter *cursor`` the dma_resv_iter object which should be cleaned up h](j )}(h ``struct dma_resv_iter *cursor``h]j)}(hjh]hstruct dma_resv_iter *cursor}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubj )}(hhh]h)}(h3the dma_resv_iter object which should be cleaned uph]h3the dma_resv_iter object which should be cleaned up}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubah}(h]h ]h"]h$]h&]uh1j hjpubh)}(h**Description**h]jr )}(hjЖh]h Description}(hjҖhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjΖubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjpubh)}(hLMake sure that the reference to the fence in the cursor is properly dropped.h]hLMake sure that the reference to the fence in the cursor is properly dropped.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjpubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j dma_resv_iter_usage (C function)c.dma_resv_iter_usagehNtauh1jhjbhhhNhNubj)}(hhh](j)}(hFenum dma_resv_usage dma_resv_iter_usage (struct dma_resv_iter *cursor)h]j)}(hEenum dma_resv_usage dma_resv_iter_usage(struct dma_resv_iter *cursor)h](j)}(hj+h]henum}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKubj)}(h h]h }(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhj"hKubh)}(hhh]j )}(hdma_resv_usageh]hdma_resv_usage}(hj4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj1ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj6modnameN classnameNjj)}j]jO)}jGdma_resv_iter_usagesbc.dma_resv_iter_usageasbuh1hhjhhhj"hKubj)}(h h]h }(hjUhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhj"hKubj )}(hdma_resv_iter_usageh]j )}(hjRh]hdma_resv_iter_usage}(hjghhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjcubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhj"hKubj)}(h(struct dma_resv_iter *cursor)h]j)}(hstruct dma_resv_iter *cursorh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj~ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj~ubh)}(hhh]j )}(h dma_resv_iterh]h dma_resv_iter}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jPc.dma_resv_iter_usageasbuh1hhj~ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj~ubjd)}(hjgh]h*}(hj̗hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj~ubj )}(hcursorh]hcursor}(hjٗhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj~ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjzubah}(h]h ]h"]h$]h&]jjuh1jhjhhhj"hKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj hhhj"hKubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj"hKhj hhubjA )}(hhh]h)}(h%Return the usage of the current fenceh]h%Return the usage of the current fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjhhubah}(h]h ]h"]h$]h&]uh1j@ hj hhhj"hKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(h**Parameters** ``struct dma_resv_iter *cursor`` the cursor of the current position **Description** Returns the usage of the currently processed fence.h](h)}(h**Parameters**h]jr )}(hj%h]h Parameters}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj#ubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubj )}(hhh]j )}(hD``struct dma_resv_iter *cursor`` the cursor of the current position h](j )}(h ``struct dma_resv_iter *cursor``h]j)}(hjDh]hstruct dma_resv_iter *cursor}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjBubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhj>ubj )}(hhh]h)}(h"the cursor of the current positionh]h"the cursor of the current position}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjYhKhjZubah}(h]h ]h"]h$]h&]uh1j hj>ubeh}(h]h ]h"]h$]h&]uh1j hjYhKhj;ubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj}ubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubh)}(h3Returns the usage of the currently processed fence.h]h3Returns the usage of the currently processed fence.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhKhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j'dma_resv_iter_is_restarted (C function)c.dma_resv_iter_is_restartedhNtauh1jhjbhhhNhNubj)}(hhh](j)}(h>bool dma_resv_iter_is_restarted (struct dma_resv_iter *cursor)h]j)}(h=bool dma_resv_iter_is_restarted(struct dma_resv_iter *cursor)h](jM)}(hji5h]hbool}(hjĘhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMubj)}(h h]h }(hjҘhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjјhMubj )}(hdma_resv_iter_is_restartedh]j )}(hdma_resv_iter_is_restartedh]hdma_resv_iter_is_restarted}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjјhMubj)}(h(struct dma_resv_iter *cursor)h]j)}(hstruct dma_resv_iter *cursorh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_resv_iterh]h dma_resv_iter}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]jO)}jGjsbc.dma_resv_iter_is_restartedasbuh1hhjubj)}(h h]h }(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjLhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hcursorh]hcursor}(hjYhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjјhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjјhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjјhMhjhhubjA )}(hhh]h)}(h/test if this is the first fence after a restarth]h/test if this is the first fence after a restart}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjјhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(h**Parameters** ``struct dma_resv_iter *cursor`` the cursor with the current position **Description** Return true if this is the first fence in an iteration after a restart.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM hjubj )}(hhh]j )}(hF``struct dma_resv_iter *cursor`` the cursor with the current position h](j )}(h ``struct dma_resv_iter *cursor``h]j)}(hjęh]hstruct dma_resv_iter *cursor}(hjƙhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj™ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM hjubj )}(hhh]h)}(h$the cursor with the current positionh]h$the cursor with the current position}(hjݙhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjٙhM hjڙubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjٙhM hjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM hjubh)}(hGReturn true if this is the first fence in an iteration after a restart.h]hGReturn true if this is the first fence in an iteration after a restart.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j*dma_resv_for_each_fence_unlocked (C macro)"c.dma_resv_for_each_fence_unlockedhNtauh1jhjbhhhNhNubj)}(hhh](j)}(h dma_resv_for_each_fence_unlockedh]j)}(h dma_resv_for_each_fence_unlockedh]j )}(h dma_resv_for_each_fence_unlockedh]j )}(hj>h]h dma_resv_for_each_fence_unlocked}(hjHhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjDubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj@hhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMubah}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj<hhhj[hMubah}(h]j7ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj[hMhj9hhubjA )}(hhh]h}(h]h ]h"]h$]h&]uh1j@ hj9hhhj[hMubeh}(h]h ](jmacroeh"]h$]h&]ja jjb jtjc jtjd je jf uh1jhhhjbhNhNubh)}(h4``dma_resv_for_each_fence_unlocked (cursor, fence)``h]j)}(hjzh]h0dma_resv_for_each_fence_unlocked (cursor, fence)}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjxubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjbhhubh)}(hunlocked fence iterator h]h)}(hunlocked fence iteratorh]hunlocked fence iterator}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjbhhubjh )}(hX**Parameters** ``cursor`` a struct dma_resv_iter pointer ``fence`` the current fence **Description** Iterate over the fences in a struct dma_resv object without holding the :c:type:`dma_resv.lock ` and using RCU instead. The cursor needs to be initialized with dma_resv_iter_begin() and cleaned up with dma_resv_iter_end(). Inside the iterator a reference to the dma_fence is held and the RCU lock dropped. Beware that the iterator can be restarted when the struct dma_resv for **cursor** is modified. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted(). For this reason prefer the lock iterator dma_resv_for_each_fence() whenever possible.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubj )}(hhh](j )}(h*``cursor`` a struct dma_resv_iter pointer h](j )}(h ``cursor``h]j)}(hjΚh]hcursor}(hjКhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj̚ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjȚubj )}(hhh]h)}(ha struct dma_resv_iter pointerh]ha struct dma_resv_iter pointer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjȚubeh}(h]h ]h"]h$]h&]uh1j hjhMhjŚubj )}(h``fence`` the current fence h](j )}(h ``fence``h]j)}(hjh]hfence}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubj )}(hhh]h)}(hthe current fenceh]hthe current fence}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjŚubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjBh]h Description}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj@ubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubh)}(hX;Iterate over the fences in a struct dma_resv object without holding the :c:type:`dma_resv.lock ` and using RCU instead. The cursor needs to be initialized with dma_resv_iter_begin() and cleaned up with dma_resv_iter_end(). Inside the iterator a reference to the dma_fence is held and the RCU lock dropped.h](hHIterate over the fences in a struct dma_resv object without holding the }(hjXhhhNhNubh)}(h":c:type:`dma_resv.lock `h]j)}(hjbh]h dma_resv.lock}(hjdhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj`ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_resvuh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjXubh and using RCU instead. The cursor needs to be initialized with dma_resv_iter_begin() and cleaned up with dma_resv_iter_end(). Inside the iterator a reference to the dma_fence is held and the RCU lock dropped.}(hjXhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMhjubh)}(hXBeware that the iterator can be restarted when the struct dma_resv for **cursor** is modified. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted(). For this reason prefer the lock iterator dma_resv_for_each_fence() whenever possible.h](hGBeware that the iterator can be restarted when the struct dma_resv for }(hjhhhNhNubjr )}(h **cursor**h]hcursor}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh is modified. Code which accumulates statistics or similar needs to check for this with dma_resv_iter_is_restarted(). For this reason prefer the lock iterator dma_resv_for_each_fence() whenever possible.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j!dma_resv_for_each_fence (C macro)c.dma_resv_for_each_fencehNtauh1jhjbhhhNhNubj)}(hhh](j)}(hdma_resv_for_each_fenceh]j)}(hdma_resv_for_each_fenceh]j )}(hdma_resv_for_each_fenceh]j )}(hjśh]hdma_resv_for_each_fence}(hjϛhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj˛ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjǛhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM&ubah}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjÛhhhjhM&ubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhM&hjhhubjA )}(hhh]h}(h]h ]h"]h$]h&]uh1j@ hjhhhjhM&ubeh}(h]h ](jmacroeh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubh)}(h7``dma_resv_for_each_fence (cursor, obj, usage, fence)``h]j)}(hjh]h3dma_resv_for_each_fence (cursor, obj, usage, fence)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM(hjbhhubh)}(hfence iterator h]h)}(hfence iteratorh]hfence iterator}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM&hjubah}(h]h ]h"]h$]h&]uh1hhj)hM&hjbhhubjh )}(hX**Parameters** ``cursor`` a struct dma_resv_iter pointer ``obj`` a dma_resv object pointer ``usage`` controls which fences to return ``fence`` the current fence **Description** Iterate over the fences in a struct dma_resv object while holding the :c:type:`dma_resv.lock `. **all_fences** controls if the shared fences are returned as well. The cursor initialisation is part of the iterator and the fence stays valid as long as the lock is held and so no extra reference to the fence is taken.h](h)}(h**Parameters**h]jr )}(hj6h]h Parameters}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj4ubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM*hj0ubj )}(hhh](j )}(h*``cursor`` a struct dma_resv_iter pointer h](j )}(h ``cursor``h]j)}(hjUh]hcursor}(hjWhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjSubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM'hjOubj )}(hhh]h)}(ha struct dma_resv_iter pointerh]ha struct dma_resv_iter pointer}(hjnhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjjhM'hjkubah}(h]h ]h"]h$]h&]uh1j hjOubeh}(h]h ]h"]h$]h&]uh1j hjjhM'hjLubj )}(h"``obj`` a dma_resv object pointer h](j )}(h``obj``h]j)}(hjh]hobj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM(hjubj )}(hhh]h)}(ha dma_resv object pointerh]ha dma_resv object pointer}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM(hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhM(hjLubj )}(h*``usage`` controls which fences to return h](j )}(h ``usage``h]j)}(hjǜh]husage}(hjɜhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjŜubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM)hjubj )}(hhh]h)}(hcontrols which fences to returnh]hcontrols which fences to return}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjܜhM)hjݜubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjܜhM)hjLubj )}(h``fence`` the current fence h](j )}(h ``fence``h]j)}(hjh]hfence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM*hjubj )}(hhh]h)}(hthe current fenceh]hthe current fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM*hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhM*hjLubeh}(h]h ]h"]h$]h&]uh1j hj0ubh)}(h**Description**h]jr )}(hj;h]h Description}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj9ubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM,hj0ubh)}(hXEIterate over the fences in a struct dma_resv object while holding the :c:type:`dma_resv.lock `. **all_fences** controls if the shared fences are returned as well. The cursor initialisation is part of the iterator and the fence stays valid as long as the lock is held and so no extra reference to the fence is taken.h](hFIterate over the fences in a struct dma_resv object while holding the }(hjQhhhNhNubh)}(h":c:type:`dma_resv.lock `h]j)}(hj[h]h dma_resv.lock}(hj]hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjYubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_resvuh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM+hjQubh. }(hjQhhhNhNubjr )}(h**all_fences**h]h all_fences}(hj}hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjQubh controls if the shared fences are returned as well. The cursor initialisation is part of the iterator and the fence stays valid as long as the lock is held and so no extra reference to the fence is taken.}(hjQhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjxhM+hj0ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_lock (C function)c.dma_resv_lockhNtauh1jhjbhhhNhNubj)}(hhh](j)}(hDint dma_resv_lock (struct dma_resv *obj, struct ww_acquire_ctx *ctx)h]j)}(hCint dma_resv_lock(struct dma_resv *obj, struct ww_acquire_ctx *ctx)h](jM)}(hinth]hint}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMAubj)}(h h]h }(hjĝhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjÝhMAubj )}(h dma_resv_lockh]j )}(h dma_resv_lockh]h dma_resv_lock}(hj֝hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjҝubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjÝhMAubj)}(h2(struct dma_resv *obj, struct ww_acquire_ctx *ctx)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGj؝sbc.dma_resv_lockasbuh1hhjubj)}(h h]h }(hj0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj>hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hobjh]hobj}(hjKhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hstruct ww_acquire_ctx *ctxh](j)}(hjh]hstruct}(hjdhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj`ubj)}(h h]h }(hjqhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj`ubh)}(hhh]j )}(hww_acquire_ctxh]hww_acquire_ctx}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]j,c.dma_resv_lockasbuh1hhj`ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj`ubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj`ubj )}(hctxh]hctx}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj`ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjÝhMAubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjÝhMAubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjÝhMAhjhhubjA )}(hhh]h)}(hlock the reservation objecth]hlock the reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMAhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjÝhMAubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv *obj`` the reservation object ``struct ww_acquire_ctx *ctx`` the locking context **Description** Locks the reservation object for exclusive access and modification. Note, that the lock is only against other writers, readers will run concurrently with a writer under RCU. The seqlock is used to notify readers if they overlap with a writer. As the reservation object may be locked by multiple parties in an undefined order, a #ww_acquire_ctx is passed to unwind if a cycle is detected. See ww_mutex_lock() and ww_acquire_init(). A reservation object may be locked by itself by passing NULL as **ctx**. When a die situation is indicated by returning -EDEADLK all locks held by **ctx** must be unlocked and then dma_resv_lock_slow() called on **obj**. Unlocked by calling dma_resv_unlock(). See also dma_resv_lock_interruptible() for the interruptible variant.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMEhjubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hj&h]hstruct dma_resv *obj}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj$ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMBhj ubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj;hMBhj<ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj;hMBhjubj )}(h3``struct ww_acquire_ctx *ctx`` the locking context h](j )}(h``struct ww_acquire_ctx *ctx``h]j)}(hj_h]hstruct ww_acquire_ctx *ctx}(hjahhhNhNubah}(h]h ]h"]h$]h&]uh1jhj]ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMChjYubj )}(hhh]h)}(hthe locking contexth]hthe locking context}(hjxhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjthMChjuubah}(h]h ]h"]h$]h&]uh1j hjYubeh}(h]h ]h"]h$]h&]uh1j hjthMChjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMEhjubh)}(hLocks the reservation object for exclusive access and modification. Note, that the lock is only against other writers, readers will run concurrently with a writer under RCU. The seqlock is used to notify readers if they overlap with a writer.h]hLocks the reservation object for exclusive access and modification. Note, that the lock is only against other writers, readers will run concurrently with a writer under RCU. The seqlock is used to notify readers if they overlap with a writer.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMDhjubh)}(hXAs the reservation object may be locked by multiple parties in an undefined order, a #ww_acquire_ctx is passed to unwind if a cycle is detected. See ww_mutex_lock() and ww_acquire_init(). A reservation object may be locked by itself by passing NULL as **ctx**.h](hAs the reservation object may be locked by multiple parties in an undefined order, a #ww_acquire_ctx is passed to unwind if a cycle is detected. See ww_mutex_lock() and ww_acquire_init(). A reservation object may be locked by itself by passing NULL as }(hjhhhNhNubjr )}(h**ctx**h]hctx}(hjǟhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMIhjubh)}(hWhen a die situation is indicated by returning -EDEADLK all locks held by **ctx** must be unlocked and then dma_resv_lock_slow() called on **obj**.h](hJWhen a die situation is indicated by returning -EDEADLK all locks held by }(hjhhhNhNubjr )}(h**ctx**h]hctx}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh: must be unlocked and then dma_resv_lock_slow() called on }(hjhhhNhNubjr )}(h**obj**h]hobj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMNhjubh)}(h&Unlocked by calling dma_resv_unlock().h]h&Unlocked by calling dma_resv_unlock().}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMQhjubh)}(hESee also dma_resv_lock_interruptible() for the interruptible variant.h]hESee also dma_resv_lock_interruptible() for the interruptible variant.}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMShjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j(dma_resv_lock_interruptible (C function)c.dma_resv_lock_interruptiblehNtauh1jhjbhhhNhNubj)}(hhh](j)}(hRint dma_resv_lock_interruptible (struct dma_resv *obj, struct ww_acquire_ctx *ctx)h]j)}(hQint dma_resv_lock_interruptible(struct dma_resv *obj, struct ww_acquire_ctx *ctx)h](jM)}(hinth]hint}(hjQhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjMhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM]ubj)}(h h]h }(hj`hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjMhhhj_hM]ubj )}(hdma_resv_lock_interruptibleh]j )}(hdma_resv_lock_interruptibleh]hdma_resv_lock_interruptible}(hjrhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjnubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjMhhhj_hM]ubj)}(h2(struct dma_resv *obj, struct ww_acquire_ctx *ctx)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjtsbc.dma_resv_lock_interruptibleasbuh1hhjubj)}(h h]h }(hj̠hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjڠhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hobjh]hobj}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hstruct ww_acquire_ctx *ctxh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hww_acquire_ctxh]hww_acquire_ctx}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]jȠc.dma_resv_lock_interruptibleasbuh1hhjubj)}(h h]h }(hj<hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjJhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hctxh]hctx}(hjWhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjMhhhj_hM]ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjIhhhj_hM]ubah}(h]jDah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj_hM]hjFhhubjA )}(hhh]h)}(hlock the reservation objecth]hlock the reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM]hj~hhubah}(h]h ]h"]h$]h&]uh1j@ hjFhhhj_hM]ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(hX[**Parameters** ``struct dma_resv *obj`` the reservation object ``struct ww_acquire_ctx *ctx`` the locking context **Description** Locks the reservation object interruptible for exclusive access and modification. Note, that the lock is only against other writers, readers will run concurrently with a writer under RCU. The seqlock is used to notify readers if they overlap with a writer. As the reservation object may be locked by multiple parties in an undefined order, a #ww_acquire_ctx is passed to unwind if a cycle is detected. See ww_mutex_lock() and ww_acquire_init(). A reservation object may be locked by itself by passing NULL as **ctx**. When a die situation is indicated by returning -EDEADLK all locks held by **ctx** must be unlocked and then dma_resv_lock_slow_interruptible() called on **obj**. Unlocked by calling dma_resv_unlock().h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMahjubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hj¡h]hstruct dma_resv *obj}(hjġhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM^hjubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjۡhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjסhM^hjءubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjסhM^hjubj )}(h3``struct ww_acquire_ctx *ctx`` the locking context h](j )}(h``struct ww_acquire_ctx *ctx``h]j)}(hjh]hstruct ww_acquire_ctx *ctx}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM_hjubj )}(hhh]h)}(hthe locking contexth]hthe locking context}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM_hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhM_hjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj6h]h Description}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj4ubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMahjubh)}(hXLocks the reservation object interruptible for exclusive access and modification. Note, that the lock is only against other writers, readers will run concurrently with a writer under RCU. The seqlock is used to notify readers if they overlap with a writer.h]hXLocks the reservation object interruptible for exclusive access and modification. Note, that the lock is only against other writers, readers will run concurrently with a writer under RCU. The seqlock is used to notify readers if they overlap with a writer.}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM`hjubh)}(hXAs the reservation object may be locked by multiple parties in an undefined order, a #ww_acquire_ctx is passed to unwind if a cycle is detected. See ww_mutex_lock() and ww_acquire_init(). A reservation object may be locked by itself by passing NULL as **ctx**.h](hAs the reservation object may be locked by multiple parties in an undefined order, a #ww_acquire_ctx is passed to unwind if a cycle is detected. See ww_mutex_lock() and ww_acquire_init(). A reservation object may be locked by itself by passing NULL as }(hj[hhhNhNubjr )}(h**ctx**h]hctx}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj[ubh.}(hj[hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMehjubh)}(hWhen a die situation is indicated by returning -EDEADLK all locks held by **ctx** must be unlocked and then dma_resv_lock_slow_interruptible() called on **obj**.h](hJWhen a die situation is indicated by returning -EDEADLK all locks held by }(hj|hhhNhNubjr )}(h**ctx**h]hctx}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj|ubhH must be unlocked and then dma_resv_lock_slow_interruptible() called on }(hj|hhhNhNubjr )}(h**obj**h]hobj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj|ubh.}(hj|hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMjhjubh)}(h&Unlocked by calling dma_resv_unlock().h]h&Unlocked by calling dma_resv_unlock().}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMnhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_lock_slow (C function)c.dma_resv_lock_slowhNtauh1jhjbhhhNhNubj)}(hhh](j)}(hJvoid dma_resv_lock_slow (struct dma_resv *obj, struct ww_acquire_ctx *ctx)h]j)}(hIvoid dma_resv_lock_slow(struct dma_resv *obj, struct ww_acquire_ctx *ctx)h](jM)}(hvoidh]hvoid}(hjޢhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjڢhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMxubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjڢhhhjhMxubj )}(hdma_resv_lock_slowh]j )}(hdma_resv_lock_slowh]hdma_resv_lock_slow}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjڢhhhjhMxubj)}(h2(struct dma_resv *obj, struct ww_acquire_ctx *ctx)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj(hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj6ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj;modnameN classnameNjj)}j]jO)}jGjsbc.dma_resv_lock_slowasbuh1hhjubj)}(h h]h }(hjYhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjghhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hobjh]hobj}(hjthhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hstruct ww_acquire_ctx *ctxh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hww_acquire_ctxh]hww_acquire_ctx}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jUc.dma_resv_lock_slowasbuh1hhjubj)}(h h]h }(hjɣhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjףhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hctxh]hctx}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjڢhhhjhMxubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj֢hhhjhMxubah}(h]jѢah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMxhjӢhhubjA )}(hhh]h)}(h$slowpath lock the reservation objecth]h$slowpath lock the reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMxhj hhubah}(h]h ]h"]h$]h&]uh1j@ hjӢhhhjhMxubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j&jc j&jd je jf uh1jhhhjbhNhNubjh )}(hX_**Parameters** ``struct dma_resv *obj`` the reservation object ``struct ww_acquire_ctx *ctx`` the locking context **Description** Acquires the reservation object after a die case. This function will sleep until the lock becomes available. See dma_resv_lock() as well. See also dma_resv_lock_slow_interruptible() for the interruptible variant.h](h)}(h**Parameters**h]jr )}(hj0h]h Parameters}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj.ubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM|hj*ubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjOh]hstruct dma_resv *obj}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjMubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMyhjIubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjhhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjdhMyhjeubah}(h]h ]h"]h$]h&]uh1j hjIubeh}(h]h ]h"]h$]h&]uh1j hjdhMyhjFubj )}(h3``struct ww_acquire_ctx *ctx`` the locking context h](j )}(h``struct ww_acquire_ctx *ctx``h]j)}(hjh]hstruct ww_acquire_ctx *ctx}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMzhjubj )}(hhh]h)}(hthe locking contexth]hthe locking context}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMzhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMzhjFubeh}(h]h ]h"]h$]h&]uh1j hj*ubh)}(h**Description**h]jr )}(hjäh]h Description}(hjŤhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM|hj*ubh)}(hAcquires the reservation object after a die case. This function will sleep until the lock becomes available. See dma_resv_lock() as well.h]hAcquires the reservation object after a die case. This function will sleep until the lock becomes available. See dma_resv_lock() as well.}(hj٤hhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhM{hj*ubh)}(hJSee also dma_resv_lock_slow_interruptible() for the interruptible variant.h]hJSee also dma_resv_lock_slow_interruptible() for the interruptible variant.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhj*ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j-dma_resv_lock_slow_interruptible (C function)"c.dma_resv_lock_slow_interruptiblehNtauh1jhjbhhhNhNubj)}(hhh](j)}(hWint dma_resv_lock_slow_interruptible (struct dma_resv *obj, struct ww_acquire_ctx *ctx)h]j)}(hVint dma_resv_lock_slow_interruptible(struct dma_resv *obj, struct ww_acquire_ctx *ctx)h](jM)}(hinth]hint}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMubj)}(h h]h }(hj&hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhj%hMubj )}(h dma_resv_lock_slow_interruptibleh]j )}(h dma_resv_lock_slow_interruptibleh]h dma_resv_lock_slow_interruptible}(hj8hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj4ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhj%hMubj)}(h2(struct dma_resv *obj, struct ww_acquire_ctx *ctx)h](j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjThhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjPubj)}(h h]h }(hjahhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjPubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjrhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjoubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjtmodnameN classnameNjj)}j]jO)}jGj:sb"c.dma_resv_lock_slow_interruptibleasbuh1hhjPubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjPubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjPubj )}(hobjh]hobj}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjPubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjLubj)}(hstruct ww_acquire_ctx *ctxh](j)}(hjh]hstruct}(hjƥhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj¥ubj)}(h h]h }(hjӥhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj¥ubh)}(hhh]j )}(hww_acquire_ctxh]hww_acquire_ctx}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]j"c.dma_resv_lock_slow_interruptibleasbuh1hhj¥ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj¥ubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj¥ubj )}(hctxh]hctx}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj¥ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjLubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhj%hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhj%hMubah}(h]j ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj%hMhj hhubjA )}(hhh]h)}(h3slowpath lock the reservation object, interruptibleh]h3slowpath lock the reservation object, interruptible}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjDhhubah}(h]h ]h"]h$]h&]uh1j@ hj hhhj%hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j_jc j_jd je jf uh1jhhhjbhNhNubjh )}(hX/**Parameters** ``struct dma_resv *obj`` the reservation object ``struct ww_acquire_ctx *ctx`` the locking context **Description** Acquires the reservation object interruptible after a die case. This function will sleep until the lock becomes available. See dma_resv_lock_interruptible() as well.h](h)}(h**Parameters**h]jr )}(hjih]h Parameters}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjgubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjcubj )}(hhh](j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjh]hstruct dma_resv *obj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubj )}(h3``struct ww_acquire_ctx *ctx`` the locking context h](j )}(h``struct ww_acquire_ctx *ctx``h]j)}(hjh]hstruct ww_acquire_ctx *ctx}(hjæhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubj )}(hhh]h)}(hthe locking contexth]hthe locking context}(hjڦhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj֦hMhjצubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj֦hMhjubeh}(h]h ]h"]h$]h&]uh1j hjcubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjcubh)}(hAcquires the reservation object interruptible after a die case. This function will sleep until the lock becomes available. See dma_resv_lock_interruptible() as well.h]hAcquires the reservation object interruptible after a die case. This function will sleep until the lock becomes available. See dma_resv_lock_interruptible() as well.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjcubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_trylock (C function)c.dma_resv_trylockhNtauh1jhjbhhhNhNubj)}(hhh](j)}(h,bool dma_resv_trylock (struct dma_resv *obj)h]j)}(h+bool dma_resv_trylock(struct dma_resv *obj)h](jM)}(hji5h]hbool}(hjAhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj=hhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMubj)}(h h]h }(hjOhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj=hhhjNhMubj )}(hdma_resv_trylockh]j )}(hdma_resv_trylockh]hdma_resv_trylock}(hjahhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj]ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj=hhhjNhMubj)}(h(struct dma_resv *obj)h]j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hj}hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjyubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjyubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjcsbc.dma_resv_trylockasbuh1hhjyubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjyubjd)}(hjgh]h*}(hjɧhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjyubj )}(hobjh]hobj}(hj֧hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjyubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjuubah}(h]h ]h"]h$]h&]jjuh1jhj=hhhjNhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj9hhhjNhMubah}(h]j4ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjNhMhj6hhubjA )}(hhh]h)}(htrylock the reservation objecth]htrylock the reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hj6hhhjNhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv *obj`` the reservation object **Description** Tries to lock the reservation object for exclusive access and modification. Note, that the lock is only against other writers, readers will run concurrently with a writer under RCU. The seqlock is used to notify readers if they overlap with a writer. Also note that since no context is provided, no deadlock protection is possible, which is also not needed for a trylock. Returns true if the lock was acquired, false otherwise.h](h)}(h**Parameters**h]jr )}(hj"h]h Parameters}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubj )}(hhh]j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjAh]hstruct dma_resv *obj}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1jhj?ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhj;ubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjZhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjVhMhjWubah}(h]h ]h"]h$]h&]uh1j hj;ubeh}(h]h ]h"]h$]h&]uh1j hjVhMhj8ubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj|h]h Description}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjzubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubh)}(hTries to lock the reservation object for exclusive access and modification. Note, that the lock is only against other writers, readers will run concurrently with a writer under RCU. The seqlock is used to notify readers if they overlap with a writer.h]hTries to lock the reservation object for exclusive access and modification. Note, that the lock is only against other writers, readers will run concurrently with a writer under RCU. The seqlock is used to notify readers if they overlap with a writer.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubh)}(hxAlso note that since no context is provided, no deadlock protection is possible, which is also not needed for a trylock.h]hxAlso note that since no context is provided, no deadlock protection is possible, which is also not needed for a trylock.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubh)}(h7Returns true if the lock was acquired, false otherwise.h]h7Returns true if the lock was acquired, false otherwise.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_is_locked (C function)c.dma_resv_is_lockedhNtauh1jhjbhhhNhNubj)}(hhh](j)}(h.bool dma_resv_is_locked (struct dma_resv *obj)h]j)}(h-bool dma_resv_is_locked(struct dma_resv *obj)h](jM)}(hji5h]hbool}(hjߨhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjۨhhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjۨhhhjhMubj )}(hdma_resv_is_lockedh]j )}(hdma_resv_is_lockedh]hdma_resv_is_locked}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjۨhhhjhMubj)}(h(struct dma_resv *obj)h]j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj(hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj6ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj;modnameN classnameNjj)}j]jO)}jGjsbc.dma_resv_is_lockedasbuh1hhjubj)}(h h]h }(hjYhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjghhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hobjh]hobj}(hjthhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjۨhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjרhhhjhMubah}(h]jҨah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjԨhhubjA )}(hhh]h)}(h is the reservation object lockedh]h is the reservation object locked}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjԨhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(h**Parameters** ``struct dma_resv *obj`` the reservation object **Description** Returns true if the mutex is locked, false if unlocked.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hj©hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubj )}(hhh]j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjߩh]hstruct dma_resv *obj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjݩubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhj٩ubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hj٩ubeh}(h]h ]h"]h$]h&]uh1j hjhMhj֩ubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubh)}(h7Returns true if the mutex is locked, false if unlocked.h]h7Returns true if the mutex is locked, false if unlocked.}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j!dma_resv_locking_ctx (C function)c.dma_resv_locking_ctxhNtauh1jhjbhhhNhNubj)}(hhh](j)}(hCstruct ww_acquire_ctx * dma_resv_locking_ctx (struct dma_resv *obj)h]j)}(hAstruct ww_acquire_ctx *dma_resv_locking_ctx(struct dma_resv *obj)h](j)}(hjh]hstruct}(hj_hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj[hhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMubj)}(h h]h }(hjmhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj[hhhjlhMubh)}(hhh]j )}(hww_acquire_ctxh]hww_acquire_ctx}(hj~hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj{ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGdma_resv_locking_ctxsbc.dma_resv_locking_ctxasbuh1hhj[hhhjlhMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj[hhhjlhMubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj[hhhjlhMubj )}(hdma_resv_locking_ctxh]j )}(hjh]hdma_resv_locking_ctx}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj[hhhjlhMubj)}(h(struct dma_resv *obj)h]j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hj٪hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjժubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjժubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_resv_locking_ctxasbuh1hhjժubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjժubjd)}(hjgh]h*}(hj#hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjժubj )}(hobjh]hobj}(hj0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjժubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjѪubah}(h]h ]h"]h$]h&]jjuh1jhj[hhhjlhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjWhhhjlhMubah}(h]jRah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjlhMhjThhubjA )}(hhh]h)}(h+returns the context used to lock the objecth]h+returns the context used to lock the object}(hjZhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjWhhubah}(h]h ]h"]h$]h&]uh1j@ hjThhhjlhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jrjc jrjd je jf uh1jhhhjbhNhNubjh )}(hX**Parameters** ``struct dma_resv *obj`` the reservation object **Description** Returns the context used to lock a reservation object or NULL if no context was used or the object is not locked at all. WARNING: This interface is pretty horrible, but TTM needs it because it doesn't pass the struct ww_acquire_ctx around in some very long callchains. Everyone else just uses it to check whether they're holding a reservation or not.h](h)}(h**Parameters**h]jr )}(hj|h]h Parameters}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjzubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjvubj )}(hhh]j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hjh]hstruct dma_resv *obj}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubah}(h]h ]h"]h$]h&]uh1j hjvubh)}(h**Description**h]jr )}(hj֫h]h Description}(hjثhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjԫubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjvubh)}(hxReturns the context used to lock a reservation object or NULL if no context was used or the object is not locked at all.h]hxReturns the context used to lock a reservation object or NULL if no context was used or the object is not locked at all.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjvubh)}(hWARNING: This interface is pretty horrible, but TTM needs it because it doesn't pass the struct ww_acquire_ctx around in some very long callchains. Everyone else just uses it to check whether they're holding a reservation or not.h]hWARNING: This interface is pretty horrible, but TTM needs it because it doesn’t pass the struct ww_acquire_ctx around in some very long callchains. Everyone else just uses it to check whether they’re holding a reservation or not.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjvubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_resv_unlock (C function)c.dma_resv_unlockhNtauh1jhjbhhhNhNubj)}(hhh](j)}(h+void dma_resv_unlock (struct dma_resv *obj)h]j)}(h*void dma_resv_unlock(struct dma_resv *obj)h](jM)}(hvoidh]hvoid}(hj*hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj&hhh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMubj)}(h h]h }(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj&hhhj8hMubj )}(hdma_resv_unlockh]j )}(hdma_resv_unlockh]hdma_resv_unlock}(hjKhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjGubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj&hhhj8hMubj)}(h(struct dma_resv *obj)h]j)}(hstruct dma_resv *objh](j)}(hjh]hstruct}(hjghhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjcubj)}(h h]h }(hjthhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjcubh)}(hhh]j )}(hdma_resvh]hdma_resv}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjMsbc.dma_resv_unlockasbuh1hhjcubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjcubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjcubj )}(hobjh]hobj}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjcubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj_ubah}(h]h ]h"]h$]h&]jjuh1jhj&hhhj8hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj"hhhj8hMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj8hMhjhhubjA )}(hhh]h)}(hunlock the reservation objecth]hunlock the reservation object}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhj8hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjbhNhNubjh )}(h**Parameters** ``struct dma_resv *obj`` the reservation object **Description** Unlocks the reservation object following exclusive access.h](h)}(h**Parameters**h]jr )}(hj h]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubj )}(hhh]j )}(h0``struct dma_resv *obj`` the reservation object h](j )}(h``struct dma_resv *obj``h]j)}(hj+h]hstruct dma_resv *obj}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj)ubah}(h]h ]h"]h$]h&]uh1j h\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhj%ubj )}(hhh]h)}(hthe reservation objecth]hthe reservation object}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj@hMhjAubah}(h]h ]h"]h$]h&]uh1j hj%ubeh}(h]h ]h"]h$]h&]uh1j hj@hMhj"ubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjfh]h Description}(hjhhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjdubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubh)}(h:Unlocks the reservation object following exclusive access.h]h:Unlocks the reservation object following exclusive access.}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1hh\/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:157: ./include/linux/dma-resv.hhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjbhhhNhNubeh}(h]reservation-objectsah ]h"]reservation objectsah$]h&]uh1hhhhhhhhKubh)}(hhh](h)}(h DMA Fencesh]h DMA Fences}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhKubh)}(hDMA fences, represented by :c:type:`struct dma_fence `, are the kernel internal synchronization primitive for DMA operations like GPU rendering, video encoding/decoding, or displaying buffers on a screen.h](hDMA fences, represented by }(hjhhhNhNubh)}(h&:c:type:`struct dma_fence `h]j)}(hjh]hstruct dma_fence}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:163: ./drivers/dma-buf/dma-fence.chK&hjubh, are the kernel internal synchronization primitive for DMA operations like GPU rendering, video encoding/decoding, or displaying buffers on a screen.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjҭhK&hjhhubh)}(hA fence is initialized using dma_fence_init() and completed using dma_fence_signal(). Fences are associated with a context, allocated through dma_fence_context_alloc(), and all fences on the same context are fully ordered.h]hA fence is initialized using dma_fence_init() and completed using dma_fence_signal(). Fences are associated with a context, allocated through dma_fence_context_alloc(), and all fences on the same context are fully ordered.}(hjݭhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:163: ./drivers/dma-buf/dma-fence.chK*hjhhubh)}(hSince the purposes of fences is to facilitate cross-device and cross-application synchronization, there's multiple ways to use one:h]hSince the purposes of fences is to facilitate cross-device and cross-application synchronization, there’s multiple ways to use one:}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:163: ./drivers/dma-buf/dma-fence.chK/hjhhubh)}(hhh](j)}(hIndividual fences can be exposed as a :c:type:`sync_file`, accessed as a file descriptor from userspace, created by calling sync_file_create(). This is called explicit fencing, since userspace passes around explicit synchronization points. h]h)}(hIndividual fences can be exposed as a :c:type:`sync_file`, accessed as a file descriptor from userspace, created by calling sync_file_create(). This is called explicit fencing, since userspace passes around explicit synchronization points.h](h&Individual fences can be exposed as a }(hjhhhNhNubh)}(h:c:type:`sync_file`h]j)}(hj h]h sync_file}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj sync_fileuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:163: ./drivers/dma-buf/dma-fence.chK2hjubh, accessed as a file descriptor from userspace, created by calling sync_file_create(). This is called explicit fencing, since userspace passes around explicit synchronization points.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj)hK2hjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hSome subsystems also have their own explicit fencing primitives, like :c:type:`drm_syncobj`. Compared to :c:type:`sync_file`, a :c:type:`drm_syncobj` allows the underlying fence to be updated. h]h)}(hSome subsystems also have their own explicit fencing primitives, like :c:type:`drm_syncobj`. Compared to :c:type:`sync_file`, a :c:type:`drm_syncobj` allows the underlying fence to be updated.h](hFSome subsystems also have their own explicit fencing primitives, like }(hj>hhhNhNubh)}(h:c:type:`drm_syncobj`h]j)}(hjHh]h drm_syncobj}(hjJhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjFubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj drm_syncobjuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:163: ./drivers/dma-buf/dma-fence.chK7hj>ubh. Compared to }(hj>hhhNhNubh)}(h:c:type:`sync_file`h]j)}(hjlh]h sync_file}(hjnhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj sync_fileuh1hhjehK7hj>ubh, a }(hj>hhhNhNubh)}(h:c:type:`drm_syncobj`h]j)}(hjh]h drm_syncobj}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj drm_syncobjuh1hhjehK7hj>ubh+ allows the underlying fence to be updated.}(hj>hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjehK7hj:ubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hXThen there's also implicit fencing, where the synchronization points are implicitly passed around as part of shared :c:type:`dma_buf` instances. Such implicit fences are stored in :c:type:`struct dma_resv ` through the :c:type:`dma_buf.resv ` pointer. h]h)}(hXThen there's also implicit fencing, where the synchronization points are implicitly passed around as part of shared :c:type:`dma_buf` instances. Such implicit fences are stored in :c:type:`struct dma_resv ` through the :c:type:`dma_buf.resv ` pointer.h](hvThen there’s also implicit fencing, where the synchronization points are implicitly passed around as part of shared }(hjhhhNhNubh)}(h:c:type:`dma_buf`h]j)}(hjʮh]hdma_buf}(hj̮hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjȮubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_bufuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:163: ./drivers/dma-buf/dma-fence.chK;hjubh/ instances. Such implicit fences are stored in }(hjhhhNhNubh)}(h$:c:type:`struct dma_resv `h]j)}(hjh]hstruct dma_resv}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_resvuh1hhjhK;hjubh through the }(hjhhhNhNubh)}(h :c:type:`dma_buf.resv `h]j)}(hjh]h dma_buf.resv}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_bufuh1hhjhK;hjubh pointer.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhK;hjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]jRjSuh1hhj)hK2hjhhubh)}(hhh](h)}(hDMA Fence Cross-Driver Contracth]hDMA Fence Cross-Driver Contract}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjDhhhhhKubh)}(hbSince :c:type:`dma_fence` provide a cross driver contract, all drivers must follow the same rules:h](hSince }(hjUhhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hj_h]h dma_fence}(hjahhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj]ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:169: ./drivers/dma-buf/dma-fence.chKDhjUubhI provide a cross driver contract, all drivers must follow the same rules:}(hjUhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj|hKDhjDhhubh)}(hhh](j)}(hX Fences must complete in a reasonable time. Fences which represent kernels and shaders submitted by userspace, which could run forever, must be backed up by timeout and gpu hang recovery code. Minimally that code must prevent further command submission and force complete all in-flight fences, e.g. when the driver or hardware do not support gpu reset, or if the gpu reset failed for some reason. Ideally the driver supports gpu recovery which only affects the offending userspace context, and no other userspace submissions. h]h)}(hX Fences must complete in a reasonable time. Fences which represent kernels and shaders submitted by userspace, which could run forever, must be backed up by timeout and gpu hang recovery code. Minimally that code must prevent further command submission and force complete all in-flight fences, e.g. when the driver or hardware do not support gpu reset, or if the gpu reset failed for some reason. Ideally the driver supports gpu recovery which only affects the offending userspace context, and no other userspace submissions.h]hX Fences must complete in a reasonable time. Fences which represent kernels and shaders submitted by userspace, which could run forever, must be backed up by timeout and gpu hang recovery code. Minimally that code must prevent further command submission and force complete all in-flight fences, e.g. when the driver or hardware do not support gpu reset, or if the gpu reset failed for some reason. Ideally the driver supports gpu recovery which only affects the offending userspace context, and no other userspace submissions.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:169: ./drivers/dma-buf/dma-fence.chKGhjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hX*Drivers may have different ideas of what completion within a reasonable time means. Some hang recovery code uses a fixed timeout, others a mix between observing forward progress and increasingly strict timeouts. Drivers should not try to second guess timeout handling of fences from other drivers. h]h)}(hX)Drivers may have different ideas of what completion within a reasonable time means. Some hang recovery code uses a fixed timeout, others a mix between observing forward progress and increasingly strict timeouts. Drivers should not try to second guess timeout handling of fences from other drivers.h]hX)Drivers may have different ideas of what completion within a reasonable time means. Some hang recovery code uses a fixed timeout, others a mix between observing forward progress and increasingly strict timeouts. Drivers should not try to second guess timeout handling of fences from other drivers.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:169: ./drivers/dma-buf/dma-fence.chKPhjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hTo ensure there's no deadlocks of dma_fence_wait() against other locks drivers should annotate all code required to reach dma_fence_signal(), which completes the fences, with dma_fence_begin_signalling() and dma_fence_end_signalling(). h]h)}(hTo ensure there's no deadlocks of dma_fence_wait() against other locks drivers should annotate all code required to reach dma_fence_signal(), which completes the fences, with dma_fence_begin_signalling() and dma_fence_end_signalling().h]hTo ensure there’s no deadlocks of dma_fence_wait() against other locks drivers should annotate all code required to reach dma_fence_signal(), which completes the fences, with dma_fence_begin_signalling() and dma_fence_end_signalling().}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:169: ./drivers/dma-buf/dma-fence.chKVhjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hXDrivers are allowed to call dma_fence_wait() while holding dma_resv_lock(). This means any code required for fence completion cannot acquire a :c:type:`dma_resv` lock. Note that this also pulls in the entire established locking hierarchy around dma_resv_lock() and dma_resv_unlock(). h]h)}(hXDrivers are allowed to call dma_fence_wait() while holding dma_resv_lock(). This means any code required for fence completion cannot acquire a :c:type:`dma_resv` lock. Note that this also pulls in the entire established locking hierarchy around dma_resv_lock() and dma_resv_unlock().h](hDrivers are allowed to call dma_fence_wait() while holding dma_resv_lock(). This means any code required for fence completion cannot acquire a }(hjٯhhhNhNubh)}(h:c:type:`dma_resv`h]j)}(hjh]hdma_resv}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_resvuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:169: ./drivers/dma-buf/dma-fence.chK[hjٯubhz lock. Note that this also pulls in the entire established locking hierarchy around dma_resv_lock() and dma_resv_unlock().}(hjٯhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhK[hjկubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hDrivers are allowed to call dma_fence_wait() from their :c:type:`shrinker` callbacks. This means any code required for fence completion cannot allocate memory with GFP_KERNEL. h]h)}(hDrivers are allowed to call dma_fence_wait() from their :c:type:`shrinker` callbacks. This means any code required for fence completion cannot allocate memory with GFP_KERNEL.h](h8Drivers are allowed to call dma_fence_wait() from their }(hjhhhNhNubh)}(h:c:type:`shrinker`h]j)}(hjh]hshrinker}(hj!hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjshrinkeruh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:169: ./drivers/dma-buf/dma-fence.chK`hjubhe callbacks. This means any code required for fence completion cannot allocate memory with GFP_KERNEL.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj<hK`hjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hXDrivers are allowed to call dma_fence_wait() from their :c:type:`mmu_notifier` respectively :c:type:`mmu_interval_notifier` callbacks. This means any code required for fence completion cannot allocate memory with GFP_NOFS or GFP_NOIO. Only GFP_ATOMIC is permissible, which might fail. h]h)}(hXDrivers are allowed to call dma_fence_wait() from their :c:type:`mmu_notifier` respectively :c:type:`mmu_interval_notifier` callbacks. This means any code required for fence completion cannot allocate memory with GFP_NOFS or GFP_NOIO. Only GFP_ATOMIC is permissible, which might fail.h](h8Drivers are allowed to call dma_fence_wait() from their }(hjQhhhNhNubh)}(h:c:type:`mmu_notifier`h]j)}(hj[h]h mmu_notifier}(hj]hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjYubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj mmu_notifieruh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:169: ./drivers/dma-buf/dma-fence.chKdhjQubh respectively }(hjQhhhNhNubh)}(h:c:type:`mmu_interval_notifier`h]j)}(hjh]hmmu_interval_notifier}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj}ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjmmu_interval_notifieruh1hhjxhKdhjQubh callbacks. This means any code required for fence completion cannot allocate memory with GFP_NOFS or GFP_NOIO. Only GFP_ATOMIC is permissible, which might fail.}(hjQhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjxhKdhjMubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]jRjguh1hhjhKGhjDhhubh)}(hX5Note that only GPU drivers have a reasonable excuse for both requiring :c:type:`mmu_interval_notifier` and :c:type:`shrinker` callbacks at the same time as having to track asynchronous compute work using :c:type:`dma_fence`. No driver outside of drivers/gpu should ever call dma_fence_wait() in such contexts.h](hGNote that only GPU drivers have a reasonable excuse for both requiring }(hjhhhNhNubh)}(h:c:type:`mmu_interval_notifier`h]j)}(hjh]hmmu_interval_notifier}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjmmu_interval_notifieruh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:169: ./drivers/dma-buf/dma-fence.chKihjubh and }(hjhhhNhNubh)}(h:c:type:`shrinker`h]j)}(hjh]hshrinker}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjްubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjshrinkeruh1hhjٰhKihjubhO callbacks at the same time as having to track asynchronous compute work using }(hjhhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hjh]h dma_fence}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hhjٰhKihjubhV. No driver outside of drivers/gpu should ever call dma_fence_wait() in such contexts.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjٰhKihjDhhubeh}(h]dma-fence-cross-driver-contractah ]h"]dma fence cross-driver contractah$]h&]uh1hhjhhhhhKubh)}(hhh](h)}(h DMA Fence Signalling Annotationsh]h DMA Fence Signalling Annotations}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj2hhhhhKubh)}(hProving correctness of all the kernel code around :c:type:`dma_fence` through code review and testing is tricky for a few reasons:h](h2Proving correctness of all the kernel code around }(hjChhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hjMh]h dma_fence}(hjOhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjKubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhjCubh= through code review and testing is tricky for a few reasons:}(hjChhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjjhKhj2hhubh)}(hhh](j)}(hXIt is a cross-driver contract, and therefore all drivers must follow the same rules for lock nesting order, calling contexts for various functions and anything else significant for in-kernel interfaces. But it is also impossible to test all drivers in a single machine, hence brute-force N vs. N testing of all combinations is impossible. Even just limiting to the possible combinations is infeasible. h]h)}(hXIt is a cross-driver contract, and therefore all drivers must follow the same rules for lock nesting order, calling contexts for various functions and anything else significant for in-kernel interfaces. But it is also impossible to test all drivers in a single machine, hence brute-force N vs. N testing of all combinations is impossible. Even just limiting to the possible combinations is infeasible.h]hXIt is a cross-driver contract, and therefore all drivers must follow the same rules for lock nesting order, calling contexts for various functions and anything else significant for in-kernel interfaces. But it is also impossible to test all drivers in a single machine, hence brute-force N vs. N testing of all combinations is impossible. Even just limiting to the possible combinations is infeasible.}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhjxubah}(h]h ]h"]h$]h&]uh1jhjuubj)}(hXThere is an enormous amount of driver code involved. For render drivers there's the tail of command submission, after fences are published, scheduler code, interrupt and workers to process job completion, and timeout, gpu reset and gpu hang recovery code. Plus for integration with core mm with have :c:type:`mmu_notifier`, respectively :c:type:`mmu_interval_notifier`, and :c:type:`shrinker`. For modesetting drivers there's the commit tail functions between when fences for an atomic modeset are published, and when the corresponding vblank completes, including any interrupt processing and related workers. Auditing all that code, across all drivers, is not feasible. h]h)}(hXThere is an enormous amount of driver code involved. For render drivers there's the tail of command submission, after fences are published, scheduler code, interrupt and workers to process job completion, and timeout, gpu reset and gpu hang recovery code. Plus for integration with core mm with have :c:type:`mmu_notifier`, respectively :c:type:`mmu_interval_notifier`, and :c:type:`shrinker`. For modesetting drivers there's the commit tail functions between when fences for an atomic modeset are published, and when the corresponding vblank completes, including any interrupt processing and related workers. Auditing all that code, across all drivers, is not feasible.h](hX.There is an enormous amount of driver code involved. For render drivers there’s the tail of command submission, after fences are published, scheduler code, interrupt and workers to process job completion, and timeout, gpu reset and gpu hang recovery code. Plus for integration with core mm with have }(hjhhhNhNubh)}(h:c:type:`mmu_notifier`h]j)}(hjh]h mmu_notifier}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj mmu_notifieruh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhjubh, respectively }(hjhhhNhNubh)}(h:c:type:`mmu_interval_notifier`h]j)}(hjñh]hmmu_interval_notifier}(hjűhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjmmu_interval_notifieruh1hhjhKhjubh, and }(hjhhhNhNubh)}(h:c:type:`shrinker`h]j)}(hjh]hshrinker}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjshrinkeruh1hhjhKhjubhX. For modesetting drivers there’s the commit tail functions between when fences for an atomic modeset are published, and when the corresponding vblank completes, including any interrupt processing and related workers. Auditing all that code, across all drivers, is not feasible.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1jhjuubj)}(hXDue to how many other subsystems are involved and the locking hierarchies this pulls in there is extremely thin wiggle-room for driver-specific differences. :c:type:`dma_fence` interacts with almost all of the core memory handling through page fault handlers via :c:type:`dma_resv`, dma_resv_lock() and dma_resv_unlock(). On the other side it also interacts through all allocation sites through :c:type:`mmu_notifier` and :c:type:`shrinker`. h]h)}(hXDue to how many other subsystems are involved and the locking hierarchies this pulls in there is extremely thin wiggle-room for driver-specific differences. :c:type:`dma_fence` interacts with almost all of the core memory handling through page fault handlers via :c:type:`dma_resv`, dma_resv_lock() and dma_resv_unlock(). On the other side it also interacts through all allocation sites through :c:type:`mmu_notifier` and :c:type:`shrinker`.h](hDue to how many other subsystems are involved and the locking hierarchies this pulls in there is extremely thin wiggle-room for driver-specific differences. }(hjhhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hj!h]h dma_fence}(hj#hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhjubhW interacts with almost all of the core memory handling through page fault handlers via }(hjhhhNhNubh)}(h:c:type:`dma_resv`h]j)}(hjEh]hdma_resv}(hjGhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjCubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_resvuh1hhj>hKhjubhr, dma_resv_lock() and dma_resv_unlock(). On the other side it also interacts through all allocation sites through }(hjhhhNhNubh)}(h:c:type:`mmu_notifier`h]j)}(hjhh]h mmu_notifier}(hjjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjfubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj mmu_notifieruh1hhj>hKhjubh and }(hjhhhNhNubh)}(h:c:type:`shrinker`h]j)}(hjh]hshrinker}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjshrinkeruh1hhj>hKhjubh.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj>hKhjubah}(h]h ]h"]h$]h&]uh1jhjuubeh}(h]h ]h"]h$]h&]jRjguh1hhjhKhj2hhubh)}(hXFurthermore lockdep does not handle cross-release dependencies, which means any deadlocks between dma_fence_wait() and dma_fence_signal() can't be caught at runtime with some quick testing. The simplest example is one thread waiting on a :c:type:`dma_fence` while holding a lock::h](hFurthermore lockdep does not handle cross-release dependencies, which means any deadlocks between dma_fence_wait() and dma_fence_signal() can’t be caught at runtime with some quick testing. The simplest example is one thread waiting on a }(hjhhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hjȲh]h dma_fence}(hjʲhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjƲubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhjubh while holding a lock:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhj2hhubj)}(h&lock(A); dma_fence_wait(B); unlock(A);h]h&lock(A); dma_fence_wait(B); unlock(A);}hjsbah}(h]h ]h"]h$]h&]jjuh1jh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhj2hhubh)}(hwhile the other thread is stuck trying to acquire the same lock, which prevents it from signalling the fence the previous thread is stuck waiting on::h]hwhile the other thread is stuck trying to acquire the same lock, which prevents it from signalling the fence the previous thread is stuck waiting on:}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhj2hhubj)}(h(lock(A); unlock(A); dma_fence_signal(B);h]h(lock(A); unlock(A); dma_fence_signal(B);}hjsbah}(h]h ]h"]h$]h&]jjuh1jh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhj2hhubh)}(hBy manually annotating all code relevant to signalling a :c:type:`dma_fence` we can teach lockdep about these dependencies, which also helps with the validation headache since now lockdep can check all the rules for us::h](h9By manually annotating all code relevant to signalling a }(hjhhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hj'h]h dma_fence}(hj)hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj%ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhjubh we can teach lockdep about these dependencies, which also helps with the validation headache since now lockdep can check all the rules for us:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjDhKhj2hhubj)}(hqcookie = dma_fence_begin_signalling(); lock(A); unlock(A); dma_fence_signal(B); dma_fence_end_signalling(cookie);h]hqcookie = dma_fence_begin_signalling(); lock(A); unlock(A); dma_fence_signal(B); dma_fence_end_signalling(cookie);}hjOsbah}(h]h ]h"]h$]h&]jjuh1jh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhj2hhubh)}(hFor using dma_fence_begin_signalling() and dma_fence_end_signalling() to annotate critical sections the following rules need to be observed:h]hFor using dma_fence_begin_signalling() and dma_fence_end_signalling() to annotate critical sections the following rules need to be observed:}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhj2hhubh)}(hhh](j)}(hXgAll code necessary to complete a :c:type:`dma_fence` must be annotated, from the point where a fence is accessible to other threads, to the point where dma_fence_signal() is called. Un-annotated code can contain deadlock issues, and due to the very strict rules and many corner cases it is infeasible to catch these just with review or normal stress testing. h]h)}(hXfAll code necessary to complete a :c:type:`dma_fence` must be annotated, from the point where a fence is accessible to other threads, to the point where dma_fence_signal() is called. Un-annotated code can contain deadlock issues, and due to the very strict rules and many corner cases it is infeasible to catch these just with review or normal stress testing.h](h!All code necessary to complete a }(hjthhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hj~h]h dma_fence}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj|ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhjtubhX2 must be annotated, from the point where a fence is accessible to other threads, to the point where dma_fence_signal() is called. Un-annotated code can contain deadlock issues, and due to the very strict rules and many corner cases it is infeasible to catch these just with review or normal stress testing.}(hjthhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhjpubah}(h]h ]h"]h$]h&]uh1jhjmubj)}(h:c:type:`struct dma_resv ` deserves a special note, since the readers are only protected by rcu. This means the signalling critical section starts as soon as the new fences are installed, even before dma_resv_unlock() is called. h]h)}(h:c:type:`struct dma_resv ` deserves a special note, since the readers are only protected by rcu. This means the signalling critical section starts as soon as the new fences are installed, even before dma_resv_unlock() is called.h](h)}(h$:c:type:`struct dma_resv `h]j)}(hjh]hstruct dma_resv}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_resvuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhjubh deserves a special note, since the readers are only protected by rcu. This means the signalling critical section starts as soon as the new fences are installed, even before dma_resv_unlock() is called.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjӳhKhjubah}(h]h ]h"]h$]h&]uh1jhjmubj)}(hXqThe only exception are fast paths and opportunistic signalling code, which calls dma_fence_signal() purely as an optimization, but is not required to guarantee completion of a :c:type:`dma_fence`. The usual example is a wait IOCTL which calls dma_fence_signal(), while the mandatory completion path goes through a hardware interrupt and possible job completion worker. h]h)}(hXpThe only exception are fast paths and opportunistic signalling code, which calls dma_fence_signal() purely as an optimization, but is not required to guarantee completion of a :c:type:`dma_fence`. The usual example is a wait IOCTL which calls dma_fence_signal(), while the mandatory completion path goes through a hardware interrupt and possible job completion worker.h](hThe only exception are fast paths and opportunistic signalling code, which calls dma_fence_signal() purely as an optimization, but is not required to guarantee completion of a }(hjhhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hjh]h dma_fence}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chKhjubh. The usual example is a wait IOCTL which calls dma_fence_signal(), while the mandatory completion path goes through a hardware interrupt and possible job completion worker.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1jhjmubj)}(hXMTo aid composability of code, the annotations can be freely nested, as long as the overall locking hierarchy is consistent. The annotations also work both in interrupt and process context. Due to implementation details this requires that callers pass an opaque cookie from dma_fence_begin_signalling() to dma_fence_end_signalling(). h]h)}(hXLTo aid composability of code, the annotations can be freely nested, as long as the overall locking hierarchy is consistent. The annotations also work both in interrupt and process context. Due to implementation details this requires that callers pass an opaque cookie from dma_fence_begin_signalling() to dma_fence_end_signalling().h]hXLTo aid composability of code, the annotations can be freely nested, as long as the overall locking hierarchy is consistent. The annotations also work both in interrupt and process context. Due to implementation details this requires that callers pass an opaque cookie from dma_fence_begin_signalling() to dma_fence_end_signalling().}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chMhj ubah}(h]h ]h"]h$]h&]uh1jhjmubj)}(hX'Validation against the cross driver contract is implemented by priming lockdep with the relevant hierarchy at boot-up. This means even just testing with a single device is enough to validate a driver, at least as far as deadlocks with dma_fence_wait() against dma_fence_signal() are concerned. h]h)}(hX%Validation against the cross driver contract is implemented by priming lockdep with the relevant hierarchy at boot-up. This means even just testing with a single device is enough to validate a driver, at least as far as deadlocks with dma_fence_wait() against dma_fence_signal() are concerned.h]hX%Validation against the cross driver contract is implemented by priming lockdep with the relevant hierarchy at boot-up. This means even just testing with a single device is enough to validate a driver, at least as far as deadlocks with dma_fence_wait() against dma_fence_signal() are concerned.}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:175: ./drivers/dma-buf/dma-fence.chM hj9ubah}(h]h ]h"]h$]h&]uh1jhjmubeh}(h]h ]h"]h$]h&]jRjguh1hhjhKhj2hhubeh}(h] dma-fence-signalling-annotationsah ]h"] dma fence signalling annotationsah$]h&]uh1hhjhhhhhKubh)}(hhh](h)}(hDMA Fence Deadline Hintsh]hDMA Fence Deadline Hints}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1hhj`hhhhhKubh)}(hX`In an ideal world, it would be possible to pipeline a workload sufficiently that a utilization based device frequency governor could arrive at a minimum frequency that meets the requirements of the use-case, in order to minimize power consumption. But in the real world there are many workloads which defy this ideal. For example, but not limited to:h]hX`In an ideal world, it would be possible to pipeline a workload sufficiently that a utilization based device frequency governor could arrive at a minimum frequency that meets the requirements of the use-case, in order to minimize power consumption. But in the real world there are many workloads which defy this ideal. For example, but not limited to:}(hjqhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:181: ./drivers/dma-buf/dma-fence.chMhj`hhubh)}(hhh](j)}(hWorkloads that ping-pong between device and CPU, with alternating periods of CPU waiting for device, and device waiting on CPU. This can result in devfreq and cpufreq seeing idle time in their respective domains and in result reduce frequency. h]h)}(hWorkloads that ping-pong between device and CPU, with alternating periods of CPU waiting for device, and device waiting on CPU. This can result in devfreq and cpufreq seeing idle time in their respective domains and in result reduce frequency.h]hWorkloads that ping-pong between device and CPU, with alternating periods of CPU waiting for device, and device waiting on CPU. This can result in devfreq and cpufreq seeing idle time in their respective domains and in result reduce frequency.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:181: ./drivers/dma-buf/dma-fence.chMhjubah}(h]h ]h"]h$]h&]uh1jhjubj)}(hX}Workloads that interact with a periodic time based deadline, such as double buffered GPU rendering vs vblank sync'd page flipping. In this scenario, missing a vblank deadline results in an *increase* in idle time on the GPU (since it has to wait an additional vblank period), sending a signal to the GPU's devfreq to reduce frequency, when in fact the opposite is what is needed. h]h)}(hX|Workloads that interact with a periodic time based deadline, such as double buffered GPU rendering vs vblank sync'd page flipping. In this scenario, missing a vblank deadline results in an *increase* in idle time on the GPU (since it has to wait an additional vblank period), sending a signal to the GPU's devfreq to reduce frequency, when in fact the opposite is what is needed.h](hWorkloads that interact with a periodic time based deadline, such as double buffered GPU rendering vs vblank sync’d page flipping. In this scenario, missing a vblank deadline results in an }(hjhhhNhNubj )}(h *increase*h]hincrease}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1j hjubh in idle time on the GPU (since it has to wait an additional vblank period), sending a signal to the GPU’s devfreq to reduce frequency, when in fact the opposite is what is needed.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:181: ./drivers/dma-buf/dma-fence.chMhjubah}(h]h ]h"]h$]h&]uh1jhjubeh}(h]h ]h"]h$]h&]jRjguh1hhjhMhj`hhubh)}(hX>To this end, deadline hint(s) can be set on a :c:type:`dma_fence` via :c:type:`dma_fence_set_deadline` (or indirectly via userspace facing ioctls like :c:type:`sync_set_deadline`). The deadline hint provides a way for the waiting driver, or userspace, to convey an appropriate sense of urgency to the signaling driver.h](h.To this end, deadline hint(s) can be set on a }(hjʹhhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hj״h]h dma_fence}(hjٴhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjմubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:181: ./drivers/dma-buf/dma-fence.chMhjʹubh via }(hjʹhhhNhNubh)}(h :c:type:`dma_fence_set_deadline`h]j)}(hjh]hdma_fence_set_deadline}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_fence_set_deadlineuh1hhjhMhjʹubh1 (or indirectly via userspace facing ioctls like }(hjʹhhhNhNubh)}(h:c:type:`sync_set_deadline`h]j)}(hjh]hsync_set_deadline}(hj hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjsync_set_deadlineuh1hhjhMhjʹubh). The deadline hint provides a way for the waiting driver, or userspace, to convey an appropriate sense of urgency to the signaling driver.}(hjʹhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMhj`hhubh)}(hXrA deadline hint is given in absolute ktime (CLOCK_MONOTONIC for userspace facing APIs). The time could either be some point in the future (such as the vblank based deadline for page-flipping, or the start of a compositor's composition cycle), or the current time to indicate an immediate deadline hint (Ie. forward progress cannot be made until this fence is signaled).h]hXtA deadline hint is given in absolute ktime (CLOCK_MONOTONIC for userspace facing APIs). The time could either be some point in the future (such as the vblank based deadline for page-flipping, or the start of a compositor’s composition cycle), or the current time to indicate an immediate deadline hint (Ie. forward progress cannot be made until this fence is signaled).}(hjEhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:181: ./drivers/dma-buf/dma-fence.chMhj`hhubh)}(hMultiple deadlines may be set on a given fence, even in parallel. See the documentation for :c:type:`dma_fence_ops.set_deadline `.h](h]Multiple deadlines may be set on a given fence, even in parallel. See the documentation for }(hjThhhNhNubh)}(h4:c:type:`dma_fence_ops.set_deadline `h]j)}(hj^h]hdma_fence_ops.set_deadline}(hj`hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj\ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fence_opsuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:181: ./drivers/dma-buf/dma-fence.chMhjTubh.}(hjThhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj{hMhj`hhubh)}(hThe deadline hint is just that, a hint. The driver that created the fence may react by increasing frequency, making different scheduling choices, etc. Or doing nothing at all.h]hThe deadline hint is just that, a hint. The driver that created the fence may react by increasing frequency, making different scheduling choices, etc. Or doing nothing at all.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:181: ./drivers/dma-buf/dma-fence.chMhj`hhubeh}(h]dma-fence-deadline-hintsah ]h"]dma fence deadline hintsah$]h&]uh1hhjhhhhhKubh)}(hhh](h)}(hDMA Fences Functions Referenceh]hDMA Fences Functions Reference}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhKubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_get_stub (C function)c.dma_fence_get_stubhNtauh1jhjhhhNhNubj)}(hhh](j)}(h,struct dma_fence * dma_fence_get_stub (void)h]j)}(h*struct dma_fence *dma_fence_get_stub(void)h](j)}(hjh]hstruct}(hjǵhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjõhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKubj)}(h h]h }(hjյhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjõhhhjԵhKubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGdma_fence_get_stubsbc.dma_fence_get_stubasbuh1hhjõhhhjԵhKubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjõhhhjԵhKubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjõhhhjԵhKubj )}(hdma_fence_get_stubh]j )}(hjh]hdma_fence_get_stub}(hj&hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj"ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjõhhhjԵhKubj)}(h(void)h]j)}(hvoidh]jM)}(hvoidh]hvoid}(hjAhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj=ubah}(h]h ]h"]h$]h&]noemphjjuh1jhj9ubah}(h]h ]h"]h$]h&]jjuh1jhjõhhhjԵhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjԵhKubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjԵhKhjhhubjA )}(hhh]h)}(hreturn a signaled fenceh]hreturn a signaled fence}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjhhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjԵhKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``void`` no arguments **Description** Return a stub fence which is already signaled. The fence's timestamp corresponds to the initialisation time of the linux kernel.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjubj )}(hhh]j )}(h``void`` no arguments h](j )}(h``void``h]j)}(hjh]hvoid}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjubj )}(hhh]h)}(h no argumentsh]h no arguments}(hjŶhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhj¶ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjubh)}(hReturn a stub fence which is already signaled. The fence's timestamp corresponds to the initialisation time of the linux kernel.h]hReturn a stub fence which is already signaled. The fence’s timestamp corresponds to the initialisation time of the linux kernel.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j,dma_fence_allocate_private_stub (C function)!c.dma_fence_allocate_private_stubhNtauh1jhjhhhNhNubj)}(hhh](j)}(hFstruct dma_fence * dma_fence_allocate_private_stub (ktime_t timestamp)h]j)}(hDstruct dma_fence *dma_fence_allocate_private_stub(ktime_t timestamp)h](j)}(hjh]hstruct}(hj,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj(hhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKubj)}(h h]h }(hj:hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj(hhhj9hKubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjKhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjHubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjMmodnameN classnameNjj)}j]jO)}jGdma_fence_allocate_private_stubsb!c.dma_fence_allocate_private_stubasbuh1hhj(hhhj9hKubj)}(h h]h }(hjlhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj(hhhj9hKubjd)}(hjgh]h*}(hjzhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj(hhhj9hKubj )}(hdma_fence_allocate_private_stubh]j )}(hjih]hdma_fence_allocate_private_stub}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj(hhhj9hKubj)}(h(ktime_t timestamp)h]j)}(hktime_t timestamph](h)}(hhh]j )}(hktime_th]hktime_t}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jg!c.dma_fence_allocate_private_stubasbuh1hhjubj)}(h h]h }(hjǷhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(h timestamph]h timestamp}(hjշhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhj(hhhj9hKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj$hhhj9hKubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj9hKhj!hhubjA )}(hhh]h)}(h return a private, signaled fenceh]h return a private, signaled fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjhhubah}(h]h ]h"]h$]h&]uh1j@ hj!hhhj9hKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``ktime_t timestamp`` timestamp when the fence was signaled **Description** Return a newly allocated and signaled stub fence.h](h)}(h**Parameters**h]jr )}(hj!h]h Parameters}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjubj )}(hhh]j )}(h<``ktime_t timestamp`` timestamp when the fence was signaled h](j )}(h``ktime_t timestamp``h]j)}(hj@h]hktime_t timestamp}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj>ubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhj:ubj )}(hhh]h)}(h%timestamp when the fence was signaledh]h%timestamp when the fence was signaled}(hjYhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjUhKhjVubah}(h]h ]h"]h$]h&]uh1j hj:ubeh}(h]h ]h"]h$]h&]uh1j hjUhKhj7ubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj{h]h Description}(hj}hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjyubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjubh)}(h1Return a newly allocated and signaled stub fence.h]h1Return a newly allocated and signaled stub fence.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j$dma_fence_context_alloc (C function)c.dma_fence_context_allochNtauh1jhjhhhNhNubj)}(hhh](j)}(h*u64 dma_fence_context_alloc (unsigned num)h]j)}(h)u64 dma_fence_context_alloc(unsigned num)h](h)}(hhh]j )}(hu64h]hu64}(hjøhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjŸmodnameN classnameNjj)}j]jO)}jGdma_fence_context_allocsbc.dma_fence_context_allocasbuh1hhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhKubj )}(hdma_fence_context_alloch]j )}(hjh]hdma_fence_context_alloc}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhKubj)}(h(unsigned num)h]j)}(h unsigned numh](jM)}(hunsignedh]hunsigned}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hnumh]hnum}(hj.hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhKubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhKhjhhubjA )}(hhh]h)}(h#allocate an array of fence contextsh]h#allocate an array of fence contexts}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjUhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jpjc jpjd je jf uh1jhhhjhNhNubjh )}(hX6**Parameters** ``unsigned num`` amount of contexts to allocate **Description** This function will return the first index of the number of fence contexts allocated. The fence context is used for setting :c:type:`dma_fence.context ` to a unique number by passing the context to dma_fence_init().h](h)}(h**Parameters**h]jr )}(hjzh]h Parameters}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjxubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjtubj )}(hhh]j )}(h0``unsigned num`` amount of contexts to allocate h](j )}(h``unsigned num``h]j)}(hjh]h unsigned num}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjubj )}(hhh]h)}(hamount of contexts to allocateh]hamount of contexts to allocate}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubah}(h]h ]h"]h$]h&]uh1j hjtubh)}(h**Description**h]jr )}(hjԹh]h Description}(hjֹhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjҹubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjtubh)}(hThis function will return the first index of the number of fence contexts allocated. The fence context is used for setting :c:type:`dma_fence.context ` to a unique number by passing the context to dma_fence_init().h](h|This function will return the first index of the number of fence contexts allocated. The fence context is used for setting }(hjhhhNhNubh)}(h':c:type:`dma_fence.context `h]j)}(hjh]hdma_fence.context}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjubh? to a unique number by passing the context to dma_fence_init().}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhjtubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j'dma_fence_begin_signalling (C function)c.dma_fence_begin_signallinghNtauh1jhjhhhNhNubj)}(hhh](j)}(h&bool dma_fence_begin_signalling (void)h]j)}(h%bool dma_fence_begin_signalling(void)h](jM)}(hji5h]hbool}(hj<hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj8hhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hjJhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj8hhhjIhMubj )}(hdma_fence_begin_signallingh]j )}(hdma_fence_begin_signallingh]hdma_fence_begin_signalling}(hj\hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjXubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj8hhhjIhMubj)}(h(void)h]j)}(hvoidh]jM)}(hvoidh]hvoid}(hjxhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjtubah}(h]h ]h"]h$]h&]noemphjjuh1jhjpubah}(h]h ]h"]h$]h&]jjuh1jhj8hhhjIhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj4hhhjIhMubah}(h]j/ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjIhMhj1hhubjA )}(hhh]h)}(h-begin a critical DMA fence signalling sectionh]h-begin a critical DMA fence signalling section}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hj1hhhjIhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``void`` no arguments **Description** Drivers should use this to annotate the beginning of any code section required to eventually complete :c:type:`dma_fence` by calling dma_fence_signal(). The end of these critical sections are annotated with dma_fence_end_signalling(). Opaque cookie needed by the implementation, which needs to be passed to dma_fence_end_signalling().h](h)}(h**Parameters**h]jr )}(hjĺh]h Parameters}(hjƺhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjºubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]j )}(h``void`` no arguments h](j )}(h``void``h]j)}(hjh]hvoid}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjݺubj )}(hhh]h)}(h no argumentsh]h no arguments}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubah}(h]h ]h"]h$]h&]uh1j hjݺubeh}(h]h ]h"]h$]h&]uh1j hjhKhjںubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chKhjubh)}(hDrivers should use this to annotate the beginning of any code section required to eventually complete :c:type:`dma_fence` by calling dma_fence_signal().h](hfDrivers should use this to annotate the beginning of any code section required to eventually complete }(hj4hhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hj>h]h dma_fence}(hj@hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj<ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj4ubh by calling dma_fence_signal().}(hj4hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj[hMhjubh)}(hQThe end of these critical sections are annotated with dma_fence_end_signalling().h]hQThe end of these critical sections are annotated with dma_fence_end_signalling().}(hjfhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hcOpaque cookie needed by the implementation, which needs to be passed to dma_fence_end_signalling().h]hcOpaque cookie needed by the implementation, which needs to be passed to dma_fence_end_signalling().}(hjuhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j%dma_fence_end_signalling (C function)c.dma_fence_end_signallinghNtauh1jhjhhhNhNubj)}(hhh](j)}(h+void dma_fence_end_signalling (bool cookie)h]j)}(h*void dma_fence_end_signalling(bool cookie)h](jM)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM6ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhM6ubj )}(hdma_fence_end_signallingh]j )}(hdma_fence_end_signallingh]hdma_fence_end_signalling}(hjŻhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhM6ubj)}(h (bool cookie)h]j)}(h bool cookieh](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjݻubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjݻubj )}(hcookieh]hcookie}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjݻubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjٻubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhM6ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhM6ubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhM6hjhhubjA )}(hhh]h)}(h+end a critical DMA fence signalling sectionh]h+end a critical DMA fence signalling section}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM6hj#hhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhM6ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j>jc j>jd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``bool cookie`` opaque cookie from dma_fence_begin_signalling() **Description** Closes a critical section annotation opened by dma_fence_begin_signalling().h](h)}(h**Parameters**h]jr )}(hjHh]h Parameters}(hjJhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjFubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM:hjBubj )}(hhh]j )}(h@``bool cookie`` opaque cookie from dma_fence_begin_signalling() h](j )}(h``bool cookie``h]j)}(hjgh]h bool cookie}(hjihhhNhNubah}(h]h ]h"]h$]h&]uh1jhjeubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM7hjaubj )}(hhh]h)}(h/opaque cookie from dma_fence_begin_signalling()h]h/opaque cookie from dma_fence_begin_signalling()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj|hM7hj}ubah}(h]h ]h"]h$]h&]uh1j hjaubeh}(h]h ]h"]h$]h&]uh1j hj|hM7hj^ubah}(h]h ]h"]h$]h&]uh1j hjBubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM9hjBubh)}(hLCloses a critical section annotation opened by dma_fence_begin_signalling().h]hLCloses a critical section annotation opened by dma_fence_begin_signalling().}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM8hjBubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j.dma_fence_signal_timestamp_locked (C function)#c.dma_fence_signal_timestamp_lockedhNtauh1jhjhhhNhNubj)}(hhh](j)}(hSvoid dma_fence_signal_timestamp_locked (struct dma_fence *fence, ktime_t timestamp)h]j)}(hRvoid dma_fence_signal_timestamp_locked(struct dma_fence *fence, ktime_t timestamp)h](jM)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMSubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMSubj )}(h!dma_fence_signal_timestamp_lockedh]j )}(h!dma_fence_signal_timestamp_lockedh]h!dma_fence_signal_timestamp_locked}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMSubj)}(h,(struct dma_fence *fence, ktime_t timestamp)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjBhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj?ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjDmodnameN classnameNjj)}j]jO)}jGj sb#c.dma_fence_signal_timestamp_lockedasbuh1hhj ubj)}(h h]h }(hjbhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubjd)}(hjgh]h*}(hjphhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj ubj )}(hfenceh]hfence}(hj}hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hktime_t timestamph](h)}(hhh]j )}(hktime_th]hktime_t}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]j^#c.dma_fence_signal_timestamp_lockedasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(h timestamph]h timestamp}(hjŽhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMSubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj߼hhhjhMSubah}(h]jڼah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMShjܼhhubjA )}(hhh]h)}(hsignal completion of a fenceh]hsignal completion of a fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMShjhhubah}(h]h ]h"]h$]h&]uh1j@ hjܼhhhjhMSubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to signal ``ktime_t timestamp`` fence signal timestamp in kernel's CLOCK_MONOTONIC time domain **Description** Signal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time. Set the timestamp provided as the fence signal timestamp. Unlike dma_fence_signal_timestamp(), this function must be called with :c:type:`dma_fence.lock ` held.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMWhj ubj )}(hhh](j )}(h0``struct dma_fence *fence`` the fence to signal h](j )}(h``struct dma_fence *fence``h]j)}(hj0h]hstruct dma_fence *fence}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj.ubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMThj*ubj )}(hhh]h)}(hthe fence to signalh]hthe fence to signal}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjEhMThjFubah}(h]h ]h"]h$]h&]uh1j hj*ubeh}(h]h ]h"]h$]h&]uh1j hjEhMThj'ubj )}(hU``ktime_t timestamp`` fence signal timestamp in kernel's CLOCK_MONOTONIC time domain h](j )}(h``ktime_t timestamp``h]j)}(hjih]hktime_t timestamp}(hjkhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjgubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMUhjcubj )}(hhh]h)}(h>fence signal timestamp in kernel's CLOCK_MONOTONIC time domainh]h@fence signal timestamp in kernel’s CLOCK_MONOTONIC time domain}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj~hMUhjubah}(h]h ]h"]h$]h&]uh1j hjcubeh}(h]h ]h"]h$]h&]uh1j hj~hMUhj'ubeh}(h]h ]h"]h$]h&]uh1j hj ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMWhj ubh)}(hXtSignal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time. Set the timestamp provided as the fence signal timestamp.h]hXtSignal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time. Set the timestamp provided as the fence signal timestamp.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMVhj ubh)}(hqUnlike dma_fence_signal_timestamp(), this function must be called with :c:type:`dma_fence.lock ` held.h](hGUnlike dma_fence_signal_timestamp(), this function must be called with }(hjɾhhhNhNubh)}(h$:c:type:`dma_fence.lock `h]j)}(hjӾh]hdma_fence.lock}(hjվhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjѾubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM]hjɾubh held.}(hjɾhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhM]hj ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j'dma_fence_signal_timestamp (C function)c.dma_fence_signal_timestamphNtauh1jhjhhhNhNubj)}(hhh](j)}(hLvoid dma_fence_signal_timestamp (struct dma_fence *fence, ktime_t timestamp)h]j)}(hKvoid dma_fence_signal_timestamp(struct dma_fence *fence, ktime_t timestamp)h](jM)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hj*hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhj)hMubj )}(hdma_fence_signal_timestamph]j )}(hdma_fence_signal_timestamph]hdma_fence_signal_timestamp}(hj<hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj8ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhj)hMubj)}(h,(struct dma_fence *fence, ktime_t timestamp)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjXhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjTubj)}(h h]h }(hjehhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjTubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjvhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjsubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjxmodnameN classnameNjj)}j]jO)}jGj>sbc.dma_fence_signal_timestampasbuh1hhjTubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjTubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjTubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjTubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjPubj)}(hktime_t timestamph](h)}(hhh]j )}(hktime_th]hktime_t}(hjͿhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjʿubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjϿmodnameN classnameNjj)}j]jc.dma_fence_signal_timestampasbuh1hhjƿubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjƿubj )}(h timestamph]h timestamp}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjƿubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjPubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhj)hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhj)hMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj)hMhjhhubjA )}(hhh]h)}(hsignal completion of a fenceh]hsignal completion of a fence}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj hhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhj)hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j;jc j;jd je jf uh1jhhhjhNhNubjh )}(hX **Parameters** ``struct dma_fence *fence`` the fence to signal ``ktime_t timestamp`` fence signal timestamp in kernel's CLOCK_MONOTONIC time domain **Description** Signal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time. Set the timestamp provided as the fence signal timestamp.h](h)}(h**Parameters**h]jr )}(hjEh]h Parameters}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjCubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj?ubj )}(hhh](j )}(h0``struct dma_fence *fence`` the fence to signal h](j )}(h``struct dma_fence *fence``h]j)}(hjdh]hstruct dma_fence *fence}(hjfhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjbubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj^ubj )}(hhh]h)}(hthe fence to signalh]hthe fence to signal}(hj}hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjyhMhjzubah}(h]h ]h"]h$]h&]uh1j hj^ubeh}(h]h ]h"]h$]h&]uh1j hjyhMhj[ubj )}(hU``ktime_t timestamp`` fence signal timestamp in kernel's CLOCK_MONOTONIC time domain h](j )}(h``ktime_t timestamp``h]j)}(hjh]hktime_t timestamp}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(h>fence signal timestamp in kernel's CLOCK_MONOTONIC time domainh]h@fence signal timestamp in kernel’s CLOCK_MONOTONIC time domain}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhj[ubeh}(h]h ]h"]h$]h&]uh1j hj?ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj?ubh)}(hXtSignal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time. Set the timestamp provided as the fence signal timestamp.h]hXtSignal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time. Set the timestamp provided as the fence signal timestamp.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj?ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j$dma_fence_signal_locked (C function)c.dma_fence_signal_lockedhNtauh1jhjhhhNhNubj)}(hhh](j)}(h6void dma_fence_signal_locked (struct dma_fence *fence)h]j)}(h5void dma_fence_signal_locked(struct dma_fence *fence)h](jM)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hj,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhj+hMubj )}(hdma_fence_signal_lockedh]j )}(hdma_fence_signal_lockedh]hdma_fence_signal_locked}(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj:ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhj+hMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjZhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjVubj)}(h h]h }(hjghhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjVubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjxhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjuubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjzmodnameN classnameNjj)}j]jO)}jGj@sbc.dma_fence_signal_lockedasbuh1hhjVubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjVubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjVubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjVubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjRubah}(h]h ]h"]h$]h&]jjuh1jhjhhhj+hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhj+hMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj+hMhjhhubjA )}(hhh]h)}(hsignal completion of a fenceh]hsignal completion of a fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhj+hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to signal **Description** Signal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time. Unlike dma_fence_signal(), this function must be called with :c:type:`dma_fence.lock ` held.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]j )}(h0``struct dma_fence *fence`` the fence to signal h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(hthe fence to signalh]hthe fence to signal}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj3hMhj4ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj3hMhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjYh]h Description}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjWubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hX:Signal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time.h]hX:Signal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time.}(hjohhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hgUnlike dma_fence_signal(), this function must be called with :c:type:`dma_fence.lock ` held.h](h=Unlike dma_fence_signal(), this function must be called with }(hj~hhhNhNubh)}(h$:c:type:`dma_fence.lock `h]j)}(hjh]hdma_fence.lock}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj~ubh held.}(hj~hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j.dma_fence_check_and_signal_locked (C function)#c.dma_fence_check_and_signal_lockedhNtauh1jhjhhhNhNubj)}(hhh](j)}(h@bool dma_fence_check_and_signal_locked (struct dma_fence *fence)h]j)}(h?bool dma_fence_check_and_signal_locked(struct dma_fence *fence)h](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(h!dma_fence_check_and_signal_lockedh]j )}(h!dma_fence_check_and_signal_lockedh]h!dma_fence_check_and_signal_locked}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj*hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj'ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj,modnameN classnameNjj)}j]jO)}jGjsb#c.dma_fence_check_and_signal_lockedasbuh1hhjubj)}(h h]h }(hjJhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjXhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hjehhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h)signal the fence if it's not yet signaledh]h+signal the fence if it’s not yet signaled}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hXs**Parameters** ``struct dma_fence *fence`` the fence to check and signal **Description** Checks whether a fence was signaled and signals it if it was not yet signaled. Unlike dma_fence_check_and_signal(), this function must be called with :c:type:`struct dma_fence `.lock being held. **Return** true if fence has been signaled already, false otherwise.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]j )}(h:``struct dma_fence *fence`` the fence to check and signal h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(hthe fence to check and signalh]hthe fence to check and signal}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj h]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hNChecks whether a fence was signaled and signals it if it was not yet signaled.h]hNChecks whether a fence was signaled and signals it if it was not yet signaled.}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(h~Unlike dma_fence_check_and_signal(), this function must be called with :c:type:`struct dma_fence `.lock being held.h](hGUnlike dma_fence_check_and_signal(), this function must be called with }(hj0hhhNhNubh)}(h&:c:type:`struct dma_fence `h]j)}(hj:h]hstruct dma_fence}(hj<hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj8ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj0ubh.lock being held.}(hj0hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjWhMhjubh)}(h **Return**h]jr )}(hjdh]hReturn}(hjfhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjbubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(h9true if fence has been signaled already, false otherwise.h]h9true if fence has been signaled already, false otherwise.}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j'dma_fence_check_and_signal (C function)c.dma_fence_check_and_signalhNtauh1jhjhhhNhNubj)}(hhh](j)}(h9bool dma_fence_check_and_signal (struct dma_fence *fence)h]j)}(h8bool dma_fence_check_and_signal(struct dma_fence *fence)h](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(hdma_fence_check_and_signalh]j )}(hdma_fence_check_and_signalh]hdma_fence_check_and_signal}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_check_and_signalasbuh1hhjubj)}(h h]h }(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj1hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h)signal the fence if it's not yet signaledh]h+signal the fence if it’s not yet signaled}(hjhhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjehhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to check and signal **Description** Checks whether a fence was signaled and signals it if it was not yet signaled. All this is done in a race-free manner. **Return** true if fence has been signaled already, false otherwise.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]j )}(h:``struct dma_fence *fence`` the fence to check and signal h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(hthe fence to check and signalh]hthe fence to check and signal}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hvChecks whether a fence was signaled and signals it if it was not yet signaled. All this is done in a race-free manner.h]hvChecks whether a fence was signaled and signals it if it was not yet signaled. All this is done in a race-free manner.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(h **Return**h]jr )}(hj h]hReturn}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(h9true if fence has been signaled already, false otherwise.h]h9true if fence has been signaled already, false otherwise.}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_signal (C function)c.dma_fence_signalhNtauh1jhjhhhNhNubj)}(hhh](j)}(h/void dma_fence_signal (struct dma_fence *fence)h]j)}(h.void dma_fence_signal(struct dma_fence *fence)h](jM)}(hvoidh]hvoid}(hjPhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjLhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hj_hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjLhhhj^hMubj )}(hdma_fence_signalh]j )}(hdma_fence_signalh]hdma_fence_signal}(hjqhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjmubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjLhhhj^hMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjssbc.dma_fence_signalasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjLhhhj^hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjHhhhj^hMubah}(h]jCah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj^hMhjEhhubjA )}(hhh]h)}(hsignal completion of a fenceh]hsignal completion of a fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj hhubah}(h]h ]h"]h$]h&]uh1j@ hjEhhhj^hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j(jc j(jd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to signal **Description** Signal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time.h](h)}(h**Parameters**h]jr )}(hj2h]h Parameters}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj0ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj,ubj )}(hhh]j )}(h0``struct dma_fence *fence`` the fence to signal h](j )}(h``struct dma_fence *fence``h]j)}(hjQh]hstruct dma_fence *fence}(hjShhhNhNubah}(h]h ]h"]h$]h&]uh1jhjOubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjKubj )}(hhh]h)}(hthe fence to signalh]hthe fence to signal}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjfhMhjgubah}(h]h ]h"]h$]h&]uh1j hjKubeh}(h]h ]h"]h$]h&]uh1j hjfhMhjHubah}(h]h ]h"]h$]h&]uh1j hj,ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj,ubh)}(hX:Signal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time.h]hX:Signal completion for software callbacks on a fence, this will unblock dma_fence_wait() calls and run all the callbacks added with dma_fence_add_callback(). Can be called multiple times, but since a fence can only go from the unsignaled to the signaled state and not back, it will only be effective the first time.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj,ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_fence_wait_timeout (C function)c.dma_fence_wait_timeouthNtauh1jhjhhhNhNubj)}(hhh](j)}(h\signed long dma_fence_wait_timeout (struct dma_fence *fence, bool intr, signed long timeout)h]j)}(h[signed long dma_fence_wait_timeout(struct dma_fence *fence, bool intr, signed long timeout)h](jM)}(hsignedh]hsigned}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubjM)}(hlongh]hlong}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhhjhMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(hdma_fence_wait_timeouth]j )}(hdma_fence_wait_timeouth]hdma_fence_wait_timeout}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(h9(struct dma_fence *fence, bool intr, signed long timeout)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj&ubj)}(h h]h }(hj7hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj&ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjHhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjEubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjJmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_wait_timeoutasbuh1hhj&ubj)}(h h]h }(hjhhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj&ubjd)}(hjgh]h*}(hjvhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj&ubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj&ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj"ubj)}(h bool intrh](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hintrh]hintr}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj"ubj)}(hsigned long timeouth](jM)}(hsignedh]hsigned}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjM)}(hlongh]hlong}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(htimeouth]htimeout}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj"ubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h )j? huh1jhjhM5hjxhhubjA )}(hhh]h)}(h#default release function for fencesh]h#default release function for fences}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM5hj@hhubah}(h]h ]h"]h$]h&]uh1j@ hjxhhhjhM5ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j[jc j[jd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct kref *kref`` :c:type:`dma_fence.recfount ` **Description** This is the default release functions for :c:type:`dma_fence`. Drivers shouldn't call this directly, but instead call dma_fence_put().h](h)}(h**Parameters**h]jr )}(hjeh]h Parameters}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjcubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM9hj_ubj )}(hhh]j )}(h?``struct kref *kref`` :c:type:`dma_fence.recfount ` h](j )}(h``struct kref *kref``h]j)}(hjh]hstruct kref *kref}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM6hj~ubj )}(hhh]h)}(h(:c:type:`dma_fence.recfount `h]h)}(hjh]j)}(hjh]hdma_fence.recfount}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hhjhM6hjubah}(h]h ]h"]h$]h&]uh1hhjhM6hjubah}(h]h ]h"]h$]h&]uh1j hj~ubeh}(h]h ]h"]h$]h&]uh1j hjhM6hj{ubah}(h]h ]h"]h$]h&]uh1j hj_ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM8hj_ubh)}(hThis is the default release functions for :c:type:`dma_fence`. Drivers shouldn't call this directly, but instead call dma_fence_put().h](h*This is the default release functions for }(hjhhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hjh]h dma_fence}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM7hjubhK. Drivers shouldn’t call this directly, but instead call dma_fence_put().}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhM7hj_ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_free (C function)c.dma_fence_freehNtauh1jhjhhhNhNubj)}(hhh](j)}(h-void dma_fence_free (struct dma_fence *fence)h]j)}(h,void dma_fence_free(struct dma_fence *fence)h](jM)}(hvoidh]hvoid}(hjAhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj=hhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMiubj)}(h h]h }(hjPhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj=hhhjOhMiubj )}(hdma_fence_freeh]j )}(hdma_fence_freeh]hdma_fence_free}(hjbhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj^ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj=hhhjOhMiubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj~hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjzubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjzubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjdsbc.dma_fence_freeasbuh1hhjzubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjzubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjzubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjzubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjvubah}(h]h ]h"]h$]h&]jjuh1jhj=hhhjOhMiubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj9hhhjOhMiubah}(h]j4ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjOhMihj6hhubjA )}(hhh]h)}(h1default release function for :c:type:`dma_fence`.h](hdefault release function for }(hjhhhNhNubh)}(h:c:type:`dma_fence`h]j)}(hj h]h dma_fence}(hj hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjj)}j]jc.dma_fence_freeasbj dma_fenceuh1hhjԵhKhjubh.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMihjhhubah}(h]h ]h"]h$]h&]uh1j@ hj6hhhjOhMiubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jAjc jAjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` fence to release **Description** This is the default implementation for :c:type:`dma_fence_ops.release `. It calls kfree_rcu() on **fence**.h](h)}(h**Parameters**h]jr )}(hjKh]h Parameters}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjIubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMmhjEubj )}(hhh]j )}(h-``struct dma_fence *fence`` fence to release h](j )}(h``struct dma_fence *fence``h]j)}(hjjh]hstruct dma_fence *fence}(hjlhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjhubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMjhjdubj )}(hhh]h)}(hfence to releaseh]hfence to release}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMjhjubah}(h]h ]h"]h$]h&]uh1j hjdubeh}(h]h ]h"]h$]h&]uh1j hjhMjhjaubah}(h]h ]h"]h$]h&]uh1j hjEubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMlhjEubh)}(hzThis is the default implementation for :c:type:`dma_fence_ops.release `. It calls kfree_rcu() on **fence**.h](h'This is the default implementation for }(hjhhhNhNubh)}(h/:c:type:`dma_fence_ops.release `h]j)}(hjh]hdma_fence_ops.release}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fence_opsuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMkhjubh. It calls kfree_rcu() on }(hjhhhNhNubjr )}(h **fence**h]hfence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMkhjEubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j'dma_fence_enable_signaling (C function)c.dma_fence_enable_signalinghNtauh1jhjhhhNhNubj)}(hhh](j)}(h9void dma_fence_enable_signaling (struct dma_fence *fence)h]j)}(h8void dma_fence_enable_signaling(struct dma_fence *fence)h](jM)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hj.hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhj-hMubj )}(hdma_fence_enable_signalingh]j )}(hdma_fence_enable_signalingh]hdma_fence_enable_signaling}(hj@hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj<ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhj-hMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj\hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjXubj)}(h h]h }(hjihhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjXubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjzhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjwubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj|modnameN classnameNjj)}j]jO)}jGjBsbc.dma_fence_enable_signalingasbuh1hhjXubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjXubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjXubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjXubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjTubah}(h]h ]h"]h$]h&]jjuh1jhjhhhj-hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhj-hMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj-hMhjhhubjA )}(hhh]h)}(henable signaling on fenceh]henable signaling on fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhj-hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to enable **Description** This will request for sw signaling to be enabled, to make the fence complete as soon as possible. This calls :c:type:`dma_fence_ops.enable_signaling ` internally.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]j )}(h0``struct dma_fence *fence`` the fence to enable h](j )}(h``struct dma_fence *fence``h]j)}(hj h]hstruct dma_fence *fence}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(hthe fence to enableh]hthe fence to enable}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj5hMhj6ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj5hMhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj[h]h Description}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjYubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hThis will request for sw signaling to be enabled, to make the fence complete as soon as possible. This calls :c:type:`dma_fence_ops.enable_signaling ` internally.h](hmThis will request for sw signaling to be enabled, to make the fence complete as soon as possible. This calls }(hjqhhhNhNubh)}(h8:c:type:`dma_fence_ops.enable_signaling `h]j)}(hj{h]hdma_fence_ops.enable_signaling}(hj}hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjyubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fence_opsuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjqubh internally.}(hjqhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_fence_add_callback (C function)c.dma_fence_add_callbackhNtauh1jhjhhhNhNubj)}(hhh](j)}(hdint dma_fence_add_callback (struct dma_fence *fence, struct dma_fence_cb *cb, dma_fence_func_t func)h]j)}(hcint dma_fence_add_callback(struct dma_fence *fence, struct dma_fence_cb *cb, dma_fence_func_t func)h](jM)}(hinth]hint}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(hdma_fence_add_callbackh]j )}(hdma_fence_add_callbackh]hdma_fence_add_callback}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(hI(struct dma_fence *fence, struct dma_fence_cb *cb, dma_fence_func_t func)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_add_callbackasbuh1hhjubj)}(h h]h }(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjLhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hjYhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hstruct dma_fence_cb *cbh](j)}(hjh]hstruct}(hjrhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjnubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjnubh)}(hhh]j )}(h dma_fence_cbh]h dma_fence_cb}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]j:c.dma_fence_add_callbackasbuh1hhjnubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjnubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjnubj )}(hcbh]hcb}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjnubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hdma_fence_func_t funch](h)}(hhh]j )}(hdma_fence_func_th]hdma_fence_func_t}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]j:c.dma_fence_add_callbackasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hfunch]hfunc}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h6add a callback to be called when the fence is signaledh]h6add a callback to be called when the fence is signaled}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj8hhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jSjc jSjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to wait on ``struct dma_fence_cb *cb`` the callback to register ``dma_fence_func_t func`` the function to call **Description** Add a software callback to the fence. The caller should keep a reference to the fence. **cb** will be initialized by dma_fence_add_callback(), no initialization by the caller is required. Any number of callbacks can be registered to a fence, but a callback can only be registered to one fence at a time. If fence is already signaled, this function will return -ENOENT (and *not* call the callback). Note that the callback can be called from an atomic context or irq context. Returns 0 in case of success, -ENOENT if the fence is already signaled and -EINVAL in case of error.h](h)}(h**Parameters**h]jr )}(hj]h]h Parameters}(hj_hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj[ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjWubj )}(hhh](j )}(h1``struct dma_fence *fence`` the fence to wait on h](j )}(h``struct dma_fence *fence``h]j)}(hj|h]hstruct dma_fence *fence}(hj~hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjzubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjvubj )}(hhh]h)}(hthe fence to wait onh]hthe fence to wait on}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjvubeh}(h]h ]h"]h$]h&]uh1j hjhMhjsubj )}(h5``struct dma_fence_cb *cb`` the callback to register h](j )}(h``struct dma_fence_cb *cb``h]j)}(hjh]hstruct dma_fence_cb *cb}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(hthe callback to registerh]hthe callback to register}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjsubj )}(h/``dma_fence_func_t func`` the function to call h](j )}(h``dma_fence_func_t func``h]j)}(hjh]hdma_fence_func_t func}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(hthe function to callh]hthe function to call}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjsubeh}(h]h ]h"]h$]h&]uh1j hjWubh)}(h**Description**h]jr )}(hj)h]h Description}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj'ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjWubh)}(hVAdd a software callback to the fence. The caller should keep a reference to the fence.h]hVAdd a software callback to the fence. The caller should keep a reference to the fence.}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjWubh)}(h**cb** will be initialized by dma_fence_add_callback(), no initialization by the caller is required. Any number of callbacks can be registered to a fence, but a callback can only be registered to one fence at a time.h](jr )}(h**cb**h]hcb}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjNubh will be initialized by dma_fence_add_callback(), no initialization by the caller is required. Any number of callbacks can be registered to a fence, but a callback can only be registered to one fence at a time.}(hjNhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjWubh)}(h^If fence is already signaled, this function will return -ENOENT (and *not* call the callback).h](hEIf fence is already signaled, this function will return -ENOENT (and }(hjkhhhNhNubj )}(h*not*h]hnot}(hjshhhNhNubah}(h]h ]h"]h$]h&]uh1j hjkubh call the callback).}(hjkhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjWubh)}(hKNote that the callback can be called from an atomic context or irq context.h]hKNote that the callback can be called from an atomic context or irq context.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjWubh)}(hdReturns 0 in case of success, -ENOENT if the fence is already signaled and -EINVAL in case of error.h]hdReturns 0 in case of success, -ENOENT if the fence is already signaled and -EINVAL in case of error.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjWubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j!dma_fence_get_status (C function)c.dma_fence_get_statushNtauh1jhjhhhNhNubj)}(hhh](j)}(h2int dma_fence_get_status (struct dma_fence *fence)h]j)}(h1int dma_fence_get_status(struct dma_fence *fence)h](jM)}(hinth]hint}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(hdma_fence_get_statush]j )}(hdma_fence_get_statush]hdma_fence_get_status}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj%hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj"ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj'modnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_get_statusasbuh1hhjubj)}(h h]h }(hjEhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjShhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hj`hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h"returns the status upon completionh]h"returns the status upon completion}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the dma_fence to query **Description** This wraps dma_fence_get_status_locked() to return the error status condition on a signaled fence. See dma_fence_get_status_locked() for more details. Returns 0 if the fence has not yet been signaled, 1 if the fence has been signaled without an error condition, or a negative error code if the fence has been completed in err.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]j )}(h3``struct dma_fence *fence`` the dma_fence to query h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(hthe dma_fence to queryh]hthe dma_fence to query}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hThis wraps dma_fence_get_status_locked() to return the error status condition on a signaled fence. See dma_fence_get_status_locked() for more details.h]hThis wraps dma_fence_get_status_locked() to return the error status condition on a signaled fence. See dma_fence_get_status_locked() for more details.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hReturns 0 if the fence has not yet been signaled, 1 if the fence has been signaled without an error condition, or a negative error code if the fence has been completed in err.h]hReturns 0 if the fence has not yet been signaled, 1 if the fence has been signaled without an error condition, or a negative error code if the fence has been completed in err.}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j&dma_fence_remove_callback (C function)c.dma_fence_remove_callbackhNtauh1jhjhhhNhNubj)}(hhh](j)}(hQbool dma_fence_remove_callback (struct dma_fence *fence, struct dma_fence_cb *cb)h]j)}(hPbool dma_fence_remove_callback(struct dma_fence *fence, struct dma_fence_cb *cb)h](jM)}(hji5h]hbool}(hjZhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjVhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hjhhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjVhhhjghMubj )}(hdma_fence_remove_callbackh]j )}(hdma_fence_remove_callbackh]hdma_fence_remove_callback}(hjzhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjvubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjVhhhjghMubj)}(h2(struct dma_fence *fence, struct dma_fence_cb *cb)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGj|sbc.dma_fence_remove_callbackasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hstruct dma_fence_cb *cbh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fence_cbh]h dma_fence_cb}(hj&hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj#ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj(modnameN classnameNjj)}j]jc.dma_fence_remove_callbackasbuh1hhjubj)}(h h]h }(hjDhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjRhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hcbh]hcb}(hj_hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjVhhhjghMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjRhhhjghMubah}(h]jMah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjghMhjOhhubjA )}(hhh]h)}(h)remove a callback from the signaling listh]h)remove a callback from the signaling list}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjOhhhjghMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to wait on ``struct dma_fence_cb *cb`` the callback to remove **Description** Remove a previously queued callback from the fence. This function returns true if the callback is successfully removed, or false if the fence has already been signaled. *WARNING*: Cancelling a callback should only be done if you really know what you're doing, since deadlocks and race conditions could occur all too easily. For this reason, it should only ever be done on hardware lockup recovery, with a reference held to the fence. Behaviour is undefined if **cb** has not been added to **fence** using dma_fence_add_callback() beforehand.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh](j )}(h1``struct dma_fence *fence`` the fence to wait on h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(hthe fence to wait onh]hthe fence to wait on}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubj )}(h3``struct dma_fence_cb *cb`` the callback to remove h](j )}(h``struct dma_fence_cb *cb``h]j)}(hjh]hstruct dma_fence_cb *cb}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(hthe callback to removeh]hthe callback to remove}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj>h]h Description}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj<ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hRemove a previously queued callback from the fence. This function returns true if the callback is successfully removed, or false if the fence has already been signaled.h]hRemove a previously queued callback from the fence. This function returns true if the callback is successfully removed, or false if the fence has already been signaled.}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hX*WARNING*: Cancelling a callback should only be done if you really know what you're doing, since deadlocks and race conditions could occur all too easily. For this reason, it should only ever be done on hardware lockup recovery, with a reference held to the fence.h](j )}(h *WARNING*h]hWARNING}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1j hjcubhX: Cancelling a callback should only be done if you really know what you’re doing, since deadlocks and race conditions could occur all too easily. For this reason, it should only ever be done on hardware lockup recovery, with a reference held to the fence.}(hjchhhNhNubeh}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hkBehaviour is undefined if **cb** has not been added to **fence** using dma_fence_add_callback() beforehand.h](hBehaviour is undefined if }(hjhhhNhNubjr )}(h**cb**h]hcb}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh has not been added to }(hjhhhNhNubjr )}(h **fence**h]hfence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh+ using dma_fence_add_callback() beforehand.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_fence_default_wait (C function)c.dma_fence_default_waithNtauh1jhjhhhNhNubj)}(hhh](j)}(h\signed long dma_fence_default_wait (struct dma_fence *fence, bool intr, signed long timeout)h]j)}(h[signed long dma_fence_default_wait(struct dma_fence *fence, bool intr, signed long timeout)h](jM)}(hsignedh]hsigned}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhM ubjM)}(hlongh]hlong}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhhjhM ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhM ubj )}(hdma_fence_default_waith]j )}(hdma_fence_default_waith]hdma_fence_default_wait}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhM ubj)}(h9(struct dma_fence *fence, bool intr, signed long timeout)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj(ubj)}(h h]h }(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj(ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjJhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjGubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjLmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_default_waitasbuh1hhj(ubj)}(h h]h }(hjjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj(ubjd)}(hjgh]h*}(hjxhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj(ubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj(ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj$ubj)}(h bool intrh](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hintrh]hintr}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj$ubj)}(hsigned long timeouth](jM)}(hsignedh]hsigned}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjM)}(hlongh]hlong}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(htimeouth]htimeout}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj$ubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjhM ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhM ubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhM hjhhubjA )}(hhh]h)}(hDdefault sleep until the fence gets signaled or until timeout elapsesh]hDdefault sleep until the fence gets signaled or until timeout elapses}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM hj1hhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhM ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jLjc jLjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to wait on ``bool intr`` if true, do an interruptible wait ``signed long timeout`` timeout value in jiffies, or MAX_SCHEDULE_TIMEOUT **Description** Returns -ERESTARTSYS if interrupted, 0 if the wait timed out, or the remaining timeout in jiffies on success. If timeout is zero the value one is returned if the fence is already signaled for consistency with other functions taking a jiffies timeout.h](h)}(h**Parameters**h]jr )}(hjVh]h Parameters}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjTubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM$hjPubj )}(hhh](j )}(h1``struct dma_fence *fence`` the fence to wait on h](j )}(h``struct dma_fence *fence``h]j)}(hjuh]hstruct dma_fence *fence}(hjwhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjsubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM"hjoubj )}(hhh]h)}(hthe fence to wait onh]hthe fence to wait on}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM"hjubah}(h]h ]h"]h$]h&]uh1j hjoubeh}(h]h ]h"]h$]h&]uh1j hjhM"hjlubj )}(h0``bool intr`` if true, do an interruptible wait h](j )}(h ``bool intr``h]j)}(hjh]h bool intr}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM#hjubj )}(hhh]h)}(h!if true, do an interruptible waith]h!if true, do an interruptible wait}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM#hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhM#hjlubj )}(hJ``signed long timeout`` timeout value in jiffies, or MAX_SCHEDULE_TIMEOUT h](j )}(h``signed long timeout``h]j)}(hjh]hsigned long timeout}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM$hjubj )}(hhh]h)}(h1timeout value in jiffies, or MAX_SCHEDULE_TIMEOUTh]h1timeout value in jiffies, or MAX_SCHEDULE_TIMEOUT}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM$hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhM$hjlubeh}(h]h ]h"]h$]h&]uh1j hjPubh)}(h**Description**h]jr )}(hj"h]h Description}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM&hjPubh)}(hReturns -ERESTARTSYS if interrupted, 0 if the wait timed out, or the remaining timeout in jiffies on success. If timeout is zero the value one is returned if the fence is already signaled for consistency with other functions taking a jiffies timeout.h]hReturns -ERESTARTSYS if interrupted, 0 if the wait timed out, or the remaining timeout in jiffies on success. If timeout is zero the value one is returned if the fence is already signaled for consistency with other functions taking a jiffies timeout.}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM%hjPubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j'dma_fence_wait_any_timeout (C function)c.dma_fence_wait_any_timeouthNtauh1jhjhhhNhNubj)}(hhh](j)}(hsigned long dma_fence_wait_any_timeout (struct dma_fence **fences, uint32_t count, bool intr, signed long timeout, uint32_t *idx)h]j)}(hsigned long dma_fence_wait_any_timeout(struct dma_fence **fences, uint32_t count, bool intr, signed long timeout, uint32_t *idx)h](jM)}(hsignedh]hsigned}(hjghhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjchhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMoubj)}(h h]h }(hjvhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjchhhjuhMoubjM)}(hlongh]hlong}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjchhhjuhMoubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjchhhjuhMoubj )}(hdma_fence_wait_any_timeouth]j )}(hdma_fence_wait_any_timeouth]hdma_fence_wait_any_timeout}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjchhhjuhMoubj)}(hZ(struct dma_fence **fences, uint32_t count, bool intr, signed long timeout, uint32_t *idx)h](j)}(hstruct dma_fence **fencesh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_wait_any_timeoutasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfencesh]hfences}(hj&hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(huint32_t counth](h)}(hhh]j )}(huint32_th]huint32_t}(hjBhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj?ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjDmodnameN classnameNjj)}j]jc.dma_fence_wait_any_timeoutasbuh1hhj;ubj)}(h h]h }(hj`hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj;ubj )}(hcounth]hcount}(hjnhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj;ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h bool intrh](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hintrh]hintr}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hsigned long timeouth](jM)}(hsignedh]hsigned}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjM)}(hlongh]hlong}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(htimeouth]htimeout}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h uint32_t *idxh](h)}(hhh]j )}(huint32_th]huint32_t}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_fence_wait_any_timeoutasbuh1hhjubj)}(h h]h }(hj-hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj;hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hidxh]hidx}(hjHhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjchhhjuhMoubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj_hhhjuhMoubah}(h]jZah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjuhMohj\hhubjA )}(hhh]h)}(hhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj:hMshj;ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj:hMshjubj )}(hJ``signed long timeout`` timeout value in jiffies, or MAX_SCHEDULE_TIMEOUT h](j )}(h``signed long timeout``h]j)}(hj^h]hsigned long timeout}(hj`hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj\ubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMthjXubj )}(hhh]h)}(h1timeout value in jiffies, or MAX_SCHEDULE_TIMEOUTh]h1timeout value in jiffies, or MAX_SCHEDULE_TIMEOUT}(hjwhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjshMthjtubah}(h]h ]h"]h$]h&]uh1j hjXubeh}(h]h ]h"]h$]h&]uh1j hjshMthjubj )}(hc``uint32_t *idx`` used to store the first signaled fence index, meaningful only on positive return h](j )}(h``uint32_t *idx``h]j)}(hjh]h uint32_t *idx}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMvhjubj )}(hhh]h)}(hPused to store the first signaled fence index, meaningful only on positive returnh]hPused to store the first signaled fence index, meaningful only on positive return}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMuhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMvhjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMxhjubh)}(hReturns -EINVAL on custom fence wait implementation, -ERESTARTSYS if interrupted, 0 if the wait timed out, or the remaining timeout in jiffies on success.h]hReturns -EINVAL on custom fence wait implementation, -ERESTARTSYS if interrupted, 0 if the wait timed out, or the remaining timeout in jiffies on success.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMwhjubh)}(hSynchronous waits for the first fence in the array to be signaled. The caller needs to hold a reference to all fences in the array, otherwise a fence might be freed before return, resulting in undefined behavior.h]hSynchronous waits for the first fence in the array to be signaled. The caller needs to hold a reference to all fences in the array, otherwise a fence might be freed before return, resulting in undefined behavior.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM{hjubh)}(h7See also dma_fence_wait() and dma_fence_wait_timeout().h]h7See also dma_fence_wait() and dma_fence_wait_timeout().}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_fence_set_deadline (C function)c.dma_fence_set_deadlinehNtauh1jhjhhhNhNubj)}(hhh](j)}(hGvoid dma_fence_set_deadline (struct dma_fence *fence, ktime_t deadline)h]j)}(hFvoid dma_fence_set_deadline(struct dma_fence *fence, ktime_t deadline)h](jM)}(hvoidh]hvoid}(hj6hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj2hhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hjEhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj2hhhjDhMubj )}(hdma_fence_set_deadlineh]j )}(hdma_fence_set_deadlineh]hdma_fence_set_deadline}(hjWhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjSubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj2hhhjDhMubj)}(h+(struct dma_fence *fence, ktime_t deadline)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjshhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjoubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjoubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjYsbc.dma_fence_set_deadlineasbuh1hhjoubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjoubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjoubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjoubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjkubj)}(hktime_t deadlineh](h)}(hhh]j )}(hktime_th]hktime_t}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_fence_set_deadlineasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hdeadlineh]hdeadline}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjkubeh}(h]h ]h"]h$]h&]jjuh1jhj2hhhjDhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj.hhhjDhMubah}(h]j)ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjDhMhj+hhubjA )}(hhh]h)}(h$set desired fence-wait deadline hinth]h$set desired fence-wait deadline hint}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj;hhubah}(h]h ]h"]h$]h&]uh1j@ hj+hhhjDhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jVjc jVjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence that is to be waited on ``ktime_t deadline`` the time by which the waiter hopes for the fence to be signaled **Description** Give the fence signaler a hint about an upcoming deadline, such as vblank, by which point the waiter would prefer the fence to be signaled by. This is intended to give feedback to the fence signaler to aid in power management decisions, such as boosting GPU frequency if a periodic vblank deadline is approaching but the fence is not yet signaled..h](h)}(h**Parameters**h]jr )}(hj`h]h Parameters}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj^ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjZubj )}(hhh](j )}(h>``struct dma_fence *fence`` the fence that is to be waited on h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj}ubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjyubj )}(hhh]h)}(h!the fence that is to be waited onh]h!the fence that is to be waited on}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjyubeh}(h]h ]h"]h$]h&]uh1j hjhMhjvubj )}(hU``ktime_t deadline`` the time by which the waiter hopes for the fence to be signaled h](j )}(h``ktime_t deadline``h]j)}(hjh]hktime_t deadline}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]h)}(h?the time by which the waiter hopes for the fence to be signaledh]h?the time by which the waiter hopes for the fence to be signaled}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjvubeh}(h]h ]h"]h$]h&]uh1j hjZubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjZubh)}(hX]Give the fence signaler a hint about an upcoming deadline, such as vblank, by which point the waiter would prefer the fence to be signaled by. This is intended to give feedback to the fence signaler to aid in power management decisions, such as boosting GPU frequency if a periodic vblank deadline is approaching but the fence is not yet signaled..h]hX]Give the fence signaler a hint about an upcoming deadline, such as vblank, by which point the waiter would prefer the fence to be signaled by. This is intended to give feedback to the fence signaler to aid in power management decisions, such as boosting GPU frequency if a periodic vblank deadline is approaching but the fence is not yet signaled..}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjZubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_describe (C function)c.dma_fence_describehNtauh1jhjhhhNhNubj)}(hhh](j)}(hGvoid dma_fence_describe (struct dma_fence *fence, struct seq_file *seq)h]j)}(hFvoid dma_fence_describe(struct dma_fence *fence, struct seq_file *seq)h](jM)}(hvoidh]hvoid}(hj9hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj5hhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM ubj)}(h h]h }(hjHhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj5hhhjGhM ubj )}(hdma_fence_describeh]j )}(hdma_fence_describeh]hdma_fence_describe}(hjZhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjVubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj5hhhjGhM ubj)}(h/(struct dma_fence *fence, struct seq_file *seq)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjvhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjrubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjrubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGj\sbc.dma_fence_describeasbuh1hhjrubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjrubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjrubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjrubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjnubj)}(hstruct seq_file *seqh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hseq_fileh]hseq_file}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_fence_describeasbuh1hhjubj)}(h h]h }(hj$hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj2hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hseqh]hseq}(hj?hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjnubeh}(h]h ]h"]h$]h&]jjuh1jhj5hhhjGhM ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj1hhhjGhM ubah}(h]j,ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjGhM hj.hhubjA )}(hhh]h)}(h$Dump fence description into seq_fileh]h$Dump fence description into seq_file}(hjihhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM hjfhhubah}(h]h ]h"]h$]h&]uh1j@ hj.hhhjGhM ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` the fence to describe ``struct seq_file *seq`` the seq_file to put the textual description into **Description** Dump a textual description of the fence and it's state into the seq_file.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM hjubj )}(hhh](j )}(h2``struct dma_fence *fence`` the fence to describe h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM hjubj )}(hhh]h)}(hthe fence to describeh]hthe fence to describe}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhM hjubj )}(hJ``struct seq_file *seq`` the seq_file to put the textual description into h](j )}(h``struct seq_file *seq``h]j)}(hjh]hstruct seq_file *seq}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM hjubj )}(hhh]h)}(h0the seq_file to put the textual description intoh]h0the seq_file to put the textual description into}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhM hjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM hjubh)}(hIDump a textual description of the fence and it's state into the seq_file.h]hKDump a textual description of the fence and it’s state into the seq_file.}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_init (C function)c.dma_fence_inithNtauh1jhjhhhNhNubj)}(hhh](j)}(hxvoid dma_fence_init (struct dma_fence *fence, const struct dma_fence_ops *ops, spinlock_t *lock, u64 context, u64 seqno)h]j)}(hwvoid dma_fence_init(struct dma_fence *fence, const struct dma_fence_ops *ops, spinlock_t *lock, u64 context, u64 seqno)h](jM)}(hvoidh]hvoid}(hjchhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj_hhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMCubj)}(h h]h }(hjrhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj_hhhjqhMCubj )}(hdma_fence_inith]j )}(hdma_fence_inith]hdma_fence_init}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj_hhhjqhMCubj)}(hd(struct dma_fence *fence, const struct dma_fence_ops *ops, spinlock_t *lock, u64 context, u64 seqno)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_initasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hconst struct dma_fence_ops *opsh](j)}(hjh]hconst}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj)}(hjh]hstruct}(hj-hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj:hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fence_opsh]h dma_fence_ops}(hjKhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjHubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjMmodnameN classnameNjj)}j]jc.dma_fence_initasbuh1hhjubj)}(h h]h }(hjihhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjwhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hopsh]hops}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hspinlock_t *lockh](h)}(hhh]j )}(h spinlock_th]h spinlock_t}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_fence_initasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hlockh]hlock}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h u64 contexth](h)}(hhh]j )}(hu64h]hu64}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_fence_initasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(hcontexth]hcontext}(hj!hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h u64 seqnoh](h)}(hhh]j )}(hu64h]hu64}(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj:ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj?modnameN classnameNjj)}j]jc.dma_fence_initasbuh1hhj6ubj)}(h h]h }(hj[hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj6ubj )}(hseqnoh]hseqno}(hjihhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj6ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhj_hhhjqhMCubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj[hhhjqhMCubah}(h]jVah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjqhMChjXhhubjA )}(hhh]h)}(hInitialize a custom fence.h]hInitialize a custom fence.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMChjhhubah}(h]h ]h"]h$]h&]uh1j@ hjXhhhjqhMCubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to initialize ``const struct dma_fence_ops *ops`` the dma_fence_ops for operations on this fence ``spinlock_t *lock`` optional irqsafe spinlock to use for locking this fence ``u64 context`` the execution context this fence is run on ``u64 seqno`` a linear increasing sequence number for this context **Description** Initializes an allocated fence, the caller doesn't have to keep its refcount after committing with this fence, but it will need to hold a refcount again if :c:type:`dma_fence_ops.enable_signaling ` gets called. context and seqno are used for easy comparison between fences, allowing to check which fence is later by simply using dma_fence_later(). External locks are a relic of legacy use cases that needed a shared lock to serialize signaling when no out-of-order signaling was possible through :c:type:`dma_fence_ops.signaled `. Drivers have abandoned this concept since the introduction of the callback, but the external lock is still around. New users MUST NOT use external locks, as they force the issuer to outlive all fences that reference the lock.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMGhjubj )}(hhh](j )}(h4``struct dma_fence *fence`` the fence to initialize h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMDhjubj )}(hhh]h)}(hthe fence to initializeh]hthe fence to initialize}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMDhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMDhjubj )}(hS``const struct dma_fence_ops *ops`` the dma_fence_ops for operations on this fence h](j )}(h#``const struct dma_fence_ops *ops``h]j)}(hj h]hconst struct dma_fence_ops *ops}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMEhjubj )}(hhh]h)}(h.the dma_fence_ops for operations on this fenceh]h.the dma_fence_ops for operations on this fence}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj"hMEhj#ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj"hMEhjubj )}(hM``spinlock_t *lock`` optional irqsafe spinlock to use for locking this fence h](j )}(h``spinlock_t *lock``h]j)}(hjFh]hspinlock_t *lock}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjDubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMFhj@ubj )}(hhh]h)}(h7optional irqsafe spinlock to use for locking this fenceh]h7optional irqsafe spinlock to use for locking this fence}(hj_hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj[hMFhj\ubah}(h]h ]h"]h$]h&]uh1j hj@ubeh}(h]h ]h"]h$]h&]uh1j hj[hMFhjubj )}(h;``u64 context`` the execution context this fence is run on h](j )}(h``u64 context``h]j)}(hjh]h u64 context}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj}ubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMGhjyubj )}(hhh]h)}(h*the execution context this fence is run onh]h*the execution context this fence is run on}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMGhjubah}(h]h ]h"]h$]h&]uh1j hjyubeh}(h]h ]h"]h$]h&]uh1j hjhMGhjubj )}(hC``u64 seqno`` a linear increasing sequence number for this context h](j )}(h ``u64 seqno``h]j)}(hjh]h u64 seqno}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMHhjubj )}(hhh]h)}(h4a linear increasing sequence number for this contexth]h4a linear increasing sequence number for this context}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMHhjubah}(h]h ]h"]h$]h&]uh1j hjubeyh}(h]h ]h"]h$]h&]uh1j hjhMHhjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMJhjubh)}(hInitializes an allocated fence, the caller doesn't have to keep its refcount after committing with this fence, but it will need to hold a refcount again if :c:type:`dma_fence_ops.enable_signaling ` gets called.h](hInitializes an allocated fence, the caller doesn’t have to keep its refcount after committing with this fence, but it will need to hold a refcount again if }(hj hhhNhNubh)}(h8:c:type:`dma_fence_ops.enable_signaling `h]j)}(hjh]hdma_fence_ops.enable_signaling}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fence_opsuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMIhj ubh gets called.}(hj hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj0hMIhjubh)}(hcontext and seqno are used for easy comparison between fences, allowing to check which fence is later by simply using dma_fence_later().h]hcontext and seqno are used for easy comparison between fences, allowing to check which fence is later by simply using dma_fence_later().}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMMhjubh)}(hXExternal locks are a relic of legacy use cases that needed a shared lock to serialize signaling when no out-of-order signaling was possible through :c:type:`dma_fence_ops.signaled `. Drivers have abandoned this concept since the introduction of the callback, but the external lock is still around. New users MUST NOT use external locks, as they force the issuer to outlive all fences that reference the lock.h](hExternal locks are a relic of legacy use cases that needed a shared lock to serialize signaling when no out-of-order signaling was possible through }(hjJhhhNhNubh)}(h0:c:type:`dma_fence_ops.signaled `h]j)}(hjTh]hdma_fence_ops.signaled}(hjVhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjRubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fence_opsuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMPhjJubh. Drivers have abandoned this concept since the introduction of the callback, but the external lock is still around. New users MUST NOT use external locks, as they force the issuer to outlive all fences that reference the lock.}(hjJhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjqhMPhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_init64 (C function)c.dma_fence_init64hNtauh1jhjhhhNhNubj)}(hhh](j)}(hzvoid dma_fence_init64 (struct dma_fence *fence, const struct dma_fence_ops *ops, spinlock_t *lock, u64 context, u64 seqno)h]j)}(hyvoid dma_fence_init64(struct dma_fence *fence, const struct dma_fence_ops *ops, spinlock_t *lock, u64 context, u64 seqno)h](jM)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMaubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMaubj )}(hdma_fence_init64h]j )}(hdma_fence_init64h]hdma_fence_init64}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMaubj)}(hd(struct dma_fence *fence, const struct dma_fence_ops *ops, spinlock_t *lock, u64 context, u64 seqno)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_init64asbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj%hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hj2hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hconst struct dma_fence_ops *opsh](j)}(hjh]hconst}(hjKhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjGubj)}(h h]h }(hjXhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjGubj)}(hjh]hstruct}(hjfhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjGubj)}(h h]h }(hjshhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjGubh)}(hhh]j )}(h dma_fence_opsh]h dma_fence_ops}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_fence_init64asbuh1hhjGubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjGubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjGubj )}(hopsh]hops}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjGubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hspinlock_t *lockh](h)}(hhh]j )}(h spinlock_th]h spinlock_t}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_fence_init64asbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hlockh]hlock}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h u64 contexth](h)}(hhh]j )}(hu64h]hu64}(hj.hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj+ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj0modnameN classnameNjj)}j]jc.dma_fence_init64asbuh1hhj'ubj)}(h h]h }(hjLhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj'ubj )}(hcontexth]hcontext}(hjZhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj'ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h u64 seqnoh](h)}(hhh]j )}(hu64h]hu64}(hjvhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjsubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjxmodnameN classnameNjj)}j]jc.dma_fence_init64asbuh1hhjoubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjoubj )}(hseqnoh]hseqno}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjoubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMaubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMaubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMahjhhubjA )}(hhh]h)}(h4Initialize a custom fence with 64-bit seqno support.h]h4Initialize a custom fence with 64-bit seqno support.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMahjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMaubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hXx**Parameters** ``struct dma_fence *fence`` the fence to initialize ``const struct dma_fence_ops *ops`` the dma_fence_ops for operations on this fence ``spinlock_t *lock`` optional irqsafe spinlock to use for locking this fence ``u64 context`` the execution context this fence is run on ``u64 seqno`` a linear increasing sequence number for this context **Description** Initializes an allocated fence, the caller doesn't have to keep its refcount after committing with this fence, but it will need to hold a refcount again if :c:type:`dma_fence_ops.enable_signaling ` gets called. Context and seqno are used for easy comparison between fences, allowing to check which fence is later by simply using dma_fence_later(). New users MUST NOT use external locks. Check the documentation in dma_fence_init() to understand the motives behind the legacy use cases.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMehjubj )}(hhh](j )}(h4``struct dma_fence *fence`` the fence to initialize h](j )}(h``struct dma_fence *fence``h]j)}(hj h]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMbhjubj )}(hhh]h)}(hthe fence to initializeh]hthe fence to initialize}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj"hMbhj#ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj"hMbhjubj )}(hS``const struct dma_fence_ops *ops`` the dma_fence_ops for operations on this fence h](j )}(h#``const struct dma_fence_ops *ops``h]j)}(hjFh]hconst struct dma_fence_ops *ops}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjDubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMchj@ubj )}(hhh]h)}(h.the dma_fence_ops for operations on this fenceh]h.the dma_fence_ops for operations on this fence}(hj_hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj[hMchj\ubah}(h]h ]h"]h$]h&]uh1j hj@ubeh}(h]h ]h"]h$]h&]uh1j hj[hMchjubj )}(hM``spinlock_t *lock`` optional irqsafe spinlock to use for locking this fence h](j )}(h``spinlock_t *lock``h]j)}(hjh]hspinlock_t *lock}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj}ubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMdhjyubj )}(hhh]h)}(h7optional irqsafe spinlock to use for locking this fenceh]h7optional irqsafe spinlock to use for locking this fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMdhjubah}(h]h ]h"]h$]h&]uh1j hjyubeh}(h]h ]h"]h$]h&]uh1j hjhMdhjubj )}(h;``u64 context`` the execution context this fence is run on h](j )}(h``u64 context``h]j)}(hjh]h u64 context}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMehjubj )}(hhh]h)}(h*the execution context this fence is run onh]h*the execution context this fence is run on}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMehjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMehjubj )}(hC``u64 seqno`` a linear increasing sequence number for this context h](j )}(h ``u64 seqno``h]j)}(hjh]h u64 seqno}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMfhjubj )}(hhh]h)}(h4a linear increasing sequence number for this contexth]h4a linear increasing sequence number for this context}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMfhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMfhjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj,h]h Description}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj*ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhhjubh)}(hInitializes an allocated fence, the caller doesn't have to keep its refcount after committing with this fence, but it will need to hold a refcount again if :c:type:`dma_fence_ops.enable_signaling ` gets called.h](hInitializes an allocated fence, the caller doesn’t have to keep its refcount after committing with this fence, but it will need to hold a refcount again if }(hjBhhhNhNubh)}(h8:c:type:`dma_fence_ops.enable_signaling `h]j)}(hjLh]hdma_fence_ops.enable_signaling}(hjNhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjJubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fence_opsuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMghjBubh gets called.}(hjBhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjihMghjubh)}(hContext and seqno are used for easy comparison between fences, allowing to check which fence is later by simply using dma_fence_later().h]hContext and seqno are used for easy comparison between fences, allowing to check which fence is later by simply using dma_fence_later().}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMkhjubh)}(hNew users MUST NOT use external locks. Check the documentation in dma_fence_init() to understand the motives behind the legacy use cases.h]hNew users MUST NOT use external locks. Check the documentation in dma_fence_init() to understand the motives behind the legacy use cases.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMnhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j"dma_fence_driver_name (C function)c.dma_fence_driver_namehNtauh1jhjhhhNhNubj)}(hhh](j)}(hBconst char __rcu * dma_fence_driver_name (struct dma_fence *fence)h]j)}(h@const char __rcu *dma_fence_driver_name(struct dma_fence *fence)h](j)}(hjh]hconst}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM|ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhM|ubjM)}(hcharh]hchar}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhhjhM|ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhM|ubh__rcu}(hjhhhNhNubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhM|ubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjhhhjhM|ubj )}(hdma_fence_driver_nameh]j )}(hdma_fence_driver_nameh]hdma_fence_driver_name}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhM|ubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj)hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj%ubj)}(h h]h }(hj6hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj%ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjDubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjImodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_driver_nameasbuh1hhj%ubj)}(h h]h }(hjghhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj%ubjd)}(hjgh]h*}(hjuhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj%ubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj%ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj!ubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhM|ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhM|ubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhM|hjhhubjA )}(hhh]h)}(hAccess the driver nameh]hAccess the driver name}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM|hjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhM|ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hXh**Parameters** ``struct dma_fence *fence`` the fence to query **Description** Returns a driver name backing the dma-fence implementation. IMPORTANT CONSIDERATION: Dma-fence contract stipulates that access to driver provided data (data not directly embedded into the object itself), such as the :c:type:`dma_fence.lock ` and memory potentially accessed by the :c:type:`dma_fence.ops ` functions, is forbidden after the fence has been signalled. Drivers are allowed to free that data, and some do. To allow safe access drivers are mandated to guarantee a RCU grace period between signalling the fence and freeing said data. As such access to the driver name is only valid inside a RCU locked section. The pointer MUST be both queried and USED ONLY WITHIN a SINGLE block guarded by the :c:type:`rcu_read_lock` and :c:type:`rcu_read_unlock` pair.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubj )}(hhh]j )}(h/``struct dma_fence *fence`` the fence to query h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM}hjubj )}(hhh]h)}(hthe fence to queryh]hthe fence to query}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhM}hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhM}hjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj(h]h Description}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj&ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(h;Returns a driver name backing the dma-fence implementation.h]h;Returns a driver name backing the dma-fence implementation.}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chM~hjubh)}(hX{IMPORTANT CONSIDERATION: Dma-fence contract stipulates that access to driver provided data (data not directly embedded into the object itself), such as the :c:type:`dma_fence.lock ` and memory potentially accessed by the :c:type:`dma_fence.ops ` functions, is forbidden after the fence has been signalled. Drivers are allowed to free that data, and some do.h](hIMPORTANT CONSIDERATION: Dma-fence contract stipulates that access to driver provided data (data not directly embedded into the object itself), such as the }(hjMhhhNhNubh)}(h$:c:type:`dma_fence.lock `h]j)}(hjWh]hdma_fence.lock}(hjYhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjUubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjMubh( and memory potentially accessed by the }(hjMhhhNhNubh)}(h#:c:type:`dma_fence.ops `h]j)}(hj{h]h dma_fence.ops}(hj}hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjyubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hhjthMhjMubhp functions, is forbidden after the fence has been signalled. Drivers are allowed to free that data, and some do.}(hjMhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjthMhjubh)}(h}To allow safe access drivers are mandated to guarantee a RCU grace period between signalling the fence and freeing said data.h]h}To allow safe access drivers are mandated to guarantee a RCU grace period between signalling the fence and freeing said data.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh)}(hAs such access to the driver name is only valid inside a RCU locked section. The pointer MUST be both queried and USED ONLY WITHIN a SINGLE block guarded by the :c:type:`rcu_read_lock` and :c:type:`rcu_read_unlock` pair.h](hAs such access to the driver name is only valid inside a RCU locked section. The pointer MUST be both queried and USED ONLY WITHIN a SINGLE block guarded by the }(hjhhhNhNubh)}(h:c:type:`rcu_read_lock`h]j)}(hjh]h rcu_read_lock}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj rcu_read_lockuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh and }(hjhhhNhNubh)}(h:c:type:`rcu_read_unlock`h]j)}(hjh]hrcu_read_unlock}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjrcu_read_unlockuh1hhjhMhjubh pair.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j$dma_fence_timeline_name (C function)c.dma_fence_timeline_namehNtauh1jhjhhhNhNubj)}(hhh](j)}(hDconst char __rcu * dma_fence_timeline_name (struct dma_fence *fence)h]j)}(hBconst char __rcu *dma_fence_timeline_name(struct dma_fence *fence)h](j)}(hjh]hconst}(hj&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj"hhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMubj)}(h h]h }(hj4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj"hhhj3hMubjM)}(hcharh]hchar}(hjBhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj"hhhj3hMubj)}(h h]h }(hjPhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj"hhhj3hMubh__rcu}(hj"hhhNhNubj)}(h h]h }(hjbhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj"hhhj3hMubjd)}(hjgh]h*}(hjphhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj"hhhj3hMubj )}(hdma_fence_timeline_nameh]j )}(hdma_fence_timeline_nameh]hdma_fence_timeline_name}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj}ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj"hhhj3hMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_timeline_nameasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhj"hhhj3hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhj3hMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj3hMhjhhubjA )}(hhh]h)}(hAccess the timeline nameh]hAccess the timeline name}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhj3hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j8jc j8jd je jf uh1jhhhjhNhNubjh )}(hXn**Parameters** ``struct dma_fence *fence`` the fence to query **Description** Returns a timeline name provided by the dma-fence implementation. IMPORTANT CONSIDERATION: Dma-fence contract stipulates that access to driver provided data (data not directly embedded into the object itself), such as the :c:type:`dma_fence.lock ` and memory potentially accessed by the :c:type:`dma_fence.ops ` functions, is forbidden after the fence has been signalled. Drivers are allowed to free that data, and some do. To allow safe access drivers are mandated to guarantee a RCU grace period between signalling the fence and freeing said data. As such access to the driver name is only valid inside a RCU locked section. The pointer MUST be both queried and USED ONLY WITHIN a SINGLE block guarded by the :c:type:`rcu_read_lock` and :c:type:`rcu_read_unlock` pair.h](h)}(h**Parameters**h]jr )}(hjBh]h Parameters}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj@ubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj<ubj )}(hhh]j )}(h/``struct dma_fence *fence`` the fence to query h](j )}(h``struct dma_fence *fence``h]j)}(hjah]hstruct dma_fence *fence}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1jhj_ubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj[ubj )}(hhh]h)}(hthe fence to queryh]hthe fence to query}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjvhMhjwubah}(h]h ]h"]h$]h&]uh1j hj[ubeh}(h]h ]h"]h$]h&]uh1j hjvhMhjXubah}(h]h ]h"]h$]h&]uh1j hj<ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj<ubh)}(hAReturns a timeline name provided by the dma-fence implementation.h]hAReturns a timeline name provided by the dma-fence implementation.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj<ubh)}(hX{IMPORTANT CONSIDERATION: Dma-fence contract stipulates that access to driver provided data (data not directly embedded into the object itself), such as the :c:type:`dma_fence.lock ` and memory potentially accessed by the :c:type:`dma_fence.ops ` functions, is forbidden after the fence has been signalled. Drivers are allowed to free that data, and some do.h](hIMPORTANT CONSIDERATION: Dma-fence contract stipulates that access to driver provided data (data not directly embedded into the object itself), such as the }(hjhhhNhNubh)}(h$:c:type:`dma_fence.lock `h]j)}(hjh]hdma_fence.lock}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhjubh( and memory potentially accessed by the }(hjhhhNhNubh)}(h#:c:type:`dma_fence.ops `h]j)}(hjh]h dma_fence.ops}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hhjhMhjubhp functions, is forbidden after the fence has been signalled. Drivers are allowed to free that data, and some do.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMhj<ubh)}(h}To allow safe access drivers are mandated to guarantee a RCU grace period between signalling the fence and freeing said data.h]h}To allow safe access drivers are mandated to guarantee a RCU grace period between signalling the fence and freeing said data.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj<ubh)}(hAs such access to the driver name is only valid inside a RCU locked section. The pointer MUST be both queried and USED ONLY WITHIN a SINGLE block guarded by the :c:type:`rcu_read_lock` and :c:type:`rcu_read_unlock` pair.h](hAs such access to the driver name is only valid inside a RCU locked section. The pointer MUST be both queried and USED ONLY WITHIN a SINGLE block guarded by the }(hj%hhhNhNubh)}(h:c:type:`rcu_read_lock`h]j)}(hj/h]h rcu_read_lock}(hj1hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj-ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj rcu_read_lockuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:187: ./drivers/dma-buf/dma-fence.chMhj%ubh and }(hj%hhhNhNubh)}(h:c:type:`rcu_read_unlock`h]j)}(hjSh]hrcu_read_unlock}(hjUhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjQubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjrcu_read_unlockuh1hhjLhMhj%ubh pair.}(hj%hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjLhMhj<ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence (C struct) c.dma_fencehNtauh1jhjhhhNhNubj)}(hhh](j)}(h dma_fenceh]j)}(hstruct dma_fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhKubj )}(h dma_fenceh]j )}(hjh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhKubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhKhjhhubjA )}(hhh]h)}(h"software synchronization primitiveh]h"software synchronization primitive}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK hjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhKubeh}(h]h ](jstructeh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Definition**:: struct dma_fence { union { spinlock_t *extern_lock; spinlock_t inline_lock; }; const struct dma_fence_ops *ops; union { struct list_head cb_list; ktime_t timestamp; struct rcu_head rcu; }; u64 context; u64 seqno; unsigned long flags; struct kref refcount; int error; }; **Members** ``{unnamed_union}`` anonymous ``extern_lock`` external spin_lock_irqsave used for locking (deprecated) ``inline_lock`` alternative internal spin_lock_irqsave used for locking ``ops`` dma_fence_ops associated with this fence ``{unnamed_union}`` anonymous ``cb_list`` list of all callbacks to call ``timestamp`` Timestamp when the fence was signaled. ``rcu`` used for releasing fence with kfree_rcu ``context`` execution context this fence belongs to, returned by dma_fence_context_alloc() ``seqno`` the sequence number of this fence inside the execution context, can be compared to decide which fence would be signaled later. ``flags`` A mask of DMA_FENCE_FLAG_* defined below ``refcount`` refcount for this fence ``error`` Optional, only valid if < 0, must be set before calling dma_fence_signal, indicates that the fence has completed with an error.h](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK$hjubj)}(hX]struct dma_fence { union { spinlock_t *extern_lock; spinlock_t inline_lock; }; const struct dma_fence_ops *ops; union { struct list_head cb_list; ktime_t timestamp; struct rcu_head rcu; }; u64 context; u64 seqno; unsigned long flags; struct kref refcount; int error; };h]hX]struct dma_fence { union { spinlock_t *extern_lock; spinlock_t inline_lock; }; const struct dma_fence_ops *ops; union { struct list_head cb_list; ktime_t timestamp; struct rcu_head rcu; }; u64 context; u64 seqno; unsigned long flags; struct kref refcount; int error; };}hjsbah}(h]h ]h"]h$]h&]jjuh1jh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK&hjubh)}(h **Members**h]jr )}(hj*h]hMembers}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj(ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK8hjubj )}(hhh](j )}(h``{unnamed_union}`` anonymous h](j )}(h``{unnamed_union}``h]j)}(hjIh]h{unnamed_union}}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjGubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjCubj )}(hhh]h)}(h anonymoush]h anonymous}(hjbhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj^hKhj_ubah}(h]h ]h"]h$]h&]uh1j hjCubeh}(h]h ]h"]h$]h&]uh1j hj^hKhj@ubj )}(hI``extern_lock`` external spin_lock_irqsave used for locking (deprecated) h](j )}(h``extern_lock``h]j)}(hjh]h extern_lock}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK&hj|ubj )}(hhh]h)}(h8external spin_lock_irqsave used for locking (deprecated)h]h8external spin_lock_irqsave used for locking (deprecated)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhK&hjubah}(h]h ]h"]h$]h&]uh1j hj|ubeh}(h]h ]h"]h$]h&]uh1j hjhK&hj@ubj )}(hH``inline_lock`` alternative internal spin_lock_irqsave used for locking h](j )}(h``inline_lock``h]j)}(hjh]h inline_lock}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK'hjubj )}(hhh]h)}(h7alternative internal spin_lock_irqsave used for lockingh]h7alternative internal spin_lock_irqsave used for locking}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhK'hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhK'hj@ubj )}(h1``ops`` dma_fence_ops associated with this fence h](j )}(h``ops``h]j)}(hjh]hops}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK#hjubj )}(hhh]h)}(h(dma_fence_ops associated with this fenceh]h(dma_fence_ops associated with this fence}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hK#hj ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj hK#hj@ubj )}(h``{unnamed_union}`` anonymous h](j )}(h``{unnamed_union}``h]j)}(hj-h]h{unnamed_union}}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj+ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhj'ubj )}(hhh]h)}(h anonymoush]h anonymous}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjBhKhjCubah}(h]h ]h"]h$]h&]uh1j hj'ubeh}(h]h ]h"]h$]h&]uh1j hjBhKhj@ubj )}(h*``cb_list`` list of all callbacks to call h](j )}(h ``cb_list``h]j)}(hjfh]hcb_list}(hjhhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjdubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK%hj`ubj )}(hhh]h)}(hlist of all callbacks to callh]hlist of all callbacks to call}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj{hK%hj|ubah}(h]h ]h"]h$]h&]uh1j hj`ubeh}(h]h ]h"]h$]h&]uh1j hj{hK%hj@ubj )}(h5``timestamp`` Timestamp when the fence was signaled. h](j )}(h ``timestamp``h]j)}(hjh]h timestamp}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK-hjubj )}(hhh]h)}(h&Timestamp when the fence was signaled.h]h&Timestamp when the fence was signaled.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhK-hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhK-hj@ubj )}(h0``rcu`` used for releasing fence with kfree_rcu h](j )}(h``rcu``h]j)}(hjh]hrcu}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK$hjubj )}(hhh]h)}(h'used for releasing fence with kfree_rcuh]h'used for releasing fence with kfree_rcu}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhK$hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhK$hj@ubj )}(h[``context`` execution context this fence belongs to, returned by dma_fence_context_alloc() h](j )}(h ``context``h]j)}(hjh]hcontext}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK)hj ubj )}(hhh]h)}(hNexecution context this fence belongs to, returned by dma_fence_context_alloc()h]hNexecution context this fence belongs to, returned by dma_fence_context_alloc()}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK(hj'ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj&hK)hj@ubj )}(h``seqno`` the sequence number of this fence inside the execution context, can be compared to decide which fence would be signaled later. h](j )}(h ``seqno``h]j)}(hjKh]hseqno}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjIubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK+hjEubj )}(hhh]h)}(h~the sequence number of this fence inside the execution context, can be compared to decide which fence would be signaled later.h]h~the sequence number of this fence inside the execution context, can be compared to decide which fence would be signaled later.}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK*hjaubah}(h]h ]h"]h$]h&]uh1j hjEubeh}(h]h ]h"]h$]h&]uh1j hj`hK+hj@ubj )}(h3``flags`` A mask of DMA_FENCE_FLAG_* defined below h](j )}(h ``flags``h]j)}(hjh]hflags}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK,hjubj )}(hhh]h)}(h(A mask of DMA_FENCE_FLAG_* defined belowh]h(A mask of DMA_FENCE_FLAG_* defined below}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhK,hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhK,hj@ubj )}(h%``refcount`` refcount for this fence h](j )}(h ``refcount``h]j)}(hjh]hrefcount}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK"hjubj )}(hhh]h)}(hrefcount for this fenceh]hrefcount for this fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhK"hjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhK"hj@ubj )}(h``error`` Optional, only valid if < 0, must be set before calling dma_fence_signal, indicates that the fence has completed with an error.h](j )}(h ``error``h]j)}(hjh]herror}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK.hjubj )}(hhh]h)}(hOptional, only valid if < 0, must be set before calling dma_fence_signal, indicates that the fence has completed with an error.h]hOptional, only valid if < 0, must be set before calling dma_fence_signal, indicates that the fence has completed with an error.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hK.hj ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj hK.hj@ubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubh)}(h**Description**h]jr )}(hj9h]h Description}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj7ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK2hjhhubh)}(hthe flags member must be manipulated and read using the appropriate atomic ops (bit_*), so taking the spinlock will not be needed most of the time.h]hthe flags member must be manipulated and read using the appropriate atomic ops (bit_*), so taking the spinlock will not be needed most of the time.}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK/hjhhubh)}(hXDMA_FENCE_FLAG_INITIALIZED_BIT - fence was initialized DMA_FENCE_FLAG_INLINE_LOCK_BIT - use inline spinlock instead of external one DMA_FENCE_FLAG_SIGNALED_BIT - fence is already signaled DMA_FENCE_FLAG_TIMESTAMP_BIT - timestamp recorded for fence signaling DMA_FENCE_FLAG_ENABLE_SIGNAL_BIT - enable_signaling might have been called DMA_FENCE_FLAG_USER_BITS - start of the unused bits, can be used by the implementer of the fence for its own purposes. Can be used in different ways by different fence implementers, so do not rely on this.h]hXDMA_FENCE_FLAG_INITIALIZED_BIT - fence was initialized DMA_FENCE_FLAG_INLINE_LOCK_BIT - use inline spinlock instead of external one DMA_FENCE_FLAG_SIGNALED_BIT - fence is already signaled DMA_FENCE_FLAG_TIMESTAMP_BIT - timestamp recorded for fence signaling DMA_FENCE_FLAG_ENABLE_SIGNAL_BIT - enable_signaling might have been called DMA_FENCE_FLAG_USER_BITS - start of the unused bits, can be used by the implementer of the fence for its own purposes. Can be used in different ways by different fence implementers, so do not rely on this.}(hj^hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK3hjhhubh)}(hXSince atomic bitops are used, this is not guaranteed to be the case. Particularly, if the bit was set, but dma_fence_signal was called right before this bit was set, it would have been able to set the DMA_FENCE_FLAG_SIGNALED_BIT, before enable_signaling was called. Adding a check for DMA_FENCE_FLAG_SIGNALED_BIT after setting DMA_FENCE_FLAG_ENABLE_SIGNAL_BIT closes this race, and makes sure that after dma_fence_signal was called, any enable_signaling call will have either been completed, or never called at all.h]hXSince atomic bitops are used, this is not guaranteed to be the case. Particularly, if the bit was set, but dma_fence_signal was called right before this bit was set, it would have been able to set the DMA_FENCE_FLAG_SIGNALED_BIT, before enable_signaling was called. Adding a check for DMA_FENCE_FLAG_SIGNALED_BIT after setting DMA_FENCE_FLAG_ENABLE_SIGNAL_BIT closes this race, and makes sure that after dma_fence_signal was called, any enable_signaling call will have either been completed, or never called at all.}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK )j? huh1jhjhKHhjhhubjA )}(hhh]h)}(h%callback for dma_fence_add_callback()h]h%callback for dma_fence_add_callback()}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKxhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhKHubeh}(h]h ](jstructeh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Definition**:: struct dma_fence_cb { struct list_head node; dma_fence_func_t func; }; **Members** ``node`` used by dma_fence_add_callback() to append this struct to fence::cb_list ``func`` dma_fence_func_t to callh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubh:}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK|hjubj)}(hNstruct dma_fence_cb { struct list_head node; dma_fence_func_t func; };h]hNstruct dma_fence_cb { struct list_head node; dma_fence_func_t func; };}hjsbah}(h]h ]h"]h$]h&]jjuh1jh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK~hjubh)}(h **Members**h]jr )}(hj%h]hMembers}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj#ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubj )}(hhh](j )}(hR``node`` used by dma_fence_add_callback() to append this struct to fence::cb_list h](j )}(h``node``h]j)}(hjDh]hnode}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjBubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKzhj>ubj )}(hhh]h)}(hHused by dma_fence_add_callback() to append this struct to fence::cb_listh]hHused by dma_fence_add_callback() to append this struct to fence::cb_list}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjYhKzhjZubah}(h]h ]h"]h$]h&]uh1j hj>ubeh}(h]h ]h"]h$]h&]uh1j hjYhKzhj;ubj )}(h!``func`` dma_fence_func_t to callh](j )}(h``func``h]j)}(hj}h]hfunc}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj{ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKzhjwubj )}(hhh]h)}(hdma_fence_func_t to callh]hdma_fence_func_t to call}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK{hjubah}(h]h ]h"]h$]h&]uh1j hjwubeh}(h]h ]h"]h$]h&]uh1j hjhKzhj;ubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK~hjhhubh)}(hThis struct will be initialized by dma_fence_add_callback(), additional data can be passed along by embedding dma_fence_cb in another struct.h]hThis struct will be initialized by dma_fence_add_callback(), additional data can be passed along by embedding dma_fence_cb in another struct.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhK{hjhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_ops (C struct)c.dma_fence_opshNtauh1jhjhhhNhNubj)}(hhh](j)}(h dma_fence_opsh]j)}(hstruct dma_fence_opsh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhj hKubj )}(h dma_fence_opsh]j )}(hjh]h dma_fence_ops}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhj hKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhj hKubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj hKhjhhubjA )}(hhh]h)}(h operations implemented for fenceh]h operations implemented for fence}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhj=hhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhj hKubeh}(h]h ](jstructeh"]h$]h&]ja jjb jXjc jXjd je jf uh1jhhhjhNhNubjh )}(hX**Definition**:: struct dma_fence_ops { const char * (*get_driver_name)(struct dma_fence *fence); const char * (*get_timeline_name)(struct dma_fence *fence); bool (*enable_signaling)(struct dma_fence *fence); bool (*signaled)(struct dma_fence *fence); signed long (*wait)(struct dma_fence *fence, bool intr, signed long timeout); void (*release)(struct dma_fence *fence); void (*set_deadline)(struct dma_fence *fence, ktime_t deadline); }; **Members** ``get_driver_name`` Returns the driver name. This is a callback to allow drivers to compute the name at runtime, without having it to store permanently for each fence, or build a cache of some sort. The returned string is RCU protected and can be freed after the fence signaled and a RCU grace period passed. This callback is mandatory. ``get_timeline_name`` Return the name of the context this fence belongs to. This is a callback to allow drivers to compute the name at runtime, without having it to store permanently for each fence, or build a cache of some sort. The returned string is RCU protected and can be freed after the fence signaled and a RCU grace period passed. This callback is mandatory. ``enable_signaling`` Enable software signaling of fence. For fence implementations that have the capability for hw->hw signaling, they can implement this op to enable the necessary interrupts, or insert commands into cmdstream, etc, to avoid these costly operations for the common case where only hw->hw synchronization is required. This is called in the first dma_fence_wait() or dma_fence_add_callback() path to let the fence implementation know that there is another driver waiting on the signal (ie. hw->sw case). This is called with irq's disabled, so only spinlocks which disable IRQ's can be used in the code outside of this callback. A return value of false indicates the fence already passed, or some failure occurred that made it impossible to enable signaling. True indicates successful enabling. :c:type:`dma_fence.error ` may be set in enable_signaling, but only when false is returned. Since many implementations can call dma_fence_signal() even when before **enable_signaling** has been called there's a race window, where the dma_fence_signal() might result in the final fence reference being released and its memory freed. To avoid this, implementations of this callback should grab their own reference using dma_fence_get(), to be released when the fence is signalled (through e.g. the interrupt handler). This callback is optional. If this callback is not present, then the driver must always have signaling enabled. ``signaled`` Peek whether the fence is signaled, as a fastpath optimization for e.g. dma_fence_wait() or dma_fence_add_callback(). Note that this callback does not need to make any guarantees beyond that a fence once indicates as signalled must always return true from this callback. This callback may return false even if the fence has completed already, in this case information hasn't propogated throug the system yet. See also dma_fence_is_signaled(). May set :c:type:`dma_fence.error ` if returning true. This callback is optional. ``wait`` Custom wait implementation, defaults to dma_fence_default_wait() if not set. Deprecated and should not be used by new implementations. Only used by existing implementations which need special handling for their hardware reset procedure. Must return -ERESTARTSYS if the wait is intr = true and the wait was interrupted, and remaining jiffies if fence has signaled, or 0 if wait timed out. Can also return other error values on custom implementations, which should be treated as if the fence is signaled. For example a hardware lockup could be reported like that. Implementing this callback prevents the fence from detaching after signaling and so it is necessary for the module providing the dma_fence_ops to stay loaded as long as the dma_fence exists. ``release`` Called on destruction of fence to release additional resources. Can be called from irq context. This callback is optional. If it is NULL, then dma_fence_free() is instead called as the default implementation. Implementing this callback prevents the fence from detaching after signaling and so it is necessary for the module providing the dma_fence_ops to stay loaded as long as the dma_fence exists. If the callback is implemented the memory backing the dma_fence object must be freed RCU safe. ``set_deadline`` Callback to allow a fence waiter to inform the fence signaler of an upcoming deadline, such as vblank, by which point the waiter would prefer the fence to be signaled by. This is intended to give feedback to the fence signaler to aid in power management decisions, such as boosting GPU frequency. This is called without :c:type:`dma_fence.lock ` held, it can be called multiple times and from any context. Locking is up to the callee if it has some state to manage. If multiple deadlines are set, the expectation is to track the soonest one. If the deadline is before the current time, it should be interpreted as an immediate deadline. This callback is optional.h](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj`ubh:}(hj`hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhj\ubj)}(hXstruct dma_fence_ops { const char * (*get_driver_name)(struct dma_fence *fence); const char * (*get_timeline_name)(struct dma_fence *fence); bool (*enable_signaling)(struct dma_fence *fence); bool (*signaled)(struct dma_fence *fence); signed long (*wait)(struct dma_fence *fence, bool intr, signed long timeout); void (*release)(struct dma_fence *fence); void (*set_deadline)(struct dma_fence *fence, ktime_t deadline); };h]hXstruct dma_fence_ops { const char * (*get_driver_name)(struct dma_fence *fence); const char * (*get_timeline_name)(struct dma_fence *fence); bool (*enable_signaling)(struct dma_fence *fence); bool (*signaled)(struct dma_fence *fence); signed long (*wait)(struct dma_fence *fence, bool intr, signed long timeout); void (*release)(struct dma_fence *fence); void (*set_deadline)(struct dma_fence *fence, ktime_t deadline); };}hj}sbah}(h]h ]h"]h$]h&]jjuh1jh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhj\ubh)}(h **Members**h]jr )}(hjh]hMembers}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhj\ubj )}(hhh](j )}(hXS``get_driver_name`` Returns the driver name. This is a callback to allow drivers to compute the name at runtime, without having it to store permanently for each fence, or build a cache of some sort. The returned string is RCU protected and can be freed after the fence signaled and a RCU grace period passed. This callback is mandatory. h](j )}(h``get_driver_name``h]j)}(hjh]hget_driver_name}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubj )}(hhh](h)}(hReturns the driver name. This is a callback to allow drivers to compute the name at runtime, without having it to store permanently for each fence, or build a cache of some sort.h]hReturns the driver name. This is a callback to allow drivers to compute the name at runtime, without having it to store permanently for each fence, or build a cache of some sort.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubh)}(hmThe returned string is RCU protected and can be freed after the fence signaled and a RCU grace period passed.h]hmThe returned string is RCU protected and can be freed after the fence signaled and a RCU grace period passed.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubh)}(hThis callback is mandatory.h]hThis callback is mandatory.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubj )}(hXr``get_timeline_name`` Return the name of the context this fence belongs to. This is a callback to allow drivers to compute the name at runtime, without having it to store permanently for each fence, or build a cache of some sort. The returned string is RCU protected and can be freed after the fence signaled and a RCU grace period passed. This callback is mandatory. h](j )}(h``get_timeline_name``h]j)}(hjh]hget_timeline_name}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubj )}(hhh](h)}(hReturn the name of the context this fence belongs to. This is a callback to allow drivers to compute the name at runtime, without having it to store permanently for each fence, or build a cache of some sort.h]hReturn the name of the context this fence belongs to. This is a callback to allow drivers to compute the name at runtime, without having it to store permanently for each fence, or build a cache of some sort.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubh)}(hmThe returned string is RCU protected and can be freed after the fence signaled and a RCU grace period passed.h]hmThe returned string is RCU protected and can be freed after the fence signaled and a RCU grace period passed.}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubh)}(hThis callback is mandatory.h]hThis callback is mandatory.}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhKhjubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubj )}(hX``enable_signaling`` Enable software signaling of fence. For fence implementations that have the capability for hw->hw signaling, they can implement this op to enable the necessary interrupts, or insert commands into cmdstream, etc, to avoid these costly operations for the common case where only hw->hw synchronization is required. This is called in the first dma_fence_wait() or dma_fence_add_callback() path to let the fence implementation know that there is another driver waiting on the signal (ie. hw->sw case). This is called with irq's disabled, so only spinlocks which disable IRQ's can be used in the code outside of this callback. A return value of false indicates the fence already passed, or some failure occurred that made it impossible to enable signaling. True indicates successful enabling. :c:type:`dma_fence.error ` may be set in enable_signaling, but only when false is returned. Since many implementations can call dma_fence_signal() even when before **enable_signaling** has been called there's a race window, where the dma_fence_signal() might result in the final fence reference being released and its memory freed. To avoid this, implementations of this callback should grab their own reference using dma_fence_get(), to be released when the fence is signalled (through e.g. the interrupt handler). This callback is optional. If this callback is not present, then the driver must always have signaling enabled. h](j )}(h``enable_signaling``h]j)}(hj[h]henable_signaling}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjYubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjUubj )}(hhh](h)}(h#Enable software signaling of fence.h]h#Enable software signaling of fence.}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjqubh)}(hXFor fence implementations that have the capability for hw->hw signaling, they can implement this op to enable the necessary interrupts, or insert commands into cmdstream, etc, to avoid these costly operations for the common case where only hw->hw synchronization is required. This is called in the first dma_fence_wait() or dma_fence_add_callback() path to let the fence implementation know that there is another driver waiting on the signal (ie. hw->sw case).h]hXFor fence implementations that have the capability for hw->hw signaling, they can implement this op to enable the necessary interrupts, or insert commands into cmdstream, etc, to avoid these costly operations for the common case where only hw->hw synchronization is required. This is called in the first dma_fence_wait() or dma_fence_add_callback() path to let the fence implementation know that there is another driver waiting on the signal (ie. hw->sw case).}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjqubh)}(h{This is called with irq's disabled, so only spinlocks which disable IRQ's can be used in the code outside of this callback.h]hThis is called with irq’s disabled, so only spinlocks which disable IRQ’s can be used in the code outside of this callback.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjqubh)}(hA return value of false indicates the fence already passed, or some failure occurred that made it impossible to enable signaling. True indicates successful enabling.h]hA return value of false indicates the fence already passed, or some failure occurred that made it impossible to enable signaling. True indicates successful enabling.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjqubh)}(hf:c:type:`dma_fence.error ` may be set in enable_signaling, but only when false is returned.h](h)}(h%:c:type:`dma_fence.error `h]j)}(hjh]hdma_fence.error}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubhA may be set in enable_signaling, but only when false is returned.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhKhjqubh)}(hXSince many implementations can call dma_fence_signal() even when before **enable_signaling** has been called there's a race window, where the dma_fence_signal() might result in the final fence reference being released and its memory freed. To avoid this, implementations of this callback should grab their own reference using dma_fence_get(), to be released when the fence is signalled (through e.g. the interrupt handler).h](hHSince many implementations can call dma_fence_signal() even when before }(hjhhhNhNubjr )}(h**enable_signaling**h]henable_signaling}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubhXM has been called there’s a race window, where the dma_fence_signal() might result in the final fence reference being released and its memory freed. To avoid this, implementations of this callback should grab their own reference using dma_fence_get(), to be released when the fence is signalled (through e.g. the interrupt handler).}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjqubh)}(hoThis callback is optional. If this callback is not present, then the driver must always have signaling enabled.h]hoThis callback is optional. If this callback is not present, then the driver must always have signaling enabled.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjqubeh}(h]h ]h"]h$]h&]uh1j hjUubeh}(h]h ]h"]h$]h&]uh1j hjphKhjubj )}(hX&``signaled`` Peek whether the fence is signaled, as a fastpath optimization for e.g. dma_fence_wait() or dma_fence_add_callback(). Note that this callback does not need to make any guarantees beyond that a fence once indicates as signalled must always return true from this callback. This callback may return false even if the fence has completed already, in this case information hasn't propogated throug the system yet. See also dma_fence_is_signaled(). May set :c:type:`dma_fence.error ` if returning true. This callback is optional. h](j )}(h ``signaled``h]j)}(hj h]hsignaled}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubj )}(hhh](h)}(hXPeek whether the fence is signaled, as a fastpath optimization for e.g. dma_fence_wait() or dma_fence_add_callback(). Note that this callback does not need to make any guarantees beyond that a fence once indicates as signalled must always return true from this callback. This callback may return false even if the fence has completed already, in this case information hasn't propogated throug the system yet. See also dma_fence_is_signaled().h]hXPeek whether the fence is signaled, as a fastpath optimization for e.g. dma_fence_wait() or dma_fence_add_callback(). Note that this callback does not need to make any guarantees beyond that a fence once indicates as signalled must always return true from this callback. This callback may return false even if the fence has completed already, in this case information hasn’t propogated throug the system yet. See also dma_fence_is_signaled().}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhj6ubh)}(h@May set :c:type:`dma_fence.error ` if returning true.h](hMay set }(hjHhhhNhNubh)}(h%:c:type:`dma_fence.error `h]j)}(hjRh]hdma_fence.error}(hjThhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjPubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjHubh if returning true.}(hjHhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjohKhj6ubh)}(hThis callback is optional.h]hThis callback is optional.}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj5hKhj6ubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj5hKhjubj )}(hX``wait`` Custom wait implementation, defaults to dma_fence_default_wait() if not set. Deprecated and should not be used by new implementations. Only used by existing implementations which need special handling for their hardware reset procedure. Must return -ERESTARTSYS if the wait is intr = true and the wait was interrupted, and remaining jiffies if fence has signaled, or 0 if wait timed out. Can also return other error values on custom implementations, which should be treated as if the fence is signaled. For example a hardware lockup could be reported like that. Implementing this callback prevents the fence from detaching after signaling and so it is necessary for the module providing the dma_fence_ops to stay loaded as long as the dma_fence exists. h](j )}(h``wait``h]j)}(hjh]hwait}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubj )}(hhh](h)}(hLCustom wait implementation, defaults to dma_fence_default_wait() if not set.h]hLCustom wait implementation, defaults to dma_fence_default_wait() if not set.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubh)}(hDeprecated and should not be used by new implementations. Only used by existing implementations which need special handling for their hardware reset procedure.h]hDeprecated and should not be used by new implementations. Only used by existing implementations which need special handling for their hardware reset procedure.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubh)}(hXDMust return -ERESTARTSYS if the wait is intr = true and the wait was interrupted, and remaining jiffies if fence has signaled, or 0 if wait timed out. Can also return other error values on custom implementations, which should be treated as if the fence is signaled. For example a hardware lockup could be reported like that.h]hXDMust return -ERESTARTSYS if the wait is intr = true and the wait was interrupted, and remaining jiffies if fence has signaled, or 0 if wait timed out. Can also return other error values on custom implementations, which should be treated as if the fence is signaled. For example a hardware lockup could be reported like that.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubh)}(hImplementing this callback prevents the fence from detaching after signaling and so it is necessary for the module providing the dma_fence_ops to stay loaded as long as the dma_fence exists.h]hImplementing this callback prevents the fence from detaching after signaling and so it is necessary for the module providing the dma_fence_ops to stay loaded as long as the dma_fence exists.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubj )}(hX``release`` Called on destruction of fence to release additional resources. Can be called from irq context. This callback is optional. If it is NULL, then dma_fence_free() is instead called as the default implementation. Implementing this callback prevents the fence from detaching after signaling and so it is necessary for the module providing the dma_fence_ops to stay loaded as long as the dma_fence exists. If the callback is implemented the memory backing the dma_fence object must be freed RCU safe. h](j )}(h ``release``h]j)}(hjh]hrelease}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubj )}(hhh](h)}(hCalled on destruction of fence to release additional resources. Can be called from irq context. This callback is optional. If it is NULL, then dma_fence_free() is instead called as the default implementation.h]hCalled on destruction of fence to release additional resources. Can be called from irq context. This callback is optional. If it is NULL, then dma_fence_free() is instead called as the default implementation.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubh)}(hImplementing this callback prevents the fence from detaching after signaling and so it is necessary for the module providing the dma_fence_ops to stay loaded as long as the dma_fence exists.h]hImplementing this callback prevents the fence from detaching after signaling and so it is necessary for the module providing the dma_fence_ops to stay loaded as long as the dma_fence exists.}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubh)}(h^If the callback is implemented the memory backing the dma_fence object must be freed RCU safe.h]h^If the callback is implemented the memory backing the dma_fence object must be freed RCU safe.}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhKhjubeh}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhKhjubj )}(hX``set_deadline`` Callback to allow a fence waiter to inform the fence signaler of an upcoming deadline, such as vblank, by which point the waiter would prefer the fence to be signaled by. This is intended to give feedback to the fence signaler to aid in power management decisions, such as boosting GPU frequency. This is called without :c:type:`dma_fence.lock ` held, it can be called multiple times and from any context. Locking is up to the callee if it has some state to manage. If multiple deadlines are set, the expectation is to track the soonest one. If the deadline is before the current time, it should be interpreted as an immediate deadline. This callback is optional.h](j )}(h``set_deadline``h]j)}(hjYh]h set_deadline}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjWubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjSubj )}(hhh](h)}(hX)Callback to allow a fence waiter to inform the fence signaler of an upcoming deadline, such as vblank, by which point the waiter would prefer the fence to be signaled by. This is intended to give feedback to the fence signaler to aid in power management decisions, such as boosting GPU frequency.h]hX)Callback to allow a fence waiter to inform the fence signaler of an upcoming deadline, such as vblank, by which point the waiter would prefer the fence to be signaled by. This is intended to give feedback to the fence signaler to aid in power management decisions, such as boosting GPU frequency.}(hjrhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjoubh)}(hXaThis is called without :c:type:`dma_fence.lock ` held, it can be called multiple times and from any context. Locking is up to the callee if it has some state to manage. If multiple deadlines are set, the expectation is to track the soonest one. If the deadline is before the current time, it should be interpreted as an immediate deadline.h](hThis is called without }(hjhhhNhNubh)}(h$:c:type:`dma_fence.lock `h]j)}(hjh]hdma_fence.lock}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM hjubhX& held, it can be called multiple times and from any context. Locking is up to the callee if it has some state to manage. If multiple deadlines are set, the expectation is to track the soonest one. If the deadline is before the current time, it should be interpreted as an immediate deadline.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhM hjoubh)}(hThis callback is optional.h]hThis callback is optional.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjoubeh}(h]h ]h"]h$]h&]uh1j hjSubeh}(h]h ]h"]h$]h&]uh1j hjnhMhjubeh}(h]h ]h"]h$]h&]uh1j hj\ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j&dma_fence_was_initialized (C function)c.dma_fence_was_initializedhNtauh1jhjhhhNhNubj)}(hhh](j)}(h8bool dma_fence_was_initialized (struct dma_fence *fence)h]j)}(h7bool dma_fence_was_initialized(struct dma_fence *fence)h](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM$ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhM$ubj )}(hdma_fence_was_initializedh]j )}(hdma_fence_was_initializedh]hdma_fence_was_initialized}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhM$ubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj,ubj)}(h h]h }(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj,ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjNhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjKubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjPmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_was_initializedasbuh1hhj,ubj)}(h h]h }(hjnhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj,ubjd)}(hjgh]h*}(hj|hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj,ubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj,ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj(ubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhM$ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhM$ubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhM$hjhhubjA )}(hhh]h)}(htest if fence was initializedh]htest if fence was initialized}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM$hjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhM$ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` fence to test **Return** True if fence was ever initialized, false otherwise. Works correctly only when memory backing the fence structure is zero initialized on allocation.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM(hjubj )}(hhh]j )}(h*``struct dma_fence *fence`` fence to test h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM%hjubj )}(hhh]h)}(h fence to testh]h fence to test}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hM%hj ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj hM%hjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h **Return**h]jr )}(hj/h]hReturn}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj-ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM'hjubh)}(hTrue if fence was ever initialized, false otherwise. Works correctly only when memory backing the fence structure is zero initialized on allocation.h]hTrue if fence was ever initialized, false otherwise. Works correctly only when memory backing the fence structure is zero initialized on allocation.}(hjEhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM'hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_put (C function)c.dma_fence_puthNtauh1jhjhhhNhNubj)}(hhh](j)}(h,void dma_fence_put (struct dma_fence *fence)h]j)}(h+void dma_fence_put(struct dma_fence *fence)h](jM)}(hvoidh]hvoid}(hjthhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjphhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM1ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjphhhjhM1ubj )}(h dma_fence_puth]j )}(h dma_fence_puth]h dma_fence_put}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjphhhjhM1ubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_putasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjphhhjhM1ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjlhhhjhM1ubah}(h]jgah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhM1hjihhubjA )}(hhh]h)}(hdecreases refcount of the fenceh]hdecreases refcount of the fence}(hj4hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM1hj1hhubah}(h]h ]h"]h$]h&]uh1j@ hjihhhjhM1ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jLjc jLjd je jf uh1jhhhjhNhNubjh )}(hI**Parameters** ``struct dma_fence *fence`` fence to reduce refcount ofh](h)}(h**Parameters**h]jr )}(hjVh]h Parameters}(hjXhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjTubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM5hjPubj )}(hhh]j )}(h7``struct dma_fence *fence`` fence to reduce refcount ofh](j )}(h``struct dma_fence *fence``h]j)}(hjuh]hstruct dma_fence *fence}(hjwhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjsubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM7hjoubj )}(hhh]h)}(hfence to reduce refcount ofh]hfence to reduce refcount of}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM2hjubah}(h]h ]h"]h$]h&]uh1j hjoubeh}(h]h ]h"]h$]h&]uh1j hjhM7hjlubah}(h]h ]h"]h$]h&]uh1j hjPubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_get (C function)c.dma_fence_gethNtauh1jhjhhhNhNubj)}(hhh](j)}(h:struct dma_fence * dma_fence_get (struct dma_fence *fence)h]j)}(h8struct dma_fence *dma_fence_get(struct dma_fence *fence)h](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM;ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhM;ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jG dma_fence_getsbc.dma_fence_getasbuh1hhjhhhjhM;ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhM;ubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjhhhjhM;ubj )}(h dma_fence_geth]j )}(hj h]h dma_fence_get}(hj.hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj*ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhM;ubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjIhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjEubj)}(h h]h }(hjVhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjEubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjghhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjdubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjimodnameN classnameNjj)}j]j c.dma_fence_getasbuh1hhjEubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjEubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjEubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjEubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjAubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhM;ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhM;ubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhM;hjhhubjA )}(hhh]h)}(hincreases refcount of the fenceh]hincreases refcount of the fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM;hjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhM;ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` fence to increase refcount of **Description** Returns the same fence, with refcount increased by 1.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM?hjubj )}(hhh]j )}(h:``struct dma_fence *fence`` fence to increase refcount of h](j )}(h``struct dma_fence *fence``h]j)}(hj h]hstruct dma_fence *fence}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM<hjubj )}(hhh]h)}(hfence to increase refcount ofh]hfence to increase refcount of}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hM<hj!ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj hM<hjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjFh]h Description}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjDubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM>hjubh)}(h5Returns the same fence, with refcount increased by 1.h]h5Returns the same fence, with refcount increased by 1.}(hj\hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM=hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_get_rcu (C function)c.dma_fence_get_rcuhNtauh1jhjhhhNhNubj)}(hhh](j)}(h>struct dma_fence * dma_fence_get_rcu (struct dma_fence *fence)h]j)}(h )j? huh1jhjhMHhjhhubjA )}(hhh]h)}(h3get a fence from a dma_resv_list with rcu read lockh]h3get a fence from a dma_resv_list with rcu read lock}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMHhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMHubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` fence to increase refcount of **Description** Function returns NULL if no refcount could be obtained, or the fence.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMLhjubj )}(hhh]j )}(h:``struct dma_fence *fence`` fence to increase refcount of h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMJhjubj )}(hhh]h)}(hfence to increase refcount ofh]hfence to increase refcount of}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMJhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMJhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMLhjubh)}(hEFunction returns NULL if no refcount could be obtained, or the fence.h]hEFunction returns NULL if no refcount could be obtained, or the fence.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMKhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_fence_get_rcu_safe (C function)c.dma_fence_get_rcu_safehNtauh1jhjhhhNhNubj)}(hhh](j)}(hKstruct dma_fence * dma_fence_get_rcu_safe (struct dma_fence __rcu **fencep)h]j)}(hIstruct dma_fence *dma_fence_get_rcu_safe(struct dma_fence __rcu **fencep)h](j)}(hjh]hstruct}(hjGhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjChhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMWubj)}(h h]h }(hjUhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjChhhjThMWubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjfhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjcubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjhmodnameN classnameNjj)}j]jO)}jGdma_fence_get_rcu_safesbc.dma_fence_get_rcu_safeasbuh1hhjChhhjThMWubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjChhhjThMWubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjChhhjThMWubj )}(hdma_fence_get_rcu_safeh]j )}(hjh]hdma_fence_get_rcu_safe}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjChhhjThMWubj)}(h!(struct dma_fence __rcu **fencep)h]j)}(hstruct dma_fence __rcu **fenceph](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_fence_get_rcu_safeasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh__rcu}(hjhhhNhNubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubjd)}(hjgh]h*}(hj*hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceph]hfencep}(hj7hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjChhhjThMWubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj?hhhjThMWubah}(h]j:ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjThMWhj<hhubjA )}(hhh]h)}(h+acquire a reference to an RCU tracked fenceh]h+acquire a reference to an RCU tracked fence}(hjahhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMWhj^hhubah}(h]h ]h"]h$]h&]uh1j@ hj<hhhjThMWubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jyjc jyjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence __rcu **fencep`` pointer to fence to increase refcount of **Description** Function returns NULL if no refcount could be obtained, or the fence. This function handles acquiring a reference to a fence that may be reallocated within the RCU grace period (such as with SLAB_TYPESAFE_BY_RCU), so long as the caller is using RCU on the pointer to the fence. An alternative mechanism is to employ a seqlock to protect a bunch of fences, such as used by struct dma_resv. When using a seqlock, the seqlock must be taken before and checked after a reference to the fence is acquired (as shown here). The caller is required to hold the RCU read lock.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM[hj}ubj )}(hhh]j )}(hM``struct dma_fence __rcu **fencep`` pointer to fence to increase refcount of h](j )}(h#``struct dma_fence __rcu **fencep``h]j)}(hjh]hstruct dma_fence __rcu **fencep}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMXhjubj )}(hhh]h)}(h(pointer to fence to increase refcount ofh]h(pointer to fence to increase refcount of}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMXhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMXhjubah}(h]h ]h"]h$]h&]uh1j hj}ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMZhj}ubh)}(hXFunction returns NULL if no refcount could be obtained, or the fence. This function handles acquiring a reference to a fence that may be reallocated within the RCU grace period (such as with SLAB_TYPESAFE_BY_RCU), so long as the caller is using RCU on the pointer to the fence.h]hXFunction returns NULL if no refcount could be obtained, or the fence. This function handles acquiring a reference to a fence that may be reallocated within the RCU grace period (such as with SLAB_TYPESAFE_BY_RCU), so long as the caller is using RCU on the pointer to the fence.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMYhj}ubh)}(hAn alternative mechanism is to employ a seqlock to protect a bunch of fences, such as used by struct dma_resv. When using a seqlock, the seqlock must be taken before and checked after a reference to the fence is acquired (as shown here).h]hAn alternative mechanism is to employ a seqlock to protect a bunch of fences, such as used by struct dma_resv. When using a seqlock, the seqlock must be taken before and checked after a reference to the fence is acquired (as shown here).}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM^hj}ubh)}(h1The caller is required to hold the RCU read lock.h]h1The caller is required to hold the RCU read lock.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMchj}ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_spinlock (C function)c.dma_fence_spinlockhNtauh1jhjhhhNhNubj)}(hhh](j)}(h9spinlock_t * dma_fence_spinlock (struct dma_fence *fence)h]j)}(h7spinlock_t *dma_fence_spinlock(struct dma_fence *fence)h](h)}(hhh]j )}(h spinlock_th]h spinlock_t}(hjChhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj@ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjEmodnameN classnameNjj)}j]jO)}jGdma_fence_spinlocksbc.dma_fence_spinlockasbuh1hhj<hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubj)}(h h]h }(hjehhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj<hhhjdhMubjd)}(hjgh]h*}(hjshhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj<hhhjdhMubj )}(hdma_fence_spinlockh]j )}(hjah]hdma_fence_spinlock}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj<hhhjdhMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]j_c.dma_fence_spinlockasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhj<hhhjdhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj8hhhjdhMubah}(h]j3ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjdhMhj5hhubjA )}(hhh]h)}(h3return pointer to the spinlock protecting the fenceh]h3return pointer to the spinlock protecting the fence}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hj5hhhjdhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j8jc j8jd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` the fence to get the lock from **Description** Return either the pointer to the embedded or the external spin lock.h](h)}(h**Parameters**h]jr )}(hjBh]h Parameters}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj@ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhj<ubj )}(hhh]j )}(h;``struct dma_fence *fence`` the fence to get the lock from h](j )}(h``struct dma_fence *fence``h]j)}(hjah]hstruct dma_fence *fence}(hjchhhNhNubah}(h]h ]h"]h$]h&]uh1jhj_ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhj[ubj )}(hhh]h)}(hthe fence to get the lock fromh]hthe fence to get the lock from}(hjzhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjvhMhjwubah}(h]h ]h"]h$]h&]uh1j hj[ubeh}(h]h ]h"]h$]h&]uh1j hjvhMhjXubah}(h]h ]h"]h$]h&]uh1j hj<ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhj<ubh)}(hDReturn either the pointer to the embedded or the external spin lock.h]hDReturn either the pointer to the embedded or the external spin lock.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhj<ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j dma_fence_lock_irqsave (C macro)c.dma_fence_lock_irqsavehNtauh1jhjhhhNhNubj)}(hhh](j)}(hdma_fence_lock_irqsaveh]j)}(hdma_fence_lock_irqsaveh]j )}(hdma_fence_lock_irqsaveh]j )}(hjh]hdma_fence_lock_irqsave}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubah}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jmacroeh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubh)}(h)``dma_fence_lock_irqsave (fence, flags)``h]j)}(hjh]h%dma_fence_lock_irqsave (fence, flags)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjhhubh)}(hirqsave lock the fence h]h)}(hirqsave lock the fenceh]hirqsave lock the fence}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhj-ubah}(h]h ]h"]h$]h&]uh1hhj?hMhjhhubjh )}(h**Parameters** ``fence`` the fence to lock ``flags`` where to store the CPU flags. **Description** Lock the fence, preventing it from changing to the signaled state.h](h)}(h**Parameters**h]jr )}(hjLh]h Parameters}(hjNhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjJubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjFubj )}(hhh](j )}(h``fence`` the fence to lock h](j )}(h ``fence``h]j)}(hjkh]hfence}(hjmhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjiubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjeubj )}(hhh]h)}(hthe fence to lockh]hthe fence to lock}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjeubeh}(h]h ]h"]h$]h&]uh1j hjhMhjbubj )}(h(``flags`` where to store the CPU flags. h](j )}(h ``flags``h]j)}(hjh]hflags}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(hwhere to store the CPU flags.h]hwhere to store the CPU flags.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjbubeh}(h]h ]h"]h$]h&]uh1j hjFubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjFubh)}(hBLock the fence, preventing it from changing to the signaled state.h]hBLock the fence, preventing it from changing to the signaled state.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjFubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j%dma_fence_unlock_irqrestore (C macro)c.dma_fence_unlock_irqrestorehNtauh1jhjhhhNhNubj)}(hhh](j)}(hdma_fence_unlock_irqrestoreh]j)}(hdma_fence_unlock_irqrestoreh]j )}(hdma_fence_unlock_irqrestoreh]j )}(hjh]hdma_fence_unlock_irqrestore}(hj(hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj$ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubah}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhj;hMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj;hMhjhhubjA )}(hhh]h}(h]h ]h"]h$]h&]uh1j@ hjhhhj;hMubeh}(h]h ](jmacroeh"]h$]h&]ja jjb jTjc jTjd je jf uh1jhhhjhNhNubh)}(h.``dma_fence_unlock_irqrestore (fence, flags)``h]j)}(hjZh]h*dma_fence_unlock_irqrestore (fence, flags)}(hj\hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjXubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjhhubh)}(h unlock the fence and irqrestore h]h)}(hunlock the fence and irqrestoreh]hunlock the fence and irqrestore}(hjthhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjpubah}(h]h ]h"]h$]h&]uh1hhjhMhjhhubjh )}(h**Parameters** ``fence`` the fence to unlock ``flags`` the CPU flags to restore **Description** Unlock the fence, allowing it to change its state to signaled again.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh](j )}(h``fence`` the fence to unlock h](j )}(h ``fence``h]j)}(hjh]hfence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(hthe fence to unlockh]hthe fence to unlock}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubj )}(h#``flags`` the CPU flags to restore h](j )}(h ``flags``h]j)}(hjh]hflags}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(hthe CPU flags to restoreh]hthe CPU flags to restore}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj"h]h Description}(hj$hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hDUnlock the fence, allowing it to change its state to signaled again.h]hDUnlock the fence, allowing it to change its state to signaled again.}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_assert_held (C macro)c.dma_fence_assert_heldhNtauh1jhjhhhNhNubj)}(hhh](j)}(hdma_fence_assert_heldh]j)}(hdma_fence_assert_heldh]j )}(hdma_fence_assert_heldh]j )}(hjah]hdma_fence_assert_held}(hjkhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjgubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjchhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubah}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj_hhhj~hMubah}(h]jZah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj~hMhj\hhubjA )}(hhh]h}(h]h ]h"]h$]h&]uh1j@ hj\hhhj~hMubeh}(h]h ](jmacroeh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubh)}(h!``dma_fence_assert_held (fence)``h]j)}(hjh]hdma_fence_assert_held (fence)}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjhhubh)}(h'lockdep assertion that fence is locked h]h)}(h&lockdep assertion that fence is lockedh]h&lockdep assertion that fence is locked}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubah}(h]h ]h"]h$]h&]uh1hhjhMhjhhubjh )}(h<**Parameters** ``fence`` the fence which should be lockedh](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]j )}(h*``fence`` the fence which should be lockedh](j )}(h ``fence``h]j)}(hjh]hfence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(h the fence which should be lockedh]h the fence which should be locked}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j)dma_fence_is_signaled_locked (C function)c.dma_fence_is_signaled_lockedhNtauh1jhjhhhNhNubj)}(hhh](j)}(h;bool dma_fence_is_signaled_locked (struct dma_fence *fence)h]j)}(h:bool dma_fence_is_signaled_locked(struct dma_fence *fence)h](jM)}(hji5h]hbool}(hjKhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjGhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubj)}(h h]h }(hjYhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjGhhhjXhMubj )}(hdma_fence_is_signaled_lockedh]j )}(hdma_fence_is_signaled_lockedh]hdma_fence_is_signaled_locked}(hjkhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjgubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjGhhhjXhMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjmsbc.dma_fence_is_signaled_lockedasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjGhhhjXhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjChhhjXhMubah}(h]j>ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjXhMhj@hhubjA )}(hhh]h)}(h2Return an indication if the fence is signaled yet.h]h2Return an indication if the fence is signaled yet.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hj@hhhjXhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j"jc j"jd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to check **Description** Returns true if the fence was already signaled, false if not. Since this function doesn't enable signaling, it is not guaranteed to ever return true if dma_fence_add_callback(), dma_fence_wait() or dma_fence_enable_sw_signaling() haven't been called before. This function requires :c:type:`dma_fence.lock ` to be held. See also dma_fence_is_signaled().h](h)}(h**Parameters**h]jr )}(hj,h]h Parameters}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj*ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhj&ubj )}(hhh]j )}(h/``struct dma_fence *fence`` the fence to check h](j )}(h``struct dma_fence *fence``h]j)}(hjKh]hstruct dma_fence *fence}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjIubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjEubj )}(hhh]h)}(hthe fence to checkh]hthe fence to check}(hjdhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj`hMhjaubah}(h]h ]h"]h$]h&]uh1j hjEubeh}(h]h ]h"]h$]h&]uh1j hj`hMhjBubah}(h]h ]h"]h$]h&]uh1j hj&ubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhj&ubh)}(hXReturns true if the fence was already signaled, false if not. Since this function doesn't enable signaling, it is not guaranteed to ever return true if dma_fence_add_callback(), dma_fence_wait() or dma_fence_enable_sw_signaling() haven't been called before.h]hXReturns true if the fence was already signaled, false if not. Since this function doesn’t enable signaling, it is not guaranteed to ever return true if dma_fence_add_callback(), dma_fence_wait() or dma_fence_enable_sw_signaling() haven’t been called before.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhj&ubh)}(hGThis function requires :c:type:`dma_fence.lock ` to be held.h](hThis function requires }(hjhhhNhNubh)}(h$:c:type:`dma_fence.lock `h]j)}(hjh]hdma_fence.lock}(hjhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj dma_fenceuh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh to be held.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjhMhj&ubh)}(h!See also dma_fence_is_signaled().h]h!See also dma_fence_is_signaled().}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhj&ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j"dma_fence_is_signaled (C function)c.dma_fence_is_signaledhNtauh1jhjhhhNhNubj)}(hhh](j)}(h4bool dma_fence_is_signaled (struct dma_fence *fence)h]j)}(h3bool dma_fence_is_signaled(struct dma_fence *fence)h](jM)}(hji5h]hbool}(hj hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(hdma_fence_is_signaledh]j )}(hdma_fence_is_signaledh]hdma_fence_is_signaled}(hj,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj(ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjHhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjDubj)}(h h]h }(hjUhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjDubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjfhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjcubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjhmodnameN classnameNjj)}j]jO)}jGj.sbc.dma_fence_is_signaledasbuh1hhjDubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjDubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjDubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjDubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj@ubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h2Return an indication if the fence is signaled yet.h]h2Return an indication if the fence is signaled yet.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the fence to check **Description** Returns true if the fence was already signaled, false if not. Since this function doesn't enable signaling, it is not guaranteed to ever return true if dma_fence_add_callback(), dma_fence_wait() or dma_fence_enable_signaling() haven't been called before. It's recommended for seqno fences to call dma_fence_signal when the operation is complete, it makes it possible to prevent issues from wraparound between time of issue and time of use by checking the return value of this function before calling hardware-specific wait instructions. See also dma_fence_is_signaled_locked().h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]j )}(h/``struct dma_fence *fence`` the fence to check h](j )}(h``struct dma_fence *fence``h]j)}(hj h]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(hthe fence to checkh]hthe fence to check}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj!hMhj"ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hj!hMhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjGh]h Description}(hjIhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjEubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hReturns true if the fence was already signaled, false if not. Since this function doesn't enable signaling, it is not guaranteed to ever return true if dma_fence_add_callback(), dma_fence_wait() or dma_fence_enable_signaling() haven't been called before.h]hXReturns true if the fence was already signaled, false if not. Since this function doesn’t enable signaling, it is not guaranteed to ever return true if dma_fence_add_callback(), dma_fence_wait() or dma_fence_enable_signaling() haven’t been called before.}(hj]hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hXIt's recommended for seqno fences to call dma_fence_signal when the operation is complete, it makes it possible to prevent issues from wraparound between time of issue and time of use by checking the return value of this function before calling hardware-specific wait instructions.h]hXIt’s recommended for seqno fences to call dma_fence_signal when the operation is complete, it makes it possible to prevent issues from wraparound between time of issue and time of use by checking the return value of this function before calling hardware-specific wait instructions.}(hjlhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM hjubh)}(h(See also dma_fence_is_signaled_locked().h]h(See also dma_fence_is_signaled_locked().}(hj{hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM%hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j!__dma_fence_is_later (C function)c.__dma_fence_is_laterhNtauh1jhjhhhNhNubj)}(hhh](j)}(hCbool __dma_fence_is_later (struct dma_fence *fence, u64 f1, u64 f2)h]j)}(hBbool __dma_fence_is_later(struct dma_fence *fence, u64 f1, u64 f2)h](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM=ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhM=ubj )}(h__dma_fence_is_laterh]j )}(h__dma_fence_is_laterh]h__dma_fence_is_later}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhM=ubj)}(h)(struct dma_fence *fence, u64 f1, u64 f2)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]jO)}jGjsbc.__dma_fence_is_laterasbuh1hhjubj)}(h h]h }(hj$ hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj2 hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hj? hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hu64 f1h](h)}(hhh]j )}(hu64h]hu64}(hj[ hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjX ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj] modnameN classnameNjj)}j]j c.__dma_fence_is_laterasbuh1hhjT ubj)}(h h]h }(hjy hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjT ubj )}(hf1h]hf1}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjT ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hu64 f2h](h)}(hhh]j )}(hu64h]hu64}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]j c.__dma_fence_is_laterasbuh1hhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubj )}(hf2h]hf2}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjhM=ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhM=ubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhM=hjhhubjA )}(hhh]h)}(h-return if f1 is chronologically later than f2h]h-return if f1 is chronologically later than f2}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM=hj hhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhM=ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j jc j jd je jf uh1jhhhjhNhNubjh )}(hX[**Parameters** ``struct dma_fence *fence`` fence in whose context to do the comparison ``u64 f1`` the first fence's seqno ``u64 f2`` the second fence's seqno from the same context **Description** Returns true if f1 is chronologically later than f2. Both fences must be from the same context, since a seqno is not common across contexts.h](h)}(h**Parameters**h]jr )}(hj h]h Parameters}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMAhj ubj )}(hhh](j )}(hH``struct dma_fence *fence`` fence in whose context to do the comparison h](j )}(h``struct dma_fence *fence``h]j)}(hj: h]hstruct dma_fence *fence}(hj< hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj8 ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM>hj4 ubj )}(hhh]h)}(h+fence in whose context to do the comparisonh]h+fence in whose context to do the comparison}(hjS hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjO hM>hjP ubah}(h]h ]h"]h$]h&]uh1j hj4 ubeh}(h]h ]h"]h$]h&]uh1j hjO hM>hj1 ubj )}(h#``u64 f1`` the first fence's seqno h](j )}(h ``u64 f1``h]j)}(hjs h]hu64 f1}(hju hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjq ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM?hjm ubj )}(hhh]h)}(hthe first fence's seqnoh]hthe first fence’s seqno}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hM?hj ubah}(h]h ]h"]h$]h&]uh1j hjm ubeh}(h]h ]h"]h$]h&]uh1j hj hM?hj1 ubj )}(h:``u64 f2`` the second fence's seqno from the same context h](j )}(h ``u64 f2``h]j)}(hj h]hu64 f2}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM@hj ubj )}(hhh]h)}(h.the second fence's seqno from the same contexth]h0the second fence’s seqno from the same context}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hM@hj ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj hM@hj1 ubeh}(h]h ]h"]h$]h&]uh1j hj ubh)}(h**Description**h]jr )}(hj h]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMBhj ubh)}(hReturns true if f1 is chronologically later than f2. Both fences must be from the same context, since a seqno is not common across contexts.h]hReturns true if f1 is chronologically later than f2. Both fences must be from the same context, since a seqno is not common across contexts.}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMAhj ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_is_later (C function)c.dma_fence_is_laterhNtauh1jhjhhhNhNubj)}(hhh](j)}(hDbool dma_fence_is_later (struct dma_fence *f1, struct dma_fence *f2)h]j)}(hCbool dma_fence_is_later(struct dma_fence *f1, struct dma_fence *f2)h](jM)}(hji5h]hbool}(hj, hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj( hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMRubj)}(h h]h }(hj: hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj( hhhj9 hMRubj )}(hdma_fence_is_laterh]j )}(hdma_fence_is_laterh]hdma_fence_is_later}(hjL hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjH ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj( hhhj9 hMRubj)}(h,(struct dma_fence *f1, struct dma_fence *f2)h](j)}(hstruct dma_fence *f1h](j)}(hjh]hstruct}(hjh hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjd ubj)}(h h]h }(hju hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjd ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]jO)}jGjN sbc.dma_fence_is_laterasbuh1hhjd ubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjd ubjd)}(hjgh]h*}(hj hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjd ubj )}(hf1h]hf1}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjd ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj` ubj)}(hstruct dma_fence *f2h](j)}(hjh]hstruct}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]j c.dma_fence_is_laterasbuh1hhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubjd)}(hjgh]h*}(hj$ hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj ubj )}(hf2h]hf2}(hj1 hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj` ubeh}(h]h ]h"]h$]h&]jjuh1jhj( hhhj9 hMRubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj$ hhhj9 hMRubah}(h]j ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj9 hMRhj! hhubjA )}(hhh]h)}(h-return if f1 is chronologically later than f2h]h-return if f1 is chronologically later than f2}(hj[ hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMRhjX hhubah}(h]h ]h"]h$]h&]uh1j@ hj! hhhj9 hMRubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb js jc js jd je jf uh1jhhhjhNhNubjh )}(hX3**Parameters** ``struct dma_fence *f1`` the first fence from the same context ``struct dma_fence *f2`` the second fence from the same context **Description** Returns true if f1 is chronologically later than f2. Both fences must be from the same context, since a seqno is not re-used across contexts.h](h)}(h**Parameters**h]jr )}(hj} h]h Parameters}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj{ ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMVhjw ubj )}(hhh](j )}(h?``struct dma_fence *f1`` the first fence from the same context h](j )}(h``struct dma_fence *f1``h]j)}(hj h]hstruct dma_fence *f1}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMShj ubj )}(hhh]h)}(h%the first fence from the same contexth]h%the first fence from the same context}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hMShj ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj hMShj ubj )}(h@``struct dma_fence *f2`` the second fence from the same context h](j )}(h``struct dma_fence *f2``h]j)}(hj h]hstruct dma_fence *f2}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMThj ubj )}(hhh]h)}(h&the second fence from the same contexth]h&the second fence from the same context}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj hMThj ubah}(h]h ]h"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]uh1j hj hMThj ubeh}(h]h ]h"]h$]h&]uh1j hjw ubh)}(h**Description**h]jr )}(hj h]h Description}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMVhjw ubh)}(hReturns true if f1 is chronologically later than f2. Both fences must be from the same context, since a seqno is not re-used across contexts.h]hReturns true if f1 is chronologically later than f2. Both fences must be from the same context, since a seqno is not re-used across contexts.}(hj& hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMUhjw ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j'dma_fence_is_later_or_same (C function)c.dma_fence_is_later_or_samehNtauh1jhjhhhNhNubj)}(hhh](j)}(hLbool dma_fence_is_later_or_same (struct dma_fence *f1, struct dma_fence *f2)h]j)}(hKbool dma_fence_is_later_or_same(struct dma_fence *f1, struct dma_fence *f2)h](jM)}(hji5h]hbool}(hjU hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjQ hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMcubj)}(h h]h }(hjc hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjQ hhhjb hMcubj )}(hdma_fence_is_later_or_sameh]j )}(hdma_fence_is_later_or_sameh]hdma_fence_is_later_or_same}(hju hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjq ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjQ hhhjb hMcubj)}(h,(struct dma_fence *f1, struct dma_fence *f2)h](j)}(hstruct dma_fence *f1h](j)}(hjh]hstruct}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]jO)}jGjw sbc.dma_fence_is_later_or_sameasbuh1hhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubjd)}(hjgh]h*}(hj hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj ubj )}(hf1h]hf1}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubj)}(hstruct dma_fence *f2h](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj!hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj#modnameN classnameNjj)}j]j c.dma_fence_is_later_or_sameasbuh1hhj ubj)}(h h]h }(hj?hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubjd)}(hjgh]h*}(hjMhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj ubj )}(hf2h]hf2}(hjZhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj ubeh}(h]h ]h"]h$]h&]jjuh1jhjQ hhhjb hMcubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjM hhhjb hMcubah}(h]jH ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjb hMchjJ hhubjA )}(hhh]h)}(h(return true if f1 is later or same as f2h]h(return true if f1 is later or same as f2}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMchjhhubah}(h]h ]h"]h$]h&]uh1j@ hjJ hhhjb hMcubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hXE**Parameters** ``struct dma_fence *f1`` the first fence from the same context ``struct dma_fence *f2`` the second fence from the same context **Description** Returns true if f1 is chronologically later than f2 or the same fence. Both fences must be from the same context, since a seqno is not re-used across contexts.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMghjubj )}(hhh](j )}(h?``struct dma_fence *f1`` the first fence from the same context h](j )}(h``struct dma_fence *f1``h]j)}(hjh]hstruct dma_fence *f1}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMdhjubj )}(hhh]h)}(h%the first fence from the same contexth]h%the first fence from the same context}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMdhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMdhjubj )}(h@``struct dma_fence *f2`` the second fence from the same context h](j )}(h``struct dma_fence *f2``h]j)}(hjh]hstruct dma_fence *f2}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMehjubj )}(hhh]h)}(h&the second fence from the same contexth]h&the second fence from the same context}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMehjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMehjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj9h]h Description}(hj;hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj7ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMghjubh)}(hReturns true if f1 is chronologically later than f2 or the same fence. Both fences must be from the same context, since a seqno is not re-used across contexts.h]hReturns true if f1 is chronologically later than f2 or the same fence. Both fences must be from the same context, since a seqno is not re-used across contexts.}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMfhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_later (C function)c.dma_fence_laterhNtauh1jhjhhhNhNubj)}(hhh](j)}(hOstruct dma_fence * dma_fence_later (struct dma_fence *f1, struct dma_fence *f2)h]j)}(hMstruct dma_fence *dma_fence_later(struct dma_fence *f1, struct dma_fence *f2)h](j)}(hjh]hstruct}(hj~hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjzhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMrubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjzhhhjhMrubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGdma_fence_latersbc.dma_fence_laterasbuh1hhjzhhhjhMrubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjzhhhjhMrubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjzhhhjhMrubj )}(hdma_fence_laterh]j )}(hjh]hdma_fence_later}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjzhhhjhMrubj)}(h,(struct dma_fence *f1, struct dma_fence *f2)h](j)}(hstruct dma_fence *f1h](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_fence_laterasbuh1hhjubj)}(h h]h }(hj4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjBhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hf1h]hf1}(hjOhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hstruct dma_fence *f2h](j)}(hjh]hstruct}(hjhhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjdubj)}(h h]h }(hjuhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjdubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jc.dma_fence_laterasbuh1hhjdubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjdubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjdubj )}(hf2h]hf2}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjdubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjzhhhjhMrubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjvhhhjhMrubah}(h]jqah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMrhjshhubjA )}(hhh]h)}(h&return the chronologically later fenceh]h&return the chronologically later fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMrhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjshhhjhMrubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hXY**Parameters** ``struct dma_fence *f1`` the first fence from the same context ``struct dma_fence *f2`` the second fence from the same context **Description** Returns NULL if both fences are signaled, otherwise the fence that would be signaled last. Both fences must be from the same context, since a seqno is not re-used across contexts.h](h)}(h**Parameters**h]jr )}(hj h]h Parameters}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMvhjubj )}(hhh](j )}(h?``struct dma_fence *f1`` the first fence from the same context h](j )}(h``struct dma_fence *f1``h]j)}(hj*h]hstruct dma_fence *f1}(hj,hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj(ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMshj$ubj )}(hhh]h)}(h%the first fence from the same contexth]h%the first fence from the same context}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1hhj?hMshj@ubah}(h]h ]h"]h$]h&]uh1j hj$ubeh}(h]h ]h"]h$]h&]uh1j hj?hMshj!ubj )}(h@``struct dma_fence *f2`` the second fence from the same context h](j )}(h``struct dma_fence *f2``h]j)}(hjch]hstruct dma_fence *f2}(hjehhhNhNubah}(h]h ]h"]h$]h&]uh1jhjaubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMthj]ubj )}(hhh]h)}(h&the second fence from the same contexth]h&the second fence from the same context}(hj|hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjxhMthjyubah}(h]h ]h"]h$]h&]uh1j hj]ubeh}(h]h ]h"]h$]h&]uh1j hjxhMthj!ubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMvhjubh)}(hReturns NULL if both fences are signaled, otherwise the fence that would be signaled last. Both fences must be from the same context, since a seqno is not re-used across contexts.h]hReturns NULL if both fences are signaled, otherwise the fence that would be signaled last. Both fences must be from the same context, since a seqno is not re-used across contexts.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMuhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j(dma_fence_get_status_locked (C function)c.dma_fence_get_status_lockedhNtauh1jhjhhhNhNubj)}(hhh](j)}(h9int dma_fence_get_status_locked (struct dma_fence *fence)h]j)}(h8int dma_fence_get_status_locked(struct dma_fence *fence)h](jM)}(hinth]hint}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(hdma_fence_get_status_lockedh]j )}(hdma_fence_get_status_lockedh]hdma_fence_get_status_locked}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj-hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj;ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj@modnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_get_status_lockedasbuh1hhjubj)}(h h]h }(hj^hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjlhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hjyhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h"returns the status upon completionh]h"returns the status upon completion}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX\**Parameters** ``struct dma_fence *fence`` the dma_fence to query **Description** Drivers can supply an optional error status condition before they signal the fence (to indicate whether the fence was completed due to an error rather than success). The value of the status condition is only valid if the fence has been signaled, dma_fence_get_status_locked() first checks the signal state before reporting the error status. Returns 0 if the fence has not yet been signaled, 1 if the fence has been signaled without an error condition, or a negative error code if the fence has been completed in err.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]j )}(h3``struct dma_fence *fence`` the dma_fence to query h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(hthe dma_fence to queryh]hthe dma_fence to query}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hXTDrivers can supply an optional error status condition before they signal the fence (to indicate whether the fence was completed due to an error rather than success). The value of the status condition is only valid if the fence has been signaled, dma_fence_get_status_locked() first checks the signal state before reporting the error status.h]hXTDrivers can supply an optional error status condition before they signal the fence (to indicate whether the fence was completed due to an error rather than success). The value of the status condition is only valid if the fence has been signaled, dma_fence_get_status_locked() first checks the signal state before reporting the error status.}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hReturns 0 if the fence has not yet been signaled, 1 if the fence has been signaled without an error condition, or a negative error code if the fence has been completed in err.h]hReturns 0 if the fence has not yet been signaled, 1 if the fence has been signaled without an error condition, or a negative error code if the fence has been completed in err.}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j dma_fence_set_error (C function)c.dma_fence_set_errorhNtauh1jhjhhhNhNubj)}(hhh](j)}(h=void dma_fence_set_error (struct dma_fence *fence, int error)h]j)}(hhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjohhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjkhhhjhMubah}(h]jfah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhhubjA )}(hhh]h)}(h$flag an error condition on the fenceh]h$flag an error condition on the fence}(hjhhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjehhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence *fence`` the dma_fence ``int error`` the error to store **Description** Drivers can supply an optional error status condition before they signal the fence, to indicate that the fence was completed due to an error rather than success. This must be set before signaling (so that the value is visible before any waiters on the signal callback are woken). This helper exists to help catching erroneous setting of #dma_fence.error. Examples of error codes which drivers should use: * ``-ENODATA`` This operation produced no data, no other operation affected. * ``-ECANCELED`` All operations from the same context have been canceled. * ``-ETIME`` Operation caused a timeout and potentially device reset.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh](j )}(h*``struct dma_fence *fence`` the dma_fence h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(h the dma_fenceh]h the dma_fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubj )}(h!``int error`` the error to store h](j )}(h ``int error``h]j)}(hjh]h int error}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(hthe error to storeh]hthe error to store}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hXbDrivers can supply an optional error status condition before they signal the fence, to indicate that the fence was completed due to an error rather than success. This must be set before signaling (so that the value is visible before any waiters on the signal callback are woken). This helper exists to help catching erroneous setting of #dma_fence.error.h]hXbDrivers can supply an optional error status condition before they signal the fence, to indicate that the fence was completed due to an error rather than success. This must be set before signaling (so that the value is visible before any waiters on the signal callback are woken). This helper exists to help catching erroneous setting of #dma_fence.error.}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(h1Examples of error codes which drivers should use:h]h1Examples of error codes which drivers should use:}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hhh](j)}(hL``-ENODATA`` This operation produced no data, no other operation affected.h]h)}(hjVh](j)}(h ``-ENODATA``h]h-ENODATA}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjXubh@ This operation produced no data, no other operation affected.}(hjXhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjTubah}(h]h ]h"]h$]h&]uh1jhjQubj)}(hG``-ECANCELED`` All operations from the same context have been canceled.h]h)}(hj|h](j)}(h``-ECANCELED``h]h -ECANCELED}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj~ubh9 All operations from the same context have been canceled.}(hj~hhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjzubah}(h]h ]h"]h$]h&]uh1jhjQubj)}(hG``-ETIME`` Operation caused a timeout and potentially device reset.h]h)}(hjh](j)}(h ``-ETIME``h]h-ETIME}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubh= Operation caused a timeout and potentially device reset.}(hjhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubah}(h]h ]h"]h$]h&]uh1jhjQubeh}(h]h ]h"]h$]h&]jRjguh1hhjshMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j dma_fence_timestamp (C function)c.dma_fence_timestamphNtauh1jhjhhhNhNubj)}(hhh](j)}(h5ktime_t dma_fence_timestamp (struct dma_fence *fence)h]j)}(h4ktime_t dma_fence_timestamp(struct dma_fence *fence)h](h)}(hhh]j )}(hktime_th]hktime_t}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGdma_fence_timestampsbc.dma_fence_timestampasbuh1hhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(hdma_fence_timestamph]j )}(hj h]hdma_fence_timestamp}(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj>hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj:ubj)}(h h]h }(hjKhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj:ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj\hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjYubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj^modnameN classnameNjj)}j]j c.dma_fence_timestampasbuh1hhj:ubj)}(h h]h }(hjzhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj:ubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj:ubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj:ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj6ubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h1helper to get the completion timestamp of a fenceh]h1helper to get the completion timestamp of a fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX1**Parameters** ``struct dma_fence *fence`` fence to get the timestamp from. **Description** After a fence is signaled the timestamp is updated with the signaling time, but setting the timestamp can race with tasks waiting for the signaling. This helper busy waits for the correct timestamp to appear.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]j )}(h=``struct dma_fence *fence`` fence to get the timestamp from. h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(h fence to get the timestamp from.h]h fence to get the timestamp from.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj;h]h Description}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj9ubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hAfter a fence is signaled the timestamp is updated with the signaling time, but setting the timestamp can race with tasks waiting for the signaling. This helper busy waits for the correct timestamp to appear.h]hAfter a fence is signaled the timestamp is updated with the signaling time, but setting the timestamp can race with tasks waiting for the signaling. This helper busy waits for the correct timestamp to appear.}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_wait (C function)c.dma_fence_waithNtauh1jhjhhhNhNubj)}(hhh](j)}(h?signed long dma_fence_wait (struct dma_fence *fence, bool intr)h]j)}(h>signed long dma_fence_wait(struct dma_fence *fence, bool intr)h](jM)}(hsignedh]hsigned}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj|hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj|hhhjhMubjM)}(hlongh]hlong}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj|hhhjhMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj|hhhjhMubj )}(hdma_fence_waith]j )}(hdma_fence_waith]hdma_fence_wait}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj|hhhjhMubj)}(h$(struct dma_fence *fence, bool intr)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_waitasbuh1hhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj%hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hj2hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h bool intrh](jM)}(hji5h]hbool}(hjKhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjGubj)}(h h]h }(hjXhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjGubj )}(hintrh]hintr}(hjfhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjGubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhj|hhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjxhhhjhMubah}(h]jsah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjuhhubjA )}(hhh]h)}(h#sleep until the fence gets signaledh]h#sleep until the fence gets signaled}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjuhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX<**Parameters** ``struct dma_fence *fence`` the fence to wait on ``bool intr`` if true, do an interruptible wait **Description** This function will return -ERESTARTSYS if interrupted by a signal, or 0 if the fence was signaled. Other error values may be returned on custom implementations. Performs a synchronous wait on this fence. It is assumed the caller directly or indirectly holds a reference to the fence, otherwise the fence might be freed before return, resulting in undefined behavior. See also dma_fence_wait_timeout() and dma_fence_wait_any_timeout().h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh](j )}(h1``struct dma_fence *fence`` the fence to wait on h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(hthe fence to wait onh]hthe fence to wait on}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubj )}(h0``bool intr`` if true, do an interruptible wait h](j )}(h ``bool intr``h]j)}(hj h]h bool intr}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(h!if true, do an interruptible waith]h!if true, do an interruptible wait}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhj ubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubeh}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjEh]h Description}(hjGhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjCubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hThis function will return -ERESTARTSYS if interrupted by a signal, or 0 if the fence was signaled. Other error values may be returned on custom implementations.h]hThis function will return -ERESTARTSYS if interrupted by a signal, or 0 if the fence was signaled. Other error values may be returned on custom implementations.}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hPerforms a synchronous wait on this fence. It is assumed the caller directly or indirectly holds a reference to the fence, otherwise the fence might be freed before return, resulting in undefined behavior.h]hPerforms a synchronous wait on this fence. It is assumed the caller directly or indirectly holds a reference to the fence, otherwise the fence might be freed before return, resulting in undefined behavior.}(hjjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hCSee also dma_fence_wait_timeout() and dma_fence_wait_any_timeout().h]hCSee also dma_fence_wait_timeout() and dma_fence_wait_any_timeout().}(hjyhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_is_array (C function)c.dma_fence_is_arrayhNtauh1jhjhhhNhNubj)}(hhh](j)}(h1bool dma_fence_is_array (struct dma_fence *fence)h]j)}(h0bool dma_fence_is_array(struct dma_fence *fence)h](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(hdma_fence_is_arrayh]j )}(hdma_fence_is_arrayh]hdma_fence_is_array}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_is_arrayasbuh1hhjubj)}(h h]h }(hj"hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj0hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h+check if a fence is from the array subclassh]h+check if a fence is from the array subclass}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjdhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` the fence to test **Description** Return true if it is a dma_fence_array and false otherwise.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]j )}(h.``struct dma_fence *fence`` the fence to test h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(hthe fence to testh]hthe fence to test}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(h;Return true if it is a dma_fence_array and false otherwise.h]h;Return true if it is a dma_fence_array and false otherwise.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_is_chain (C function)c.dma_fence_is_chainhNtauh1jhjhhhNhNubj)}(hhh](j)}(h1bool dma_fence_is_chain (struct dma_fence *fence)h]j)}(h0bool dma_fence_is_chain(struct dma_fence *fence)h](jM)}(hji5h]hbool}(hj(hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj$hhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubj)}(h h]h }(hj6hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj$hhhj5hMubj )}(hdma_fence_is_chainh]j )}(hdma_fence_is_chainh]hdma_fence_is_chain}(hjHhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjDubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj$hhhj5hMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjdhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj`ubj)}(h h]h }(hjqhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj`ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjJsbc.dma_fence_is_chainasbuh1hhj`ubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj`ubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj`ubj )}(hfenceh]hfence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj`ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj\ubah}(h]h ]h"]h$]h&]jjuh1jhj$hhhj5hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj hhhj5hMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj5hMhjhhubjA )}(hhh]h)}(h+check if a fence is from the chain subclassh]h+check if a fence is from the chain subclass}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhj5hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` the fence to test **Description** Return true if it is a dma_fence_chain and false otherwise.h](h)}(h**Parameters**h]jr )}(hj h]h Parameters}(hj hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM hjubj )}(hhh]j )}(h.``struct dma_fence *fence`` the fence to test h](j )}(h``struct dma_fence *fence``h]j)}(hj(h]hstruct dma_fence *fence}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj&ubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM hj"ubj )}(hhh]h)}(hthe fence to testh]hthe fence to test}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj=hM hj>ubah}(h]h ]h"]h$]h&]uh1j hj"ubeh}(h]h ]h"]h$]h&]uh1j hj=hM hjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjch]h Description}(hjehhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjaubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM hjubh)}(h;Return true if it is a dma_fence_chain and false otherwise.h]h;Return true if it is a dma_fence_chain and false otherwise.}(hjyhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhM hjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_fence_is_container (C function)c.dma_fence_is_containerhNtauh1jhjhhhNhNubj)}(hhh](j)}(h5bool dma_fence_is_container (struct dma_fence *fence)h]j)}(h4bool dma_fence_is_container(struct dma_fence *fence)h](jM)}(hji5h]hbool}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhMubj )}(hdma_fence_is_containerh]j )}(hdma_fence_is_containerh]hdma_fence_is_container}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhMubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjmodnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_is_containerasbuh1hhjubj)}(h h]h }(hj"hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hj0hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(hfenceh]hfence}(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhjhhhjhMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhMubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhMhjhhubjA )}(hhh]h)}(h0check if a fence is a container for other fencesh]h0check if a fence is a container for other fences}(hjghhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjdhhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(hX"**Parameters** ``struct dma_fence *fence`` the fence to test **Description** Return true if this fence is a container for other fences, false otherwise. This is important since we can't build up large fence structure or otherwise we run into recursion during operation on those fences.h](h)}(h**Parameters**h]jr )}(hjh]h Parameters}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]j )}(h.``struct dma_fence *fence`` the fence to test h](j )}(h``struct dma_fence *fence``h]j)}(hjh]hstruct dma_fence *fence}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjubah}(h]h ]h"]h$]h&]uh1j h]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubj )}(hhh]h)}(hthe fence to testh]hthe fence to test}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]uh1j hjhMhjubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hjh]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubh)}(hReturn true if this fence is a container for other fences, false otherwise. This is important since we can't build up large fence structure or otherwise we run into recursion during operation on those fences.h]hReturn true if this fence is a container for other fences, false otherwise. This is important since we can’t build up large fence structure or otherwise we run into recursion during operation on those fences.}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:190: ./include/linux/dma-fence.hhMhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubeh}(h]dma-fences-functions-referenceah ]h"]dma fences functions referenceah$]h&]uh1hhjhhhhhKubh)}(hhh](h)}(hDMA Fence Arrayh]hDMA Fence Array}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjhhhhhKubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j"dma_fence_array_alloc (C function)c.dma_fence_array_allochNtauh1jhjhhhNhNubj)}(hhh](j)}(h?struct dma_fence_array * dma_fence_array_alloc (int num_fences)h]j)}(h=struct dma_fence_array *dma_fence_array_alloc(int num_fences)h](j)}(hjh]hstruct}(hjAhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj=hhhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKubj)}(h h]h }(hjOhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj=hhhjNhKubh)}(hhh]j )}(hdma_fence_arrayh]hdma_fence_array}(hj`hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj]ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjbmodnameN classnameNjj)}j]jO)}jGdma_fence_array_allocsbc.dma_fence_array_allocasbuh1hhj=hhhjNhKubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj=hhhjNhKubjd)}(hjgh]h*}(hjhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj=hhhjNhKubj )}(hdma_fence_array_alloch]j )}(hj~h]hdma_fence_array_alloc}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj=hhhjNhKubj)}(h(int num_fences)h]j)}(hint num_fencesh](jM)}(hinth]hint}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubj )}(h num_fencesh]h num_fences}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubah}(h]h ]h"]h$]h&]jjuh1jhj=hhhjNhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj9hhhjNhKubah}(h]j4ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjNhKhj6hhubjA )}(hhh]h)}(hAllocate a custom fence arrayh]hAllocate a custom fence array}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhjhhubah}(h]h ]h"]h$]h&]uh1j@ hj6hhhjNhKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jjc jjd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``int num_fences`` [in] number of fences to add in the array **Description** Return dma fence array on success, NULL on failureh](h)}(h**Parameters**h]jr )}(hj#h]h Parameters}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj!ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhjubj )}(hhh]j )}(h@``int num_fences`` [in] number of fences to add in the array h](j )}(h``int num_fences``h]j)}(hjBh]hint num_fences}(hjDhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj@ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj<ubj )}(hhh]h)}(h,[in] number of fences to add in the arrayh]h,[in] number of fences to add in the array}(hj[hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjWhKhjXubah}(h]h ]h"]h$]h&]uh1j hj<ubeh}(h]h ]h"]h$]h&]uh1j hjWhKhj9ubah}(h]h ]h"]h$]h&]uh1j hjubh)}(h**Description**h]jr )}(hj}h]h Description}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj{ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhjubh)}(h2Return dma fence array on success, NULL on failureh]h2Return dma fence array on success, NULL on failure}(hjhhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhjubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j!dma_fence_array_init (C function)c.dma_fence_array_inithNtauh1jhjhhhNhNubj)}(hhh](j)}(hvoid dma_fence_array_init (struct dma_fence_array *array, int num_fences, struct dma_fence **fences, u64 context, unsigned seqno)h]j)}(hvoid dma_fence_array_init(struct dma_fence_array *array, int num_fences, struct dma_fence **fences, u64 context, unsigned seqno)h](jM)}(hvoidh]hvoid}(hjhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjhhhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKubj)}(h h]h }(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjhhhjhKubj )}(hdma_fence_array_inith]j )}(hdma_fence_array_inith]hdma_fence_array_init}(hjhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjhhhjhKubj)}(hg(struct dma_fence_array *array, int num_fences, struct dma_fence **fences, u64 context, unsigned seqno)h](j)}(hstruct dma_fence_array *arrayh](j)}(hjh]hstruct}(hjhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubh)}(hhh]j )}(hdma_fence_arrayh]hdma_fence_array}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]jO)}jGjsbc.dma_fence_array_initasbuh1hhjubj)}(h h]h }(hj= hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjubjd)}(hjgh]h*}(hjK hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjubj )}(harrayh]harray}(hjX hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hint num_fencesh](jM)}(hinth]hint}(hjq hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjm ubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjm ubj )}(h num_fencesh]h num_fences}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjm ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hstruct dma_fence **fencesh](j)}(hjh]hstruct}(hj hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj modnameN classnameNjj)}j]j9 c.dma_fence_array_initasbuh1hhj ubj)}(h h]h }(hj hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj ubjd)}(hjgh]h*}(hj hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj ubjd)}(hjgh]h*}(hj hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj ubj )}(hfencesh]hfences}(hj !hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(h u64 contexth](h)}(hhh]j )}(hu64h]hu64}(hj&!hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj#!ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj(!modnameN classnameNjj)}j]j9 c.dma_fence_array_initasbuh1hhj!ubj)}(h h]h }(hjD!hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj!ubj )}(hcontexth]hcontext}(hjR!hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj!ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubj)}(hunsigned seqnoh](jM)}(hunsignedh]hunsigned}(hjk!hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjg!ubj)}(h h]h }(hjy!hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjg!ubj )}(hseqnoh]hseqno}(hj!hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjg!ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjubeh}(h]h ]h"]h$]h&]jjuh1jhjhhhjhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjhhhjhKubah}(h]jah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjhKhjhhubjA )}(hhh]h)}(hInit a custom fence arrayh]hInit a custom fence array}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj!hhubah}(h]h ]h"]h$]h&]uh1j@ hjhhhjhKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j!jc j!jd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``struct dma_fence_array *array`` [in] dma fence array to arm ``int num_fences`` [in] number of fences to add in the array ``struct dma_fence **fences`` [in] array containing the fences ``u64 context`` [in] fence context to use ``unsigned seqno`` [in] sequence number to use **Description** Implementation of **dma_fence_array_create** without allocation. Useful to init a preallocated dma fence array in the path of reclaim or dma fence signaling.h](h)}(h**Parameters**h]jr )}(hj!h]h Parameters}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj!ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj!ubj )}(hhh](j )}(hA``struct dma_fence_array *array`` [in] dma fence array to arm h](j )}(h!``struct dma_fence_array *array``h]j)}(hj!h]hstruct dma_fence_array *array}(hj!hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj!ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj!ubj )}(hhh]h)}(h[in] dma fence array to armh]h[in] dma fence array to arm}(hj "hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj"hKhj"ubah}(h]h ]h"]h$]h&]uh1j hj!ubeh}(h]h ]h"]h$]h&]uh1j hj"hKhj!ubj )}(h@``int num_fences`` [in] number of fences to add in the array h](j )}(h``int num_fences``h]j)}(hj+"h]hint num_fences}(hj-"hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj)"ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj%"ubj )}(hhh]h)}(h,[in] number of fences to add in the arrayh]h,[in] number of fences to add in the array}(hjD"hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj@"hKhjA"ubah}(h]h ]h"]h$]h&]uh1j hj%"ubeh}(h]h ]h"]h$]h&]uh1j hj@"hKhj!ubj )}(hB``struct dma_fence **fences`` [in] array containing the fences h](j )}(h``struct dma_fence **fences``h]j)}(hjd"h]hstruct dma_fence **fences}(hjf"hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjb"ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj^"ubj )}(hhh]h)}(h#[in] array containing the fencesh]h#[in] array containing the fences}(hj}"hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjy"hKhjz"ubah}(h]h ]h"]h$]h&]uh1j hj^"ubeh}(h]h ]h"]h$]h&]uh1j hjy"hKhj!ubj )}(h-``u64 context`` [in] fence context to use h](j )}(h``u64 context``h]j)}(hj"h]h u64 context}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj"ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj"ubj )}(hhh]h)}(h[in] fence context to useh]h[in] fence context to use}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj"hKhj"ubah}(h]h ]h"]h$]h&]uh1j hj"ubeh}(h]h ]h"]h$]h&]uh1j hj"hKhj!ubj )}(h2``unsigned seqno`` [in] sequence number to use h](j )}(h``unsigned seqno``h]j)}(hj"h]hunsigned seqno}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj"ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj"ubj )}(hhh]h)}(h[in] sequence number to useh]h[in] sequence number to use}(hj"hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj"hKhj"ubah}(h]h ]h"]h$]h&]uh1j hj"ubeh}(h]h ]h"]h$]h&]uh1j hj"hKhj!ubeh}(h]h ]h"]h$]h&]uh1j hj!ubh)}(h**Description**h]jr )}(hj#h]h Description}(hj#hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj#ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj!ubh)}(hImplementation of **dma_fence_array_create** without allocation. Useful to init a preallocated dma fence array in the path of reclaim or dma fence signaling.h](hImplementation of }(hj'#hhhNhNubjr )}(h**dma_fence_array_create**h]hdma_fence_array_create}(hj/#hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj'#ubhq without allocation. Useful to init a preallocated dma fence array in the path of reclaim or dma fence signaling.}(hj'#hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj!ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j#dma_fence_array_create (C function)c.dma_fence_array_createhNtauh1jhjhhhNhNubj)}(hhh](j)}(hxstruct dma_fence_array * dma_fence_array_create (int num_fences, struct dma_fence **fences, u64 context, unsigned seqno)h]j)}(hvstruct dma_fence_array *dma_fence_array_create(int num_fences, struct dma_fence **fences, u64 context, unsigned seqno)h](j)}(hjh]hstruct}(hjh#hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjd#hhhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKubj)}(h h]h }(hjv#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjd#hhhju#hKubh)}(hhh]j )}(hdma_fence_arrayh]hdma_fence_array}(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj#ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj#modnameN classnameNjj)}j]jO)}jGdma_fence_array_createsbc.dma_fence_array_createasbuh1hhjd#hhhju#hKubj)}(h h]h }(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjd#hhhju#hKubjd)}(hjgh]h*}(hj#hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjd#hhhju#hKubj )}(hdma_fence_array_createh]j )}(hj#h]hdma_fence_array_create}(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj#ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjd#hhhju#hKubj)}(hH(int num_fences, struct dma_fence **fences, u64 context, unsigned seqno)h](j)}(hint num_fencesh](jM)}(hinth]hint}(hj#hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj#ubj)}(h h]h }(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj#ubj )}(h num_fencesh]h num_fences}(hj#hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj#ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj#ubj)}(hstruct dma_fence **fencesh](j)}(hjh]hstruct}(hj$hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj$ubj)}(h h]h }(hj$$hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj$ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj5$hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj2$ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj7$modnameN classnameNjj)}j]j#c.dma_fence_array_createasbuh1hhj$ubj)}(h h]h }(hjS$hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj$ubjd)}(hjgh]h*}(hja$hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj$ubjd)}(hjgh]h*}(hjn$hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj$ubj )}(hfencesh]hfences}(hj{$hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj$ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj#ubj)}(h u64 contexth](h)}(hhh]j )}(hu64h]hu64}(hj$hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj$ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj$modnameN classnameNjj)}j]j#c.dma_fence_array_createasbuh1hhj$ubj)}(h h]h }(hj$hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj$ubj )}(hcontexth]hcontext}(hj$hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj$ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj#ubj)}(hunsigned seqnoh](jM)}(hunsignedh]hunsigned}(hj$hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj$ubj)}(h h]h }(hj$hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj$ubj )}(hseqnoh]hseqno}(hj$hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj$ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj#ubeh}(h]h ]h"]h$]h&]jjuh1jhjd#hhhju#hKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj`#hhhju#hKubah}(h]j[#ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhju#hKhj]#hhubjA )}(hhh]h)}(hCreate a custom fence arrayh]hCreate a custom fence array}(hj"%hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj%hhubah}(h]h ]h"]h$]h&]uh1j@ hj]#hhhju#hKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j:%jc j:%jd je jf uh1jhhhjhNhNubjh )}(hX**Parameters** ``int num_fences`` [in] number of fences to add in the array ``struct dma_fence **fences`` [in] array containing the fences ``u64 context`` [in] fence context to use ``unsigned seqno`` [in] sequence number to use **Description** Allocate a dma_fence_array object and initialize the base fence with dma_fence_init(). In case of error it returns NULL. The caller should allocate the fences array with num_fences size and fill it with the fences it wants to add to the object. Ownership of this array is taken and dma_fence_put() is used on each fence on release. If **signal_on_any** is true the fence array signals if any fence in the array signals, otherwise it signals when all fences in the array signal.h](h)}(h**Parameters**h]jr )}(hjD%h]h Parameters}(hjF%hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjB%ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj>%ubj )}(hhh](j )}(h@``int num_fences`` [in] number of fences to add in the array h](j )}(h``int num_fences``h]j)}(hjc%h]hint num_fences}(hje%hhhNhNubah}(h]h ]h"]h$]h&]uh1jhja%ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj]%ubj )}(hhh]h)}(h,[in] number of fences to add in the arrayh]h,[in] number of fences to add in the array}(hj|%hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjx%hKhjy%ubah}(h]h ]h"]h$]h&]uh1j hj]%ubeh}(h]h ]h"]h$]h&]uh1j hjx%hKhjZ%ubj )}(hB``struct dma_fence **fences`` [in] array containing the fences h](j )}(h``struct dma_fence **fences``h]j)}(hj%h]hstruct dma_fence **fences}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj%ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj%ubj )}(hhh]h)}(h#[in] array containing the fencesh]h#[in] array containing the fences}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj%hKhj%ubah}(h]h ]h"]h$]h&]uh1j hj%ubeh}(h]h ]h"]h$]h&]uh1j hj%hKhjZ%ubj )}(h-``u64 context`` [in] fence context to use h](j )}(h``u64 context``h]j)}(hj%h]h u64 context}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj%ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj%ubj )}(hhh]h)}(h[in] fence context to useh]h[in] fence context to use}(hj%hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj%hKhj%ubah}(h]h ]h"]h$]h&]uh1j hj%ubeh}(h]h ]h"]h$]h&]uh1j hj%hKhjZ%ubj )}(h2``unsigned seqno`` [in] sequence number to use h](j )}(h``unsigned seqno``h]j)}(hj&h]hunsigned seqno}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj &ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj&ubj )}(hhh]h)}(h[in] sequence number to useh]h[in] sequence number to use}(hj'&hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj#&hKhj$&ubah}(h]h ]h"]h$]h&]uh1j hj&ubeh}(h]h ]h"]h$]h&]uh1j hj#&hKhjZ%ubeh}(h]h ]h"]h$]h&]uh1j hj>%ubh)}(h**Description**h]jr )}(hjI&h]h Description}(hjK&hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjG&ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj>%ubh)}(hxAllocate a dma_fence_array object and initialize the base fence with dma_fence_init(). In case of error it returns NULL.h]hxAllocate a dma_fence_array object and initialize the base fence with dma_fence_init(). In case of error it returns NULL.}(hj_&hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj>%ubh)}(hThe caller should allocate the fences array with num_fences size and fill it with the fences it wants to add to the object. Ownership of this array is taken and dma_fence_put() is used on each fence on release.h]hThe caller should allocate the fences array with num_fences size and fill it with the fences it wants to add to the object. Ownership of this array is taken and dma_fence_put() is used on each fence on release.}(hjn&hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chKhj>%ubh)}(hIf **signal_on_any** is true the fence array signals if any fence in the array signals, otherwise it signals when all fences in the array signal.h](hIf }(hj}&hhhNhNubjr )}(h**signal_on_any**h]h signal_on_any}(hj&hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj}&ubh} is true the fence array signals if any fence in the array signals, otherwise it signals when all fences in the array signal.}(hj}&hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chMhj>%ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j$dma_fence_match_context (C function)c.dma_fence_match_contexthNtauh1jhjhhhNhNubj)}(hhh](j)}(hCbool dma_fence_match_context (struct dma_fence *fence, u64 context)h]j)}(hBbool dma_fence_match_context(struct dma_fence *fence, u64 context)h](jM)}(hji5h]hbool}(hj&hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj&hhhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chMubj)}(h h]h }(hj&hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj&hhhj&hMubj )}(hdma_fence_match_contexth]j )}(hdma_fence_match_contexth]hdma_fence_match_context}(hj&hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj&ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj&hhhj&hMubj)}(h&(struct dma_fence *fence, u64 context)h](j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj&hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj&ubj)}(h h]h }(hj'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj&ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj'ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj'modnameN classnameNjj)}j]jO)}jGj&sbc.dma_fence_match_contextasbuh1hhj&ubj)}(h h]h }(hj8'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj&ubjd)}(hjgh]h*}(hjF'hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj&ubj )}(hfenceh]hfence}(hjS'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj&ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj&ubj)}(h u64 contexth](h)}(hhh]j )}(hu64h]hu64}(hjo'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjl'ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjq'modnameN classnameNjj)}j]j4'c.dma_fence_match_contextasbuh1hhjh'ubj)}(h h]h }(hj'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjh'ubj )}(hcontexth]hcontext}(hj'hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjh'ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj&ubeh}(h]h ]h"]h$]h&]jjuh1jhj&hhhj&hMubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj&hhhj&hMubah}(h]j&ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj&hMhj&hhubjA )}(hhh]h)}(h.Check if all fences are from the given contexth]h.Check if all fences are from the given context}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chMhj'hhubah}(h]h ]h"]h$]h&]uh1j@ hj&hhhj&hMubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j'jc j'jd je jf uh1jhhhjhNhNubjh )}(hX=**Parameters** ``struct dma_fence *fence`` [in] fence or fence array ``u64 context`` [in] fence context to check all fences against **Description** Checks the provided fence or, for a fence array, all fences in the array against the given context. Returns false if any fence is from a different context.h](h)}(h**Parameters**h]jr )}(hj'h]h Parameters}(hj'hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj'ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chMhj'ubj )}(hhh](j )}(h9``struct dma_fence *fence`` [in] fence or fence array h](j )}(h``struct dma_fence *fence``h]j)}(hj(h]hstruct dma_fence *fence}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj(ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chMhj(ubj )}(hhh]h)}(h[in] fence or fence arrayh]h[in] fence or fence array}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj(hMhj(ubah}(h]h ]h"]h$]h&]uh1j hj(ubeh}(h]h ]h"]h$]h&]uh1j hj(hMhj'ubj )}(hB``u64 context`` [in] fence context to check all fences against h](j )}(h``u64 context``h]j)}(hj?(h]h u64 context}(hjA(hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj=(ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chMhj9(ubj )}(hhh]h)}(h1[in] fence context to check all fences againsth]h1[in] fence context to check all fences against}(hjX(hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjT(hMhjU(ubah}(h]h ]h"]h$]h&]uh1j hj9(ubeh}(h]h ]h"]h$]h&]uh1j hjT(hMhj'ubeh}(h]h ]h"]h$]h&]uh1j hj'ubh)}(h**Description**h]jr )}(hjz(h]h Description}(hj|(hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjx(ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chMhj'ubh)}(hChecks the provided fence or, for a fence array, all fences in the array against the given context. Returns false if any fence is from a different context.h]hChecks the provided fence or, for a fence array, all fences in the array against the given context. Returns false if any fence is from a different context.}(hj(hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:196: ./drivers/dma-buf/dma-fence-array.chMhj'ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_array_cb (C struct)c.dma_fence_array_cbhNtauh1jhjhhhNhNubj)}(hhh](j)}(hdma_fence_array_cbh]j)}(hstruct dma_fence_array_cbh](j)}(hjh]hstruct}(hj(hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj(hhhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKubj)}(h h]h }(hj(hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj(hhhj(hKubj )}(hdma_fence_array_cbh]j )}(hj(h]hdma_fence_array_cb}(hj(hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj(ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj(hhhj(hKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj(hhhj(hKubah}(h]j(ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj(hKhj(hhubjA )}(hhh]h)}(hcallback helper for fence arrayh]hcallback helper for fence array}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKhj(hhubah}(h]h ]h"]h$]h&]uh1j@ hj(hhhj(hKubeh}(h]h ](jstructeh"]h$]h&]ja jjb j)jc j)jd je jf uh1jhhhjhNhNubjh )}(h**Definition**:: struct dma_fence_array_cb { struct dma_fence_cb cb; struct dma_fence_array *array; }; **Members** ``cb`` fence callback structure for signaling ``array`` reference to the parent fence array objecth](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hj%)hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj!)ubh:}(hj!)hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKhj)ubj)}(h]struct dma_fence_array_cb { struct dma_fence_cb cb; struct dma_fence_array *array; };h]h]struct dma_fence_array_cb { struct dma_fence_cb cb; struct dma_fence_array *array; };}hj>)sbah}(h]h ]h"]h$]h&]jjuh1jhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKhj)ubh)}(h **Members**h]jr )}(hjO)h]hMembers}(hjQ)hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjM)ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKhj)ubj )}(hhh](j )}(h.``cb`` fence callback structure for signaling h](j )}(h``cb``h]j)}(hjn)h]hcb}(hjp)hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjl)ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKhjh)ubj )}(hhh]h)}(h&fence callback structure for signalingh]h&fence callback structure for signaling}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj)hKhj)ubah}(h]h ]h"]h$]h&]uh1j hjh)ubeh}(h]h ]h"]h$]h&]uh1j hj)hKhje)ubj )}(h4``array`` reference to the parent fence array objecth](j )}(h ``array``h]j)}(hj)h]harray}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj)ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKhj)ubj )}(hhh]h)}(h*reference to the parent fence array objecth]h*reference to the parent fence array object}(hj)hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKhj)ubah}(h]h ]h"]h$]h&]uh1j hj)ubeh}(h]h ]h"]h$]h&]uh1j hj)hKhje)ubeh}(h]h ]h"]h$]h&]uh1j hj)ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_array (C struct)c.dma_fence_arrayhNtauh1jhjhhhNhNubj)}(hhh](j)}(hdma_fence_arrayh]j)}(hstruct dma_fence_arrayh](j)}(hjh]hstruct}(hj*hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj)hhhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKubj)}(h h]h }(hj*hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj)hhhj*hKubj )}(hdma_fence_arrayh]j )}(hj)h]hdma_fence_array}(hj!*hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj*ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj)hhhj*hKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj)hhhj*hKubah}(h]j)ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj*hKhj)hhubjA )}(hhh]h)}(h%fence to represent an array of fencesh]h%fence to represent an array of fences}(hjC*hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKhj@*hhubah}(h]h ]h"]h$]h&]uh1j@ hj)hhhj*hKubeh}(h]h ](jstructeh"]h$]h&]ja jjb j[*jc j[*jd je jf uh1jhhhjhNhNubjh )}(hX**Definition**:: struct dma_fence_array { struct dma_fence base; unsigned num_fences; atomic_t num_pending; struct dma_fence **fences; struct irq_work work; struct dma_fence_array_cb callbacks[]; }; **Members** ``base`` fence base class ``num_fences`` number of fences in the array ``num_pending`` fences in the array still pending ``fences`` array of the fences ``work`` internal irq_work function ``callbacks`` array of callback helpersh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjg*hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjc*ubh:}(hjc*hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK!hj_*ubj)}(hstruct dma_fence_array { struct dma_fence base; unsigned num_fences; atomic_t num_pending; struct dma_fence **fences; struct irq_work work; struct dma_fence_array_cb callbacks[]; };h]hstruct dma_fence_array { struct dma_fence base; unsigned num_fences; atomic_t num_pending; struct dma_fence **fences; struct irq_work work; struct dma_fence_array_cb callbacks[]; };}hj*sbah}(h]h ]h"]h$]h&]jjuh1jhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK#hj_*ubh)}(h **Members**h]jr )}(hj*h]hMembers}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj*ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK,hj_*ubj )}(hhh](j )}(h``base`` fence base class h](j )}(h``base``h]j)}(hj*h]hbase}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj*ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKhj*ubj )}(hhh]h)}(hfence base classh]hfence base class}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj*hKhj*ubah}(h]h ]h"]h$]h&]uh1j hj*ubeh}(h]h ]h"]h$]h&]uh1j hj*hKhj*ubj )}(h-``num_fences`` number of fences in the array h](j )}(h``num_fences``h]j)}(hj*h]h num_fences}(hj*hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj*ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK hj*ubj )}(hhh]h)}(hnumber of fences in the arrayh]hnumber of fences in the array}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj*hK hj*ubah}(h]h ]h"]h$]h&]uh1j hj*ubeh}(h]h ]h"]h$]h&]uh1j hj*hK hj*ubj )}(h2``num_pending`` fences in the array still pending h](j )}(h``num_pending``h]j)}(hj"+h]h num_pending}(hj$+hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj +ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK!hj+ubj )}(hhh]h)}(h!fences in the array still pendingh]h!fences in the array still pending}(hj;+hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj7+hK!hj8+ubah}(h]h ]h"]h$]h&]uh1j hj+ubeh}(h]h ]h"]h$]h&]uh1j hj7+hK!hj*ubj )}(h``fences`` array of the fences h](j )}(h ``fences``h]j)}(hj[+h]hfences}(hj]+hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjY+ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK"hjU+ubj )}(hhh]h)}(harray of the fencesh]harray of the fences}(hjt+hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjp+hK"hjq+ubah}(h]h ]h"]h$]h&]uh1j hjU+ubeh}(h]h ]h"]h$]h&]uh1j hjp+hK"hj*ubj )}(h$``work`` internal irq_work function h](j )}(h``work``h]j)}(hj+h]hwork}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj+ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK#hj+ubj )}(hhh]h)}(hinternal irq_work functionh]hinternal irq_work function}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj+hK#hj+ubah}(h]h ]h"]h$]h&]uh1j hj+ubeh}(h]h ]h"]h$]h&]uh1j hj+hK#hj*ubj )}(h'``callbacks`` array of callback helpersh](j )}(h ``callbacks``h]j)}(hj+h]h callbacks}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj+ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK#hj+ubj )}(hhh]h)}(harray of callback helpersh]harray of callback helpers}(hj+hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK$hj+ubah}(h]h ]h"]h$]h&]uh1j hj+ubeh}(h]h ]h"]h$]h&]uh1j hj+hK#hj*ubeh}(h]h ]h"]h$]h&]uh1j hj_*ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jto_dma_fence_array (C function)c.to_dma_fence_arrayhNtauh1jhjhhhNhNubj)}(hhh](j)}(hEstruct dma_fence_array * to_dma_fence_array (struct dma_fence *fence)h]j)}(hCstruct dma_fence_array *to_dma_fence_array(struct dma_fence *fence)h](j)}(hjh]hstruct}(hj',hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj#,hhhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK2ubj)}(h h]h }(hj5,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj#,hhhj4,hK2ubh)}(hhh]j )}(hdma_fence_arrayh]hdma_fence_array}(hjF,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjC,ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjH,modnameN classnameNjj)}j]jO)}jGto_dma_fence_arraysbc.to_dma_fence_arrayasbuh1hhj#,hhhj4,hK2ubj)}(h h]h }(hjg,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj#,hhhj4,hK2ubjd)}(hjgh]h*}(hju,hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj#,hhhj4,hK2ubj )}(hto_dma_fence_arrayh]j )}(hjd,h]hto_dma_fence_array}(hj,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj,ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj#,hhhj4,hK2ubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj,hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj,ubj)}(h h]h }(hj,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj,ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj,ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj,modnameN classnameNjj)}j]jb,c.to_dma_fence_arrayasbuh1hhj,ubj)}(h h]h }(hj,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj,ubjd)}(hjgh]h*}(hj,hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj,ubj )}(hfenceh]hfence}(hj,hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj,ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj,ubah}(h]h ]h"]h$]h&]jjuh1jhj#,hhhj4,hK2ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj,hhhj4,hK2ubah}(h]j,ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj4,hK2hj,hhubjA )}(hhh]h)}(h!cast a fence to a dma_fence_arrayh]h!cast a fence to a dma_fence_array}(hj"-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK2hj-hhubah}(h]h ]h"]h$]h&]uh1j@ hj,hhhj4,hK2ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j:-jc j:-jd je jf uh1jhhhjhNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` fence to cast to a dma_fence_array **Description** Returns NULL if the fence is not a dma_fence_array, or the dma_fence_array otherwise.h](h)}(h**Parameters**h]jr )}(hjD-h]h Parameters}(hjF-hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjB-ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK6hj>-ubj )}(hhh]j )}(h?``struct dma_fence *fence`` fence to cast to a dma_fence_array h](j )}(h``struct dma_fence *fence``h]j)}(hjc-h]hstruct dma_fence *fence}(hje-hhhNhNubah}(h]h ]h"]h$]h&]uh1jhja-ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK3hj]-ubj )}(hhh]h)}(h"fence to cast to a dma_fence_arrayh]h"fence to cast to a dma_fence_array}(hj|-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjx-hK3hjy-ubah}(h]h ]h"]h$]h&]uh1j hj]-ubeh}(h]h ]h"]h$]h&]uh1j hjx-hK3hjZ-ubah}(h]h ]h"]h$]h&]uh1j hj>-ubh)}(h**Description**h]jr )}(hj-h]h Description}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj-ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK5hj>-ubh)}(hUReturns NULL if the fence is not a dma_fence_array, or the dma_fence_array otherwise.h]hUReturns NULL if the fence is not a dma_fence_array, or the dma_fence_array otherwise.}(hj-hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhK4hj>-ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j"dma_fence_array_for_each (C macro)c.dma_fence_array_for_eachhNtauh1jhjhhhNhNubj)}(hhh](j)}(hdma_fence_array_for_eachh]j)}(hdma_fence_array_for_eachh]j )}(hdma_fence_array_for_eachh]j )}(hj-h]hdma_fence_array_for_each}(hj-hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj-ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj-hhhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKBubah}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj-hhhj-hKBubah}(h]j-ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj-hKBhj-hhubjA )}(hhh]h}(h]h ]h"]h$]h&]uh1j@ hj-hhhj-hKBubeh}(h]h ](jmacroeh"]h$]h&]ja jjb j.jc j.jd je jf uh1jhhhjhNhNubh)}(h1``dma_fence_array_for_each (fence, index, head)``h]j)}(hj.h]h-dma_fence_array_for_each (fence, index, head)}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj.ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKDhjhhubh)}(h!iterate over all fences in array h]h)}(h iterate over all fences in arrayh]h iterate over all fences in array}(hj3.hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKBhj/.ubah}(h]h ]h"]h$]h&]uh1hhjA.hKBhjhhubjh )}(hX\**Parameters** ``fence`` current fence ``index`` index into the array ``head`` potential dma_fence_array object **Description** Test if **array** is a dma_fence_array object and if yes iterate over all fences in the array. If not just iterate over the fence in **array** itself. For a deep dive iterator see dma_fence_unwrap_for_each().h](h)}(h**Parameters**h]jr )}(hjN.h]h Parameters}(hjP.hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjL.ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKFhjH.ubj )}(hhh](j )}(h``fence`` current fence h](j )}(h ``fence``h]j)}(hjm.h]hfence}(hjo.hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjk.ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKChjg.ubj )}(hhh]h)}(h current fenceh]h current fence}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj.hKChj.ubah}(h]h ]h"]h$]h&]uh1j hjg.ubeh}(h]h ]h"]h$]h&]uh1j hj.hKChjd.ubj )}(h``index`` index into the array h](j )}(h ``index``h]j)}(hj.h]hindex}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj.ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKDhj.ubj )}(hhh]h)}(hindex into the arrayh]hindex into the array}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj.hKDhj.ubah}(h]h ]h"]h$]h&]uh1j hj.ubeh}(h]h ] h"]h$]h&]uh1j hj.hKDhjd.ubj )}(h*``head`` potential dma_fence_array object h](j )}(h``head``h]j)}(hj.h]hhead}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj.ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKEhj.ubj )}(hhh]h)}(h potential dma_fence_array objecth]h potential dma_fence_array object}(hj.hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj.hKEhj.ubah}(h]h ]h"]h$]h&]uh1j hj.ubeh}(h]h ]h"]h$]h&]uh1j hj.hKEhjd.ubeh}(h]h ]h"]h$]h&]uh1j hjH.ubh)}(h**Description**h]jr )}(hj/h]h Description}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj/ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKGhjH.ubh)}(hTest if **array** is a dma_fence_array object and if yes iterate over all fences in the array. If not just iterate over the fence in **array** itself.h](hTest if }(hj0/hhhNhNubjr )}(h **array**h]harray}(hj8/hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj0/ubht is a dma_fence_array object and if yes iterate over all fences in the array. If not just iterate over the fence in }(hj0/hhhNhNubjr )}(h **array**h]harray}(hjJ/hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj0/ubh itself.}(hj0/hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKFhjH.ubh)}(h9For a deep dive iterator see dma_fence_unwrap_for_each().h]h9For a deep dive iterator see dma_fence_unwrap_for_each().}(hjc/hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:199: ./include/linux/dma-fence-array.hhKIhjH.ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjhhhNhNubeh}(h]dma-fence-arrayah ]h"]dma fence arrayah$]h&]uh1hhjhhhhhKubh)}(hhh](h)}(hDMA Fence Chainh]hDMA Fence Chain}(hj/hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj/hhhhhKubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j!dma_fence_chain_walk (C function)c.dma_fence_chain_walkhNtauh1jhj/hhhNhNubj)}(hhh](j)}(hAstruct dma_fence * dma_fence_chain_walk (struct dma_fence *fence)h]j)}(h?struct dma_fence *dma_fence_chain_walk(struct dma_fence *fence)h](j)}(hjh]hstruct}(hj/hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj/hhhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chK ubj)}(h h]h }(hj/hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj/hhhj/hK ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj/hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj/ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj/modnameN classnameNjj)}j]jO)}jGdma_fence_chain_walksbc.dma_fence_chain_walkasbuh1hhj/hhhj/hK ubj)}(h h]h }(hj/hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj/hhhj/hK ubjd)}(hjgh]h*}(hj/hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj/hhhj/hK ubj )}(hdma_fence_chain_walkh]j )}(hj/h]hdma_fence_chain_walk}(hj 0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj0ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj/hhhj/hK ubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj%0hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj!0ubj)}(h h]h }(hj20hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj!0ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjC0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj@0ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjE0modnameN classnameNjj)}j]j/c.dma_fence_chain_walkasbuh1hhj!0ubj)}(h h]h }(hja0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj!0ubjd)}(hjgh]h*}(hjo0hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj!0ubj )}(hfenceh]hfence}(hj|0hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj!0ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj0ubah}(h]h ]h"]h$]h&]jjuh1jhj/hhhj/hK ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj/hhhj/hK ubah}(h]j/ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj/hK hj/hhubjA )}(hhh]h)}(hchain walking functionh]hchain walking function}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chK hj0hhubah}(h]h ]h"]h$]h&]uh1j@ hj/hhhj/hK ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j0jc j0jd je jf uh1jhhhj/hNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` current chain node **Description** Walk the chain to the next node. Returns the next fence or NULL if we are at the end of the chain. Garbage collects chain nodes which are already signaled.h](h)}(h**Parameters**h]jr )}(hj0h]h Parameters}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj0ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chK$hj0ubj )}(hhh]j )}(h/``struct dma_fence *fence`` current chain node h](j )}(h``struct dma_fence *fence``h]j)}(hj0h]hstruct dma_fence *fence}(hj0hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj0ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chK!hj0ubj )}(hhh]h)}(hcurrent chain nodeh]hcurrent chain node}(hj1hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj0hK!hj0ubah}(h]h ]h"]h$]h&]uh1j hj0ubeh}(h]h ]h"]h$]h&]uh1j hj0hK!hj0ubah}(h]h ]h"]h$]h&]uh1j hj0ubh)}(h**Description**h]jr )}(hj"1h]h Description}(hj$1hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj 1ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chK#hj0ubh)}(hWalk the chain to the next node. Returns the next fence or NULL if we are at the end of the chain. Garbage collects chain nodes which are already signaled.h]hWalk the chain to the next node. Returns the next fence or NULL if we are at the end of the chain. Garbage collects chain nodes which are already signaled.}(hj81hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chK"hj0ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj/hhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j'dma_fence_chain_find_seqno (C function)c.dma_fence_chain_find_seqnohNtauh1jhj/hhhNhNubj)}(hhh](j)}(hJint dma_fence_chain_find_seqno (struct dma_fence **pfence, uint64_t seqno)h]j)}(hIint dma_fence_chain_find_seqno(struct dma_fence **pfence, uint64_t seqno)h](jM)}(hinth]hint}(hjg1hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjc1hhhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKPubj)}(h h]h }(hjv1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjc1hhhju1hKPubj )}(hdma_fence_chain_find_seqnoh]j )}(hdma_fence_chain_find_seqnoh]hdma_fence_chain_find_seqno}(hj1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj1ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjc1hhhju1hKPubj)}(h+(struct dma_fence **pfence, uint64_t seqno)h](j)}(hstruct dma_fence **pfenceh](j)}(hjh]hstruct}(hj1hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj1ubj)}(h h]h }(hj1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj1ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj1ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj1modnameN classnameNjj)}j]jO)}jGj1sbc.dma_fence_chain_find_seqnoasbuh1hhj1ubj)}(h h]h }(hj1hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj1ubjd)}(hjgh]h*}(hj1hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj1ubjd)}(hjgh]h*}(hj1hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj1ubj )}(hpfenceh]hpfence}(hj 2hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj1ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj1ubj)}(huint64_t seqnoh](h)}(hhh]j )}(huint64_th]huint64_t}(hj&2hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj#2ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj(2modnameN classnameNjj)}j]j1c.dma_fence_chain_find_seqnoasbuh1hhj2ubj)}(h h]h }(hjD2hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj2ubj )}(hseqnoh]hseqno}(hjR2hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj2ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj1ubeh}(h]h ]h"]h$]h&]jjuh1jhjc1hhhju1hKPubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj_1hhhju1hKPubah}(h]jZ1ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhju1hKPhj\1hhubjA )}(hhh]h)}(hfind fence chain node by seqnoh]hfind fence chain node by seqno}(hj|2hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKPhjy2hhubah}(h]h ]h"]h$]h&]uh1j@ hj\1hhhju1hKPubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j2jc j2jd je jf uh1jhhhj/hNhNubjh )}(hX**Parameters** ``struct dma_fence **pfence`` pointer to the chain node where to start ``uint64_t seqno`` the sequence number to search for **Description** Advance the fence pointer to the chain node which will signal this sequence number. If no sequence number is provided then this is a no-op. Returns EINVAL if the fence is not a chain node or the sequence number has not yet advanced far enough.h](h)}(h**Parameters**h]jr )}(hj2h]h Parameters}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj2ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKThj2ubj )}(hhh](j )}(hG``struct dma_fence **pfence`` pointer to the chain node where to start h](j )}(h``struct dma_fence **pfence``h]j)}(hj2h]hstruct dma_fence **pfence}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj2ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKQhj2ubj )}(hhh]h)}(h(pointer to the chain node where to starth]h(pointer to the chain node where to start}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj2hKQhj2ubah}(h]h ]h"]h$]h&]uh1j hj2ubeh}(h]h ]h"]h$]h&]uh1j hj2hKQhj2ubj )}(h5``uint64_t seqno`` the sequence number to search for h](j )}(h``uint64_t seqno``h]j)}(hj2h]huint64_t seqno}(hj2hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj2ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKRhj2ubj )}(hhh]h)}(h!the sequence number to search forh]h!the sequence number to search for}(hj3hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj 3hKRhj 3ubah}(h]h ]h"]h$]h&]uh1j hj2ubeh}(h]h ]h"]h$]h&]uh1j hj 3hKRhj2ubeh}(h]h ]h"]h$]h&]uh1j hj2ubh)}(h**Description**h]jr )}(hj13h]h Description}(hj33hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj/3ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKThj2ubh)}(hAdvance the fence pointer to the chain node which will signal this sequence number. If no sequence number is provided then this is a no-op.h]hAdvance the fence pointer to the chain node which will signal this sequence number. If no sequence number is provided then this is a no-op.}(hjG3hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKShj2ubh)}(hgReturns EINVAL if the fence is not a chain node or the sequence number has not yet advanced far enough.h]hgReturns EINVAL if the fence is not a chain node or the sequence number has not yet advanced far enough.}(hjV3hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKVhj2ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj/hhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j!dma_fence_chain_init (C function)c.dma_fence_chain_inithNtauh1jhj/hhhNhNubj)}(hhh](j)}(hzvoid dma_fence_chain_init (struct dma_fence_chain *chain, struct dma_fence *prev, struct dma_fence *fence, uint64_t seqno)h]j)}(hyvoid dma_fence_chain_init(struct dma_fence_chain *chain, struct dma_fence *prev, struct dma_fence *fence, uint64_t seqno)h](jM)}(hvoidh]hvoid}(hj3hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj3hhhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKubj)}(h h]h }(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj3hhhj3hKubj )}(hdma_fence_chain_inith]j )}(hdma_fence_chain_inith]hdma_fence_chain_init}(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj3ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj3hhhj3hKubj)}(h`(struct dma_fence_chain *chain, struct dma_fence *prev, struct dma_fence *fence, uint64_t seqno)h](j)}(hstruct dma_fence_chain *chainh](j)}(hjh]hstruct}(hj3hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj3ubj)}(h h]h }(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj3ubh)}(hhh]j )}(hdma_fence_chainh]hdma_fence_chain}(hj3hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj3ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj3modnameN classnameNjj)}j]jO)}jGj3sbc.dma_fence_chain_initasbuh1hhj3ubj)}(h h]h }(hj4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj3ubjd)}(hjgh]h*}(hj4hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj3ubj )}(hchainh]hchain}(hj4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj3ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj3ubj)}(hstruct dma_fence *prevh](j)}(hjh]hstruct}(hj44hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj04ubj)}(h h]h }(hjA4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj04ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjR4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjO4ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjT4modnameN classnameNjj)}j]j3c.dma_fence_chain_initasbuh1hhj04ubj)}(h h]h }(hjp4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj04ubjd)}(hjgh]h*}(hj~4hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj04ubj )}(hprevh]hprev}(hj4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj04ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj3ubj)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj4hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj4ubj)}(h h]h }(hj4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj4ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj4ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj4modnameN classnameNjj)}j]j3c.dma_fence_chain_initasbuh1hhj4ubj)}(h h]h }(hj4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj4ubjd)}(hjgh]h*}(hj4hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj4ubj )}(hfenceh]hfence}(hj4hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj4ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj3ubj)}(huint64_t seqnoh](h)}(hhh]j )}(huint64_th]huint64_t}(hj5hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj5ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj5modnameN classnameNjj)}j]j3c.dma_fence_chain_initasbuh1hhj5ubj)}(h h]h }(hj55hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj5ubj )}(hseqnoh]hseqno}(hjC5hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj5ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj3ubeh}(h]h ]h"]h$]h&]jjuh1jhj3hhhj3hKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj}3hhhj3hKubah}(h]jx3ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj3hKhjz3hhubjA )}(hhh]h)}(hinitialize a fence chainh]hinitialize a fence chain}(hjm5hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKhjj5hhubah}(h]h ]h"]h$]h&]uh1j@ hjz3hhhj3hKubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j5jc j5jd je jf uh1jhhhj/hNhNubjh )}(hX**Parameters** ``struct dma_fence_chain *chain`` the chain node to initialize ``struct dma_fence *prev`` the previous fence ``struct dma_fence *fence`` the current fence ``uint64_t seqno`` the sequence number to use for the fence chain **Description** Initialize a new chain node and either start a new chain or add the node to the existing chain of the previous fence.h](h)}(h**Parameters**h]jr )}(hj5h]h Parameters}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj5ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKhj5ubj )}(hhh](j )}(h?``struct dma_fence_chain *chain`` the chain node to initialize h](j )}(h!``struct dma_fence_chain *chain``h]j)}(hj5h]hstruct dma_fence_chain *chain}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj5ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKhj5ubj )}(hhh]h)}(hthe chain node to initializeh]hthe chain node to initialize}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj5hKhj5ubah}(h]h ]h"]h$]h&]uh1j hj5ubeh}(h]h ]h"]h$]h&]uh1j hj5hKhj5ubj )}(h.``struct dma_fence *prev`` the previous fence h](j )}(h``struct dma_fence *prev``h]j)}(hj5h]hstruct dma_fence *prev}(hj5hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj5ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKhj5ubj )}(hhh]h)}(hthe previous fenceh]hthe previous fence}(hj6hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj5hKhj5ubah}(h]h ]h"]h$]h&]uh1j hj5ubeh}(h]h ]h"]h$]h&]uh1j hj5hKhj5ubj )}(h.``struct dma_fence *fence`` the current fence h](j )}(h``struct dma_fence *fence``h]j)}(hj 6h]hstruct dma_fence *fence}(hj"6hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj6ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKhj6ubj )}(hhh]h)}(hthe current fenceh]hthe current fence}(hj96hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj56hKhj66ubah}(h]h ]h"]h$]h&]uh1j hj6ubeh}(h]h ]h"]h$]h&]uh1j hj56hKhj5ubj )}(hB``uint64_t seqno`` the sequence number to use for the fence chain h](j )}(h``uint64_t seqno``h]j)}(hjY6h]huint64_t seqno}(hj[6hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjW6ubah}(h]h ]h"]h$]h&]uh1j he/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKhjS6ubj )}(hhh]h)}(h.the sequence number to use for the fence chainh]h.the sequence number to use for the fence chain}(hjr6hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjn6hKhjo6ubah}(h]h ]h"]h$]h&]uh1j hjS6ubeh}(h]h ]h"]h$]h&]uh1j hjn6hKhj5ubeh}(h]h ]h"]h$]h&]uh1j hj5ubh)}(h**Description**h]jr )}(hj6h]h Description}(hj6hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj6ubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKhj5ubh)}(huInitialize a new chain node and either start a new chain or add the node to the existing chain of the previous fence.h]huInitialize a new chain node and either start a new chain or add the node to the existing chain of the previous fence.}(hj6hhhNhNubah}(h]h ]h"]h$]h&]uh1hhe/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:205: ./drivers/dma-buf/dma-fence-chain.chKhj5ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj/hhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_chain (C struct)c.dma_fence_chainhNtauh1jhj/hhhNhNubj)}(hhh](j)}(hdma_fence_chainh]j)}(hstruct dma_fence_chainh](j)}(hjh]hstruct}(hj6hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj6hhhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKubj)}(h h]h }(hj6hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj6hhhj6hKubj )}(hdma_fence_chainh]j )}(hj6h]hdma_fence_chain}(hj6hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj6ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj6hhhj6hKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj6hhhj6hKubah}(h]j6ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj6hKhj6hhubjA )}(hhh]h)}(h+fence to represent an node of a fence chainh]h+fence to represent an node of a fence chain}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKhj7hhubah}(h]h ]h"]h$]h&]uh1j@ hj6hhhj6hKubeh}(h]h ](jstructeh"]h$]h&]ja jjb j37jc j37jd je jf uh1jhhhj/hNhNubjh )}(hX-**Definition**:: struct dma_fence_chain { struct dma_fence base; struct dma_fence *prev; u64 prev_seqno; struct dma_fence *fence; union { struct dma_fence_cb cb; struct irq_work work; }; }; **Members** ``base`` fence base class ``prev`` previous fence of the chain ``prev_seqno`` original previous seqno before garbage collection ``fence`` encapsulated fence ``{unnamed_union}`` anonymous ``cb`` callback for signaling This is used to add the callback for signaling the complection of the fence chain. Never used at the same time as the irq work. ``work`` irq work item for signaling Irq work structure to allow us to add the callback without running into lock inversion. Never used at the same time as the callback.h](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hj?7hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj;7ubh:}(hj;7hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKhj77ubj)}(hstruct dma_fence_chain { struct dma_fence base; struct dma_fence *prev; u64 prev_seqno; struct dma_fence *fence; union { struct dma_fence_cb cb; struct irq_work work; }; };h]hstruct dma_fence_chain { struct dma_fence base; struct dma_fence *prev; u64 prev_seqno; struct dma_fence *fence; union { struct dma_fence_cb cb; struct irq_work work; }; };}hjX7sbah}(h]h ]h"]h$]h&]jjuh1jhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKhj77ubh)}(h **Members**h]jr )}(hji7h]hMembers}(hjk7hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjg7ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK#hj77ubj )}(hhh](j )}(h``base`` fence base class h](j )}(h``base``h]j)}(hj7h]hbase}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj7ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKhj7ubj )}(hhh]h)}(hfence base classh]hfence base class}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj7hKhj7ubah}(h]h ]h"]h$]h&]uh1j hj7ubeh}(h]h ]h"]h$]h&]uh1j hj7hKhj7ubj )}(h%``prev`` previous fence of the chain h](j )}(h``prev``h]j)}(hj7h]hprev}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj7ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKhj7ubj )}(hhh]h)}(hprevious fence of the chainh]hprevious fence of the chain}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj7hKhj7ubah}(h]h ]h"]h$]h&]uh1j hj7ubeh}(h]h ]h"]h$]h&]uh1j hj7hKhj7ubj )}(hA``prev_seqno`` original previous seqno before garbage collection h](j )}(h``prev_seqno``h]j)}(hj7h]h prev_seqno}(hj7hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj7ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKhj7ubj )}(hhh]h)}(h1original previous seqno before garbage collectionh]h1original previous seqno before garbage collection}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj8hKhj8ubah}(h]h ]h"]h$]h&]uh1j hj7ubeh}(h]h ]h"]h$]h&]uh1j hj8hKhj7ubj )}(h``fence`` encapsulated fence h](j )}(h ``fence``h]j)}(hj38h]hfence}(hj58hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj18ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKhj-8ubj )}(hhh]h)}(hencapsulated fenceh]hencapsulated fence}(hjL8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjH8hKhjI8ubah}(h]h ]h"]h$]h&]uh1j hj-8ubeh}(h]h ]h"]h$]h&]uh1j hjH8hKhj7ubj )}(h``{unnamed_union}`` anonymous h](j )}(h``{unnamed_union}``h]j)}(hjl8h]h{unnamed_union}}(hjn8hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjj8ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKhjf8ubj )}(hhh]h)}(h anonymoush]h anonymous}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj8hKhj8ubah}(h]h ]h"]h$]h&]uh1j hjf8ubeh}(h]h ]h"]h$]h&]uh1j hj8hKhj7ubj )}(h``cb`` callback for signaling This is used to add the callback for signaling the complection of the fence chain. Never used at the same time as the irq work. h](j )}(h``cb``h]j)}(hj8h]hcb}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj8ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK$hj8ubj )}(hhh](h)}(hcallback for signalingh]hcallback for signaling}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK hj8ubh)}(hThis is used to add the callback for signaling the complection of the fence chain. Never used at the same time as the irq work.h]hThis is used to add the callback for signaling the complection of the fence chain. Never used at the same time as the irq work.}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK"hj8ubeh}(h]h ]h"]h$]h&]uh1j hj8ubeh}(h]h ]h"]h$]h&]uh1j hj8hK$hj7ubj )}(h``work`` irq work item for signaling Irq work structure to allow us to add the callback without running into lock inversion. Never used at the same time as the callback.h](j )}(h``work``h]j)}(hj8h]hwork}(hj8hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj8ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK,hj8ubj )}(hhh](h)}(hirq work item for signalingh]hirq work item for signaling}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK)hj9ubh)}(hIrq work structure to allow us to add the callback without running into lock inversion. Never used at the same time as the callback.h]hIrq work structure to allow us to add the callback without running into lock inversion. Never used at the same time as the callback.}(hj9hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK+hj9ubeh}(h]h ]h"]h$]h&]uh1j hj8ubeh}(h]h ]h"]h$]h&]uh1j hj9hK,hj7ubeh}(h]h ]h"]h$]h&]uh1j hj77ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj/hhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jto_dma_fence_chain (C function)c.to_dma_fence_chainhNtauh1jhj/hhhNhNubj)}(hhh](j)}(hEstruct dma_fence_chain * to_dma_fence_chain (struct dma_fence *fence)h]j)}(hCstruct dma_fence_chain *to_dma_fence_chain(struct dma_fence *fence)h](j)}(hjh]hstruct}(hjW9hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjS9hhhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK4ubj)}(h h]h }(hje9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjS9hhhjd9hK4ubh)}(hhh]j )}(hdma_fence_chainh]hdma_fence_chain}(hjv9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjs9ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjx9modnameN classnameNjj)}j]jO)}jGto_dma_fence_chainsbc.to_dma_fence_chainasbuh1hhjS9hhhjd9hK4ubj)}(h h]h }(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjS9hhhjd9hK4ubjd)}(hjgh]h*}(hj9hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjS9hhhjd9hK4ubj )}(hto_dma_fence_chainh]j )}(hj9h]hto_dma_fence_chain}(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj9ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjS9hhhjd9hK4ubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj9hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj9ubj)}(h h]h }(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj9ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj9hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj9ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj9modnameN classnameNjj)}j]j9c.to_dma_fence_chainasbuh1hhj9ubj)}(h h]h }(hj :hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj9ubjd)}(hjgh]h*}(hj:hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj9ubj )}(hfenceh]hfence}(hj(:hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj9ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj9ubah}(h]h ]h"]h$]h&]jjuh1jhjS9hhhjd9hK4ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjO9hhhjd9hK4ubah}(h]jJ9ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjd9hK4hjL9hhubjA )}(hhh]h)}(h!cast a fence to a dma_fence_chainh]h!cast a fence to a dma_fence_chain}(hjR:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK4hjO:hhubah}(h]h ]h"]h$]h&]uh1j@ hjL9hhhjd9hK4ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb jj:jc jj:jd je jf uh1jhhhj/hNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` fence to cast to a dma_fence_array **Description** Returns NULL if the fence is not a dma_fence_chain, or the dma_fence_chain otherwise.h](h)}(h**Parameters**h]jr )}(hjt:h]h Parameters}(hjv:hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjr:ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK8hjn:ubj )}(hhh]j )}(h?``struct dma_fence *fence`` fence to cast to a dma_fence_array h](j )}(h``struct dma_fence *fence``h]j)}(hj:h]hstruct dma_fence *fence}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj:ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK5hj:ubj )}(hhh]h)}(h"fence to cast to a dma_fence_arrayh]h"fence to cast to a dma_fence_array}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj:hK5hj:ubah}(h]h ]h"]h$]h&]uh1j hj:ubeh}(h]h ]h"]h$]h&]uh1j hj:hK5hj:ubah}(h]h ]h"]h$]h&]uh1j hjn:ubh)}(h**Description**h]jr )}(hj:h]h Description}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj:ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK7hjn:ubh)}(hUReturns NULL if the fence is not a dma_fence_chain, or the dma_fence_chain otherwise.h]hUReturns NULL if the fence is not a dma_fence_chain, or the dma_fence_chain otherwise.}(hj:hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK6hjn:ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj/hhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j&dma_fence_chain_contained (C function)c.dma_fence_chain_containedhNtauh1jhj/hhhNhNubj)}(hhh](j)}(hFstruct dma_fence * dma_fence_chain_contained (struct dma_fence *fence)h]j)}(hDstruct dma_fence *dma_fence_chain_contained(struct dma_fence *fence)h](j)}(hjh]hstruct}(hj;hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj;hhhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKDubj)}(h h]h }(hj!;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj;hhhj ;hKDubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj2;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj/;ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj4;modnameN classnameNjj)}j]jO)}jGdma_fence_chain_containedsbc.dma_fence_chain_containedasbuh1hhj;hhhj ;hKDubj)}(h h]h }(hjS;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj;hhhj ;hKDubjd)}(hjgh]h*}(hja;hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj;hhhj ;hKDubj )}(hdma_fence_chain_containedh]j )}(hjP;h]hdma_fence_chain_contained}(hjr;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjn;ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj;hhhj ;hKDubj)}(h(struct dma_fence *fence)h]j)}(hstruct dma_fence *fenceh](j)}(hjh]hstruct}(hj;hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj;ubj)}(h h]h }(hj;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj;ubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hj;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj;ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj;modnameN classnameNjj)}j]jN;c.dma_fence_chain_containedasbuh1hhj;ubj)}(h h]h }(hj;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj;ubjd)}(hjgh]h*}(hj;hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj;ubj )}(hfenceh]hfence}(hj;hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj;ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj;ubah}(h]h ]h"]h$]h&]jjuh1jhj;hhhj ;hKDubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj ;hhhj ;hKDubah}(h]j;ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj ;hKDhj;hhubjA )}(hhh]h)}(hreturn the contained fenceh]hreturn the contained fence}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKDhj <hhubah}(h]h ]h"]h$]h&]uh1j@ hj;hhhj ;hKDubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j&<jc j&<jd je jf uh1jhhhj/hNhNubjh )}(h**Parameters** ``struct dma_fence *fence`` the fence to test **Description** If the fence is a dma_fence_chain the function returns the fence contained inside the chain object, otherwise it returns the fence itself.h](h)}(h**Parameters**h]jr )}(hj0<h]h Parameters}(hj2<hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj.<ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKHhj*<ubj )}(hhh]j )}(h.``struct dma_fence *fence`` the fence to test h](j )}(h``struct dma_fence *fence``h]j)}(hjO<h]hstruct dma_fence *fence}(hjQ<hhhNhNubah}(h]h ]h"]h$]h&]uh1jhjM<ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKEhjI<ubj )}(hhh]h)}(hthe fence to testh]hthe fence to test}(hjh<hhhNhNubah}(h]h ]h"]h$]h&]uh1hhjd<hKEhje<ubah}(h]h ]h"]h$]h&]uh1j hjI<ubeh}(h]h ]h"]h$]h&]uh1j hjd<hKEhjF<ubah}(h]h ]h"]h$]h&]uh1j hj*<ubh)}(h**Description**h]jr )}(hj<h]h Description}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj<ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKGhj*<ubh)}(hIf the fence is a dma_fence_chain the function returns the fence contained inside the chain object, otherwise it returns the fence itself.h]hIf the fence is a dma_fence_chain the function returns the fence contained inside the chain object, otherwise it returns the fence itself.}(hj<hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKFhj*<ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj/hhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_chain_alloc (C macro)c.dma_fence_chain_allochNtauh1jhj/hhhNhNubj)}(hhh](j)}(hdma_fence_chain_alloch]j)}(hdma_fence_chain_alloch]j )}(hdma_fence_chain_alloch]j )}(hj<h]hdma_fence_chain_alloc}(hj<hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj<ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj<hhhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKSubah}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj<hhhj<hKSubah}(h]j<ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj<hKShj<hhubjA )}(hhh]h}(h]h ]h"]h$]h&]uh1j@ hj<hhhj<hKSubeh}(h]h ](jmacroeh"]h$]h&]ja jjb j<jc j<jd je jf uh1jhhhj/hNhNubh)}(h``dma_fence_chain_alloc ()``h]j)}(hj=h]hdma_fence_chain_alloc ()}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj=ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKUhj/hhubh)}(hX# Returns a new :c:type:`struct dma_fence_chain ` object or ``NULL`` on failure. **Description** This specialized allocator has to be a macro for its allocations to be accounted separately (to have a separate alloc_tag). The typecast is intentional to enforce typesafety. h](h)}(h`Returns a new :c:type:`struct dma_fence_chain ` object or ``NULL`` on failure. h]h)}(h_Returns a new :c:type:`struct dma_fence_chain ` object or ``NULL`` on failure.h](hReturns a new }(hj#=hhhNhNubh)}(h2:c:type:`struct dma_fence_chain `h]j)}(hj-=h]hstruct dma_fence_chain}(hj/=hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj+=ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjdma_fence_chainuh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKShj#=ubh object or }(hj#=hhhNhNubj)}(h``NULL``h]hNULL}(hjO=hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj#=ubh on failure.}(hj#=hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjJ=hKShj=ubah}(h]h ]h"]h$]h&]uh1hhjJ=hKShj=ubh)}(h**Description**h]jr )}(hjo=h]h Description}(hjq=hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjm=ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKUhj=ubh)}(hThis specialized allocator has to be a macro for its allocations to be accounted separately (to have a separate alloc_tag). The typecast is intentional to enforce typesafety.h]hThis specialized allocator has to be a macro for its allocations to be accounted separately (to have a separate alloc_tag). The typecast is intentional to enforce typesafety.}(hj=hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKThj=ubeh}(h]h ]h"]h$]h&]uh1hhjJ=hKShj/hhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j!dma_fence_chain_free (C function)c.dma_fence_chain_freehNtauh1jhj/hhhNhNubj)}(hhh](j)}(h9void dma_fence_chain_free (struct dma_fence_chain *chain)h]j)}(h8void dma_fence_chain_free(struct dma_fence_chain *chain)h](jM)}(hvoidh]hvoid}(hj=hhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhj=hhhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK^ubj)}(h h]h }(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj=hhhj=hK^ubj )}(hdma_fence_chain_freeh]j )}(hdma_fence_chain_freeh]hdma_fence_chain_free}(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj=ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj=hhhj=hK^ubj)}(h(struct dma_fence_chain *chain)h]j)}(hstruct dma_fence_chain *chainh](j)}(hjh]hstruct}(hj=hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj=ubj)}(h h]h }(hj=hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj=ubh)}(hhh]j )}(hdma_fence_chainh]hdma_fence_chain}(hj>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj >ubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetj>modnameN classnameNjj)}j]jO)}jGj=sbc.dma_fence_chain_freeasbuh1hhj=ubj)}(h h]h }(hj.>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj=ubjd)}(hjgh]h*}(hj<>hhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchj=ubj )}(hchainh]hchain}(hjI>hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj=ubeh}(h]h ]h"]h$]h&]noemphjjuh1jhj=ubah}(h]h ]h"]h$]h&]jjuh1jhj=hhhj=hK^ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj=hhhj=hK^ubah}(h]j=ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj=hK^hj=hhubjA )}(hhh]h)}(hZFrees an allocated but not used :c:type:`struct dma_fence_chain ` object.h](h Frees an allocated but not used }(hjs>hhhNhNubh)}(h2:c:type:`struct dma_fence_chain `h]j)}(hj}>h]hstruct dma_fence_chain}(hj>hhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj{>ubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjj)}j]j*>c.dma_fence_chain_freeasbjdma_fence_chainuh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKhjs>ubh object.}(hjs>hhhNhNubeh}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK^hjp>hhubah}(h]h ]h"]h$]h&]uh1j@ hj=hhhj=hK^ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j>jc j>jd je jf uh1jhhhj/hNhNubjh )}(hXx**Parameters** ``struct dma_fence_chain *chain`` chain node to free **Description** Frees up an allocated but not used struct dma_fence_chain object. This doesn't need an RCU grace period since the fence was never initialized nor published. After dma_fence_chain_init() has been called the fence must be released by calling dma_fence_put(), and not through this function.h](h)}(h**Parameters**h]jr )}(hj>h]h Parameters}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj>ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKbhj>ubj )}(hhh]j )}(h5``struct dma_fence_chain *chain`` chain node to free h](j )}(h!``struct dma_fence_chain *chain``h]j)}(hj>h]hstruct dma_fence_chain *chain}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj>ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhK`hj>ubj )}(hhh]h)}(hchain node to freeh]hchain node to free}(hj>hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj>hK`hj>ubah}(h]h ]h"]h$]h&]uh1j hj>ubeh}(h]h ]h"]h$]h&]uh1j hj>hK`hj>ubah}(h]h ]h"]h$]h&]uh1j hj>ubh)}(h**Description**h]jr )}(hj?h]h Description}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj?ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKbhj>ubh)}(hXFrees up an allocated but not used struct dma_fence_chain object. This doesn't need an RCU grace period since the fence was never initialized nor published. After dma_fence_chain_init() has been called the fence must be released by calling dma_fence_put(), and not through this function.h]hX!Frees up an allocated but not used struct dma_fence_chain object. This doesn’t need an RCU grace period since the fence was never initialized nor published. After dma_fence_chain_init() has been called the fence must be released by calling dma_fence_put(), and not through this function.}(hj.?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKahj>ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj/hhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j"dma_fence_chain_for_each (C macro)c.dma_fence_chain_for_eachhNtauh1jhj/hhhNhNubj)}(hhh](j)}(hdma_fence_chain_for_eachh]j)}(hdma_fence_chain_for_eachh]j )}(hdma_fence_chain_for_eachh]j )}(hjW?h]hdma_fence_chain_for_each}(hja?hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj]?ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjY?hhhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKmubah}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjU?hhhjt?hKmubah}(h]jP?ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjt?hKmhjR?hhubjA )}(hhh]h}(h]h ]h"]h$]h&]uh1j@ hjR?hhhjt?hKmubeh}(h]h ](jmacroeh"]h$]h&]ja jjb j?jc j?jd je jf uh1jhhhj/hNhNubh)}(h)``dma_fence_chain_for_each (iter, head)``h]j)}(hj?h]h%dma_fence_chain_for_each (iter, head)}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj?ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKohj/hhubh)}(h!iterate over all fences in chain h]h)}(h iterate over all fences in chainh]h iterate over all fences in chain}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKmhj?ubah}(h]h ]h"]h$]h&]uh1hhj?hKmhj/hhubjh )}(hX**Parameters** ``iter`` current fence ``head`` starting point **Description** Iterate over all fences in the chain. We keep a reference to the current fence while inside the loop which must be dropped when breaking out. For a deep dive iterator see dma_fence_unwrap_for_each().h](h)}(h**Parameters**h]jr )}(hj?h]h Parameters}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj?ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKqhj?ubj )}(hhh](j )}(h``iter`` current fence h](j )}(h``iter``h]j)}(hj?h]hiter}(hj?hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj?ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKnhj?ubj )}(hhh]h)}(h current fenceh]h current fence}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj?hKnhj?ubah}(h]h ]h"]h$]h&]uh1j hj?ubeh}(h]h ]h"]h$]h&]uh1j hj?hKnhj?ubj )}(h``head`` starting point h](j )}(h``head``h]j)}(hj @h]hhead}(hj"@hhhNhNubah}(h]h ]h"]h$]h&]uh1jhj@ubah}(h]h ]h"]h$]h&]uh1j hc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKohj@ubj )}(hhh]h)}(hstarting pointh]hstarting point}(hj9@hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj5@hKohj6@ubah}(h]h ]h"]h$]h&]uh1j hj@ubeh}(h]h ]h"]h$]h&]uh1j hj5@hKohj?ubeh}(h]h ]h"]h$]h&]uh1j hj?ubh)}(h**Description**h]jr )}(hj[@h]h Description}(hj]@hhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjY@ubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKqhj?ubh)}(hIterate over all fences in the chain. We keep a reference to the current fence while inside the loop which must be dropped when breaking out.h]hIterate over all fences in the chain. We keep a reference to the current fence while inside the loop which must be dropped when breaking out.}(hjq@hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKphj?ubh)}(h9For a deep dive iterator see dma_fence_unwrap_for_each().h]h9For a deep dive iterator see dma_fence_unwrap_for_each().}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1hhc/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:208: ./include/linux/dma-fence-chain.hhKshj?ubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj/hhhNhNubeh}(h]dma-fence-chainah ]h"]dma fence chainah$]h&]uh1hhjhhhhhKubh)}(hhh](h)}(hDMA Fence unwraph]hDMA Fence unwrap}(hj@hhhNhNubah}(h]h ]h"]h$]h&]uh1hhj@hhhhhKubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jdma_fence_unwrap (C struct)c.dma_fence_unwraphNtauh1jhj@hhhNhNubj)}(hhh](j)}(hdma_fence_unwraph]j)}(hstruct dma_fence_unwraph](j)}(hjh]hstruct}(hj@hhhNhNubah}(h]h ]jah"]h$]h&]uh1jhj@hhhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhKubj)}(h h]h }(hj@hhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhj@hhhj@hKubj )}(hdma_fence_unwraph]j )}(hj@h]hdma_fence_unwrap}(hj@hhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj@ubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hj@hhhj@hKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj@hhhj@hKubah}(h]j@ah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj@hKhj@hhubjA )}(hhh]h)}(h#cursor into the container structureh]h#cursor into the container structure}(hj AhhhNhNubah}(h]h ]h"]h$]h&]uh1hhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhKhjAhhubah}(h]h ]h"]h$]h&]uh1j@ hj@hhhj@hKubeh}(h]h ](jstructeh"]h$]h&]ja jjb j"Ajc j"Ajd je jf uh1jhhhj@hNhNubjh )}(hXo**Definition**:: struct dma_fence_unwrap { struct dma_fence *chain; struct dma_fence *array; unsigned int index; }; **Members** ``chain`` potential dma_fence_chain, but can be other fence as well ``array`` potential dma_fence_array, but can be other fence as well ``index`` last returned index if **array** is really a dma_fence_arrayh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hj.AhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj*Aubh:}(hj*AhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhKhj&Aubj)}(hnstruct dma_fence_unwrap { struct dma_fence *chain; struct dma_fence *array; unsigned int index; };h]hnstruct dma_fence_unwrap { struct dma_fence *chain; struct dma_fence *array; unsigned int index; };}hjGAsbah}(h]h ]h"]h$]h&]jjuh1jhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhKhj&Aubh)}(h **Members**h]jr )}(hjXAh]hMembers}(hjZAhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjVAubah}(h]h ]h"]h$]h&]uh1hhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhKhj&Aubj )}(hhh](j )}(hD``chain`` potential dma_fence_chain, but can be other fence as well h](j )}(h ``chain``h]j)}(hjwAh]hchain}(hjyAhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjuAubah}(h]h ]h"]h$]h&]uh1j hd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhKhjqAubj )}(hhh]h)}(h9potential dma_fence_chain, but can be other fence as wellh]h9potential dma_fence_chain, but can be other fence as well}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjAhKhjAubah}(h]h ]h"]h$]h&]uh1j hjqAubeh}(h]h ]h"]h$]h&]uh1j hjAhKhjnAubj )}(hD``array`` potential dma_fence_array, but can be other fence as well h](j )}(h ``array``h]j)}(hjAh]harray}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjAubah}(h]h ]h"]h$]h&]uh1j hd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhKhjAubj )}(hhh]h)}(h9potential dma_fence_array, but can be other fence as wellh]h9potential dma_fence_array, but can be other fence as well}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjAhKhjAubah}(h]h ]h"]h$]h&]uh1j hjAubeh}(h]h ]h"]h$]h&]uh1j hjAhKhjnAubj )}(hF``index`` last returned index if **array** is really a dma_fence_arrayh](j )}(h ``index``h]j)}(hjAh]hindex}(hjAhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjAubah}(h]h ]h"]h$]h&]uh1j hd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhKhjAubj )}(hhh]h)}(hBh]h Description}(hj@BhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj )j? huh1jhjBhK(hjqBhhubjA )}(hhh]h}(h]h ]h"]h$]h&]uh1j@ hjqBhhhjBhK(ubeh}(h]h ](jmacroeh"]h$]h&]ja jjb jBjc jBjd je jf uh1jhhhj@hNhNubh)}(h3``dma_fence_unwrap_for_each (fence, cursor, head)``h]j)}(hjBh]h/dma_fence_unwrap_for_each (fence, cursor, head)}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjBubah}(h]h ]h"]h$]h&]uh1hhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhK*hj@hhubh)}(h&iterate over all fences in containers h]h)}(h%iterate over all fences in containersh]h%iterate over all fences in containers}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1hhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hrhK(hjBubah}(h]h ]h"]h$]h&]uh1hhjBhK(hj@hhubjh )}(hXA**Parameters** ``fence`` current fence ``cursor`` current position inside the containers ``head`` starting point for the iterator **Description** Unwrap dma_fence_chain and dma_fence_array containers and deep dive into all potential fences in them. If **head** is just a normal fence only that one is returned.h](h)}(h**Parameters**h]jr )}(hjBh]h Parameters}(hjBhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjBubah}(h]h ]h"]h$]h&]uh1hhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhK,hjBubj )}(hhh](j )}(h``fence`` current fence h](j )}(h ``fence``h]j)}(hjCh]hfence}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1jhjCubah}(h]h ]h"]h$]h&]uh1j hd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhK)hjCubj )}(hhh]h)}(h current fenceh]h current fence}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1hhjChK)hjCubah}(h]h ]h"]h$]h&]uh1j hjCubeh}(h]h ]h"]h$]h&]uh1j hjChK)hjBubj )}(h2``cursor`` current position inside the containers h](j )}(h ``cursor``h]j)}(hj?Ch]hcursor}(hjAChhhNhNubah}(h]h ]h"]h$]h&]uh1jhj=Cubah}(h]h ]h"]h$]h&]uh1j hd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhK*hj9Cubj )}(hhh]h)}(h¤t position inside the containersh]h¤t position inside the containers}(hjXChhhNhNubah}(h]h ]h"]h$]h&]uh1hhjTChK*hjUCubah}(h]h ]h"]h$]h&]uh1j hj9Cubeh}(h]h ]h"]h$]h&]uh1j hjTChK*hjBubj )}(h)``head`` starting point for the iterator h](j )}(h``head``h]j)}(hjxCh]hhead}(hjzChhhNhNubah}(h]h ]h"]h$]h&]uh1jhjvCubah}(h]h ]h"]h$]h&]uh1j hd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhK+hjrCubj )}(hhh]h)}(hstarting point for the iteratorh]hstarting point for the iterator}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1hhjChK+hjCubah}(h]h ]h"]h$]h&]uh1j hjrCubeh}(h]h ]h"]h$]h&]uh1j hjChK+hjBubeh}(h]h ]h"]h$]h&]uh1j hjBubh)}(h**Description**h]jr )}(hjCh]h Description}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjCubah}(h]h ]h"]h$]h&]uh1hhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhK-hjBubh)}(hUnwrap dma_fence_chain and dma_fence_array containers and deep dive into all potential fences in them. If **head** is just a normal fence only that one is returned.h](hjUnwrap dma_fence_chain and dma_fence_array containers and deep dive into all potential fences in them. If }(hjChhhNhNubjr )}(h**head**h]hhead}(hjChhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjCubh2 is just a normal fence only that one is returned.}(hjChhhNhNubeh}(h]h ]h"]h$]h&]uh1hhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhK,hjBubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj@hhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j dma_fence_unwrap_merge (C macro)c.dma_fence_unwrap_mergehNtauh1jhj@hhhNhNubj)}(hhh](j)}(hdma_fence_unwrap_mergeh]j)}(hdma_fence_unwrap_mergeh]j )}(hdma_fence_unwrap_mergeh]j )}(hjDh]hdma_fence_unwrap_merge}(hjDhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hj Dubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjDhhhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhK )j? huh1jhj!DhKDubah}(h]h ]h"]h$]h&]uh1hhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhK>hj@hhubh)}(hunwrap and merge fences h]h)}(hunwrap and merge fencesh]hunwrap and merge fences}(hjZDhhhNhNubah}(h]h ]h"]h$]h&]uh1hhd/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:214: ./include/linux/dma-fence-unwrap.hhKEah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjXEhK9hj@EhhubjA )}(hhh]h)}(hcreates a sync fileh]hcreates a sync file}(hjFFhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chK9hjCFhhubah}(h]h ]h"]h$]h&]uh1j@ hj@EhhhjXEhK9ubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j^Fjc j^Fjd je jf uh1jhhhj!EhNhNubjh )}(hXh**Parameters** ``struct dma_fence *fence`` fence to add to the sync_fence **Description** Creates a sync_file containg **fence**. This function acquires and additional reference of **fence** for the newly-created :c:type:`sync_file`, if it succeeds. The sync_file can be released with fput(sync_file->file). Returns the sync_file or NULL in case of error.h](h)}(h**Parameters**h]jr )}(hjhFh]h Parameters}(hjjFhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjfFubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chK=hjbFubj )}(hhh]j )}(h;``struct dma_fence *fence`` fence to add to the sync_fence h](j )}(h``struct dma_fence *fence``h]j)}(hjFh]hstruct dma_fence *fence}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjFubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chK:hjFubj )}(hhh]h)}(hfence to add to the sync_fenceh]hfence to add to the sync_fence}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjFhK:hjFubah}(h]h ]h"]h$]h&]uh1j hjFubeh}(h]h ]h"]h$]h&]uh1j hjFhK:hj~Fubah}(h]h ]h"]h$]h&]uh1j hjbFubh)}(h**Description**h]jr )}(hjFh]h Description}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjFubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chKfile). Returns the sync_file or NULL in case of error.h](hCreates a sync_file containg }(hjFhhhNhNubjr )}(h **fence**h]hfence}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjFubh5. This function acquires and additional reference of }(hjFhhhNhNubjr )}(h **fence**h]hfence}(hjFhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjFubh for the newly-created }(hjFhhhNhNubh)}(h:c:type:`sync_file`h]j)}(hjGh]h sync_file}(hjGhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjGubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjj sync_fileuh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chK;hjFubh{, if it succeeds. The sync_file can be released with fput(sync_file->file). Returns the sync_file or NULL in case of error.}(hjFhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhj#GhK;hjbFubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj!EhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](j sync_file_get_fence (C function)c.sync_file_get_fencehNtauh1jhj!EhhhNhNubj)}(hhh](j)}(h/struct dma_fence * sync_file_get_fence (int fd)h]j)}(h-struct dma_fence *sync_file_get_fence(int fd)h](j)}(hjh]hstruct}(hjNGhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjJGhhh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chKaubj)}(h h]h }(hj\GhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjJGhhhj[GhKaubh)}(hhh]j )}(h dma_fenceh]h dma_fence}(hjmGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjjGubah}(h]h ]h"]h$]h&] refdomainjreftypejG reftargetjoGmodnameN classnameNjj)}j]jO)}jGsync_file_get_fencesbc.sync_file_get_fenceasbuh1hhjJGhhhj[GhKaubj)}(h h]h }(hjGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjJGhhhj[GhKaubjd)}(hjgh]h*}(hjGhhhNhNubah}(h]h ]jpah"]h$]h&]uh1jchjJGhhhj[GhKaubj )}(hsync_file_get_fenceh]j )}(hjGh]hsync_file_get_fence}(hjGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjGubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjJGhhhj[GhKaubj)}(h(int fd)h]j)}(hint fdh](jM)}(hinth]hint}(hjGhhhNhNubah}(h]h ]jYah"]h$]h&]uh1jLhjGubj)}(h h]h }(hjGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjGubj )}(hfdh]hfd}(hjGhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjGubeh}(h]h ]h"]h$]h&]noemphjjuh1jhjGubah}(h]h ]h"]h$]h&]jjuh1jhjJGhhhj[GhKaubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjFGhhhj[GhKaubah}(h]jAGah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhj[GhKahjCGhhubjA )}(hhh]h)}(h)get the fence related to the sync_file fdh]h)get the fence related to the sync_file fd}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chKahj Hhhubah}(h]h ]h"]h$]h&]uh1j@ hjCGhhhj[GhKaubeh}(h]h ](jfunctioneh"]h$]h&]ja jjb j&Hjc j&Hjd je jf uh1jhhhj!EhNhNubjh )}(h**Parameters** ``int fd`` sync_file fd to get the fence from **Description** Ensures **fd** references a valid sync_file and returns a fence that represents all fence in the sync_file. On error NULL is returned.h](h)}(h**Parameters**h]jr )}(hj0Hh]h Parameters}(hj2HhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj.Hubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chKehj*Hubj )}(hhh]j )}(h.``int fd`` sync_file fd to get the fence from h](j )}(h ``int fd``h]j)}(hjOHh]hint fd}(hjQHhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjMHubah}(h]h ]h"]h$]h&]uh1j h_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chKbhjIHubj )}(hhh]h)}(h"sync_file fd to get the fence fromh]h"sync_file fd to get the fence from}(hjhHhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjdHhKbhjeHubah}(h]h ]h"]h$]h&]uh1j hjIHubeh}(h]h ]h"]h$]h&]uh1j hjdHhKbhjFHubah}(h]h ]h"]h$]h&]uh1j hj*Hubh)}(h**Description**h]jr )}(hjHh]h Description}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjHubah}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chKdhj*Hubh)}(hEnsures **fd** references a valid sync_file and returns a fence that represents all fence in the sync_file. On error NULL is returned.h](hEnsures }(hjHhhhNhNubjr )}(h**fd**h]hfd}(hjHhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjHubhx references a valid sync_file and returns a fence that represents all fence in the sync_file. On error NULL is returned.}(hjHhhhNhNubeh}(h]h ]h"]h$]h&]uh1hh_/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:220: ./drivers/dma-buf/sync_file.chKchj*Hubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hj!EhhhNhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jsync_file (C struct) c.sync_filehNtauh1jhj!Ehhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:223: ./include/linux/sync_file.hhNubj)}(hhh](j)}(h sync_fileh]j)}(hstruct sync_fileh](j)}(hjh]hstruct}(hjHhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjHhhh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:223: ./include/linux/sync_file.hhKubj)}(h h]h }(hjHhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjHhhhjHhKubj )}(h sync_fileh]j )}(hjHh]h sync_file}(hjIhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjHubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjHhhhjHhKubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjHhhhjHhKubah}(h]jHah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjHhKhjHhhubjA )}(hhh]h)}(h$sync file to export to the userspaceh]h$sync file to export to the userspace}(hj$IhhhNhNubah}(h]h ]h"]h$]h&]uh1hh]/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:223: ./include/linux/sync_file.hhKhj!Ihhubah}(h]h ]h"]h$]h&]uh1j@ hjHhhhjHhKubeh}(h]h ](jstructeh"]h$]h&]ja jjb j )j? huh1jhjKhKhjxKhhubjA )}(hhh]h)}(h SYNC_IOC_MERGE: merge two fencesh]h SYNC_IOC_MERGE: merge two fences}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhjKhhubah}(h]h ]h"]h$]h&]uh1j@ hjxKhhhjKhKubeh}(h]h ](jstructeh"]h$]h&]ja jjb jKjc jKjd je jf uh1jhhhjXKhjwKhNubjh )}(hX{**Definition**:: struct sync_merge_data { char name[32]; __s32 fd2; __s32 fence; __u32 flags; __u32 pad; }; **Members** ``name`` name of new fence ``fd2`` file descriptor of second fence ``fence`` returns the fd of the new fence to userspace ``flags`` merge_data flags ``pad`` padding for 64-bit alignment, should always be zeroh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjKhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjKubh:}(hjKhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhjKubj)}(hnstruct sync_merge_data { char name[32]; __s32 fd2; __s32 fence; __u32 flags; __u32 pad; };h]hnstruct sync_merge_data { char name[32]; __s32 fd2; __s32 fence; __u32 flags; __u32 pad; };}hjLsbah}(h]h ]h"]h$]h&]jjuh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhjKubh)}(h **Members**h]jr )}(hjLh]hMembers}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjLubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK!hjKubj )}(hhh](j )}(h``name`` name of new fence h](j )}(h``name``h]j)}(hj2Lh]hname}(hj4LhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj0Lubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhj,Lubj )}(hhh]h)}(hname of new fenceh]hname of new fence}(hjKLhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjGLhKhjHLubah}(h]h ]h"]h$]h&]uh1j hj,Lubeh}(h]h ]h"]h$]h&]uh1j hjGLhKhj)Lubj )}(h(``fd2`` file descriptor of second fence h](j )}(h``fd2``h]j)}(hjkLh]hfd2}(hjmLhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjiLubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhjeLubj )}(hhh]h)}(hfile descriptor of second fenceh]hfile descriptor of second fence}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjLhKhjLubah}(h]h ]h"]h$]h&]uh1j hjeLubeh}(h]h ]h"]h$]h&]uh1j hjLhKhj)Lubj )}(h7``fence`` returns the fd of the new fence to userspace h](j )}(h ``fence``h]j)}(hjLh]hfence}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjLubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhjLubj )}(hhh]h)}(h,returns the fd of the new fence to userspaceh]h,returns the fd of the new fence to userspace}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjLhKhjLubah}(h]h ]h"]h$]h&]uh1j hjLubeh}(h]h ]h"]h$]h&]uh1j hjLhKhj)Lubj )}(h``flags`` merge_data flags h](j )}(h ``flags``h]j)}(hjLh]hflags}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjLubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhjLubj )}(hhh]h)}(hmerge_data flagsh]hmerge_data flags}(hjLhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjLhKhjLubah}(h]h ]h"]h$]h&]uh1j hjLubeh}(h]h ]h"]h$]h&]uh1j hjLhKhj)Lubj )}(h;``pad`` padding for 64-bit alignment, should always be zeroh](j )}(h``pad``h]j)}(hjMh]hpad}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjMubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhjMubj )}(hhh]h)}(h3padding for 64-bit alignment, should always be zeroh]h3padding for 64-bit alignment, should always be zero}(hj/MhhhNhNubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhj,Mubah}(h]h ]h"]h$]h&]uh1j hjMubeh}(h]h ]h"]h$]h&]uh1j hj+MhKhj)Lubeh}(h]h ]h"]h$]h&]uh1j hjKubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjXKhhhjwKhNubh)}(h**Description**h]jr )}(hjYMh]h Description}(hj[MhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjWMubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhjXKhhubh)}(hCreates a new fence containing copies of the sync_pts in both the calling fd and sync_merge_data.fd2. Returns the new fence's fd in sync_merge_data.fenceh]hCreates a new fence containing copies of the sync_pts in both the calling fd and sync_merge_data.fd2. Returns the new fence’s fd in sync_merge_data.fence}(hjoMhhhNhNubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhjXKhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jsync_fence_info (C struct)c.sync_fence_infohNtauh1jhjXKhhhjwKhNubj)}(hhh](j)}(hsync_fence_infoh]j)}(hstruct sync_fence_infoh](j)}(hjh]hstruct}(hjMhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjMhhhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK ubj)}(h h]h }(hjMhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjMhhhjMhK ubj )}(hsync_fence_infoh]j )}(hjMh]hsync_fence_info}(hjMhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjMubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjMhhhjMhK ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjMhhhjMhK ubah}(h]jMah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjMhK hjMhhubjA )}(hhh]h)}(hdetailed fence informationh]hdetailed fence information}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK'hjMhhubah}(h]h ]h"]h$]h&]uh1j@ hjMhhhjMhK ubeh}(h]h ](jstructeh"]h$]h&]ja jjb jMjc jMjd je jf uh1jhhhjXKhjwKhNubjh )}(hX**Definition**:: struct sync_fence_info { char obj_name[32]; char driver_name[32]; __s32 status; __u32 flags; __u64 timestamp_ns; }; **Members** ``obj_name`` name of parent sync_timeline ``driver_name`` name of driver implementing the parent ``status`` status of the fence 0:active 1:signaled <0:error ``flags`` fence_info flags ``timestamp_ns`` timestamp of status change in nanosecondsh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjMhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjMubh:}(hjMhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK+hjMubj)}(hstruct sync_fence_info { char obj_name[32]; char driver_name[32]; __s32 status; __u32 flags; __u64 timestamp_ns; };h]hstruct sync_fence_info { char obj_name[32]; char driver_name[32]; __s32 status; __u32 flags; __u64 timestamp_ns; };}hjNsbah}(h]h ]h"]h$]h&]jjuh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK-hjMubh)}(h **Members**h]jr )}(hj'Nh]hMembers}(hj)NhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hj%Nubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK5hjMubj )}(hhh](j )}(h*``obj_name`` name of parent sync_timeline h](j )}(h ``obj_name``h]j)}(hjFNh]hobj_name}(hjHNhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjDNubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK)hj@Nubj )}(hhh]h)}(hname of parent sync_timelineh]hname of parent sync_timeline}(hj_NhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj[NhK)hj\Nubah}(h]h ]h"]h$]h&]uh1j hj@Nubeh}(h]h ]h"]h$]h&]uh1j hj[NhK)hj=Nubj )}(h7``driver_name`` name of driver implementing the parent h](j )}(h``driver_name``h]j)}(hjNh]h driver_name}(hjNhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj}Nubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK*hjyNubj )}(hhh]h)}(h&name of driver implementing the parenth]h&name of driver implementing the parent}(hjNhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjNhK*hjNubah}(h]h ]h"]h$]h&]uh1j hjyNubeh}(h]h ]h"]h$]h&]uh1j hjNhK*hj=Nubj )}(h<``status`` status of the fence 0:active 1:signaled <0:error h](j )}(h ``status``h]j)}(hjNh]hstatus}(hjNhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjNubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK+hjNubj )}(hhh]h)}(h0status of the fence 0:active 1:signaled <0:errorh]h0status of the fence 0:active 1:signaled <0:error}(hjNhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjNhK+hjNubah}(h]h ]h"]h$]h&]uh1j hjNubeh}(h]h ]h"]h$]h&]uh1j hjNhK+hj=Nubj )}(h``flags`` fence_info flags h](j )}(h ``flags``h]j)}(hjNh]hflags}(hjNhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjNubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK,hjNubj )}(hhh]h)}(hfence_info flagsh]hfence_info flags}(hj OhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjOhK,hjOubah}(h]h ]h"]h$]h&]uh1j hjNubeh}(h]h ]h"]h$]h&]uh1j hjOhK,hj=Nubj )}(h:``timestamp_ns`` timestamp of status change in nanosecondsh](j )}(h``timestamp_ns``h]j)}(hj*Oh]h timestamp_ns}(hj,OhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj(Oubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK,hj$Oubj )}(hhh]h)}(h)timestamp of status change in nanosecondsh]h)timestamp of status change in nanoseconds}(hjCOhhhNhNubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK-hj@Oubah}(h]h ]h"]h$]h&]uh1j hj$Oubeh}(h]h ]h"]h$]h&]uh1j hj?OhK,hj=Nubeh}(h]h ]h"]h$]h&]uh1j hjMubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjXKhhhjwKhNubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jsync_file_info (C struct)c.sync_file_infohNtauh1jhjXKhhhjwKhNubj)}(hhh](j)}(hsync_file_infoh]j)}(hstruct sync_file_infoh](j)}(hjh]hstruct}(hjOhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjOhhhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK3ubj)}(h h]h }(hjOhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjOhhhjOhK3ubj )}(hsync_file_infoh]j )}(hj~Oh]hsync_file_info}(hjOhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjOubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjOhhhjOhK3ubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hj|OhhhjOhK3ubah}(h]jwOah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjOhK3hjyOhhubjA )}(hhh]h)}(h;SYNC_IOC_FILE_INFO: get detailed information on a sync_fileh]h;SYNC_IOC_FILE_INFO: get detailed information on a sync_file}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK7hjOhhubah}(h]h ]h"]h$]h&]uh1j@ hjyOhhhjOhK3ubeh}(h]h ](jstructeh"]h$]h&]ja jjb jOjc jOjd je jf uh1jhhhjXKhjwKhNubjh )}(hX**Definition**:: struct sync_file_info { char name[32]; __s32 status; __u32 flags; __u32 num_fences; __u32 pad; __u64 sync_fence_info; }; **Members** ``name`` name of fence ``status`` status of fence. 1: signaled 0:active <0:error ``flags`` sync_file_info flags ``num_fences`` number of fences in the sync_file ``pad`` padding for 64-bit alignment, should always be zero ``sync_fence_info`` pointer to array of struct :c:type:`sync_fence_info` with all fences in the sync_fileh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjOhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjOubh:}(hjOhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK;hjOubj)}(hstruct sync_file_info { char name[32]; __s32 status; __u32 flags; __u32 num_fences; __u32 pad; __u64 sync_fence_info; };h]hstruct sync_file_info { char name[32]; __s32 status; __u32 flags; __u32 num_fences; __u32 pad; __u64 sync_fence_info; };}hjPsbah}(h]h ]h"]h$]h&]jjuh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK=hjOubh)}(h **Members**h]jr )}(hjPh]hMembers}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjPubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKFhjOubj )}(hhh](j )}(h``name`` name of fence h](j )}(h``name``h]j)}(hj3Ph]hname}(hj5PhhhNhNubah}(h]h ]h"]h$]h&]uh1jhj1Pubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK9hj-Pubj )}(hhh]h)}(h name of fenceh]h name of fence}(hjLPhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjHPhK9hjIPubah}(h]h ]h"]h$]h&]uh1j hj-Pubeh}(h]h ]h"]h$]h&]uh1j hjHPhK9hj*Pubj )}(h:``status`` status of fence. 1: signaled 0:active <0:error h](j )}(h ``status``h]j)}(hjlPh]hstatus}(hjnPhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjjPubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK:hjfPubj )}(hhh]h)}(h.status of fence. 1: signaled 0:active <0:errorh]h.status of fence. 1: signaled 0:active <0:error}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjPhK:hjPubah}(h]h ]h"]h$]h&]uh1j hjfPubeh}(h]h ]h"]h$]h&]uh1j hjPhK:hj*Pubj )}(h``flags`` sync_file_info flags h](j )}(h ``flags``h]j)}(hjPh]hflags}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjPubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK;hjPubj )}(hhh]h)}(hsync_file_info flagsh]hsync_file_info flags}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjPhK;hjPubah}(h]h ]h"]h$]h&]uh1j hjPubeh}(h]h ]h"]h$]h&]uh1j hjPhK;hj*Pubj )}(h1``num_fences`` number of fences in the sync_file h](j )}(h``num_fences``h]j)}(hjPh]h num_fences}(hjPhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjPubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKhjJQubj )}(hhh]h)}(hUpointer to array of struct :c:type:`sync_fence_info` with all fences in the sync_fileh](hpointer to array of struct }(hjiQhhhNhNubh)}(h:c:type:`sync_fence_info`h]j)}(hjsQh]hsync_fence_info}(hjuQhhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhjqQubah}(h]h ]h"]h$]h&]refdocj refdomainjreftypetype refexplicitrefwarnjjjsync_fence_infouh1hhjeQhK>hjiQubh! with all fences in the sync_file}(hjiQhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhjeQhK>hjfQubah}(h]h ]h"]h$]h&]uh1j hjJQubeh}(h]h ]h"]h$]h&]uh1j hjeQhK>hj*Pubeh}(h]h ]h"]h$]h&]uh1j hjOubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjXKhhhjwKhNubh)}(h**Description**h]jr )}(hjQh]h Description}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjQubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKBhjXKhhubh)}(hXTakes a struct sync_file_info. If num_fences is 0, the field is updated with the actual number of fences. If num_fences is > 0, the system will use the pointer provided on sync_fence_info to return up to num_fences of struct sync_fence_info, with detailed fence information.h]hXTakes a struct sync_file_info. If num_fences is 0, the field is updated with the actual number of fences. If num_fences is > 0, the system will use the pointer provided on sync_fence_info to return up to num_fences of struct sync_fence_info, with detailed fence information.}(hjQhhhNhNubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK?hjXKhhubj)}(hhh]h}(h]h ]h"]h$]h&]entries](jsync_set_deadline (C struct)c.sync_set_deadlinehNtauh1jhjXKhhhjwKhNubj)}(hhh](j)}(hsync_set_deadlineh]j)}(hstruct sync_set_deadlineh](j)}(hjh]hstruct}(hjQhhhNhNubah}(h]h ]jah"]h$]h&]uh1jhjQhhhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKGubj)}(h h]h }(hjRhhhNhNubah}(h]h ]j ah"]h$]h&]uh1jhjQhhhjRhKGubj )}(hsync_set_deadlineh]j )}(hjQh]hsync_set_deadline}(hjRhhhNhNubah}(h]h ]j ah"]h$]h&]uh1j hjRubah}(h]h ](j' j( eh"]h$]h&]jjuh1j hjQhhhjRhKGubeh}(h]h ]h"]h$]h&]jjj2 uh1jj3 j4 hjQhhhjRhKGubah}(h]jQah ](j8 j9 eh"]h$]h&]j= j> )j? huh1jhjRhKGhjQhhubjA )}(hhh]h)}(h6SYNC_IOC_SET_DEADLINE - set a deadline hint on a fenceh]h6SYNC_IOC_SET_DEADLINE - set a deadline hint on a fence}(hj5RhhhNhNubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKPhj2Rhhubah}(h]h ]h"]h$]h&]uh1j@ hjQhhhjRhKGubeh}(h]h ](jstructeh"]h$]h&]ja jjb jMRjc jMRjd je jf uh1jhhhjXKhjwKhNubjh )}(h**Definition**:: struct sync_set_deadline { __u64 deadline_ns; __u64 pad; }; **Members** ``deadline_ns`` absolute time of the deadline ``pad`` must be zeroh](h)}(h**Definition**::h](jr )}(h**Definition**h]h Definition}(hjYRhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjURubh:}(hjURhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKThjQRubj)}(hCstruct sync_set_deadline { __u64 deadline_ns; __u64 pad; };h]hCstruct sync_set_deadline { __u64 deadline_ns; __u64 pad; };}hjrRsbah}(h]h ]h"]h$]h&]jjuh1jhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKVhjQRubh)}(h **Members**h]jr )}(hjRh]hMembers}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjRubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhK[hjQRubj )}(hhh](j )}(h.``deadline_ns`` absolute time of the deadline h](j )}(h``deadline_ns``h]j)}(hjRh]h deadline_ns}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjRubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKRhjRubj )}(hhh]h)}(habsolute time of the deadlineh]habsolute time of the deadline}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1hhjRhKRhjRubah}(h]h ]h"]h$]h&]uh1j hjRubeh}(h]h ]h"]h$]h&]uh1j hjRhKRhjRubj )}(h``pad`` must be zeroh](j )}(h``pad``h]j)}(hjRh]hpad}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1jhjRubah}(h]h ]h"]h$]h&]uh1j hb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKRhjRubj )}(hhh]h)}(h must be zeroh]h must be zero}(hjRhhhNhNubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKShjRubah}(h]h ]h"]h$]h&]uh1j hjRubeh}(h]h ]h"]h$]h&]uh1j hjRhKRhjRubeh}(h]h ]h"]h$]h&]uh1j hjQRubeh}(h]h ] kernelindentah"]h$]h&]uh1jg hjXKhhhjwKhNubh)}(h**Description**h]jr )}(hjSh]h Description}(hj ShhhNhNubah}(h]h ]h"]h$]h&]uh1jq hjSubah}(h]h ]h"]h$]h&]uh1hhb/var/lib/git/docbuild/linux/Documentation/driver-api/dma-buf:229: ./include/uapi/linux/sync_file.hhKVhjXKhhubh)}(hSAllows userspace to set a deadline on a fence, see :c:type:`dma_fence_set_deadline`h](h3Allows userspace to set a deadline on a fence, see }(hj4ShhhNhNubh)}(h :c:type:`dma_fence_set_deadline`h]j)}(hj>Sh]hdma_fence_set_deadline}(hj@ShhhNhNubah}(h]h ](jjc-typeeh"]h$]h&]uh1jhj userspace [label="memory management"] userspace -> kernel [label="Future fence, fence proxy, ..."] { rank=same; kernel userspace } }h]hX9digraph "Fencing Cycle" { node [shape=box bgcolor=grey style=filled] kernel [label="Kernel DMA Fences"] userspace [label="userspace controlled fences"] kernel -> userspace [label="memory management"] userspace -> kernel [label="Future fence, fence proxy, ..."] { rank=same; kernel userspace } }}hjTsbah}(h]h ]h"]h$]h&]jjuh1jhjThhubah}(h]h ]h"]h$]h&]alt#Indefinite Fencing Dependency CyclesrclangDOTuh1jThjTubhcaption)}(h#Indefinite Fencing Dependency Cycleh]h#Indefinite Fencing Dependency Cycle}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1jThhhKhjTubeh}(h]id1ah ]h"]h$]h&]altjTcaptionjTuh1jThjShhhhhNubh)}(hXThis means that the kernel might accidentally create deadlocks through memory management dependencies which userspace is unaware of, which randomly hangs workloads until the timeout kicks in. Workloads, which from userspace's perspective, do not contain a deadlock. In such a mixed fencing architecture there is no single entity with knowledge of all dependencies. Therefore preventing such deadlocks from within the kernel is not possible.Jh]hXThis means that the kernel might accidentally create deadlocks through memory management dependencies which userspace is unaware of, which randomly hangs workloads until the timeout kicks in. Workloads, which from userspace’s perspective, do not contain a deadlock. In such a mixed fencing architecture there is no single entity with knowledge of all dependencies. Therefore preventing such deadlocks from within the kernel is not possible.}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhMhjShhubh)}(hmThe only solution to avoid dependencies loops is by not allowing indefinite fences in the kernel. This means:h]hmThe only solution to avoid dependencies loops is by not allowing indefinite fences in the kernel. This means:}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhM$hjShhubh)}(hhh](j)}(hfNo future fences, proxy fences or userspace fences imported as DMA fences, with or without a timeout. h]h)}(heNo future fences, proxy fences or userspace fences imported as DMA fences, with or without a timeout.h]heNo future fences, proxy fences or userspace fences imported as DMA fences, with or without a timeout.}(hjThhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhM'hjTubah}(h]h ]h"]h$]h&]uh1jhjThhhhhNubj)}(hNo DMA fences that signal end of batchbuffer for command submission where userspace is allowed to use userspace fencing or long running compute workloads. This also means no implicit fencing for shared buffers in these cases. h]h)}(hNo DMA fences that signal end of batchbuffer for command submission where userspace is allowed to use userspace fencing or long running compute workloads. This also means no implicit fencing for shared buffers in these cases.h]hNo DMA fences that signal end of batchbuffer for command submission where userspace is allowed to use userspace fencing or long running compute workloads. This also means no implicit fencing for shared buffers in these cases.}(hj UhhhNhNubah}(h]h ]h"]h$]h&]uh1hhhhM*hjUubah}(h]h ]h"]h$]h&]uh1jhjThhhhhNubeh}(h]h ]h"]h$]h&]jRjguh1hhhhM'hjShhubeh}(h]indefinite-dma-fencesah ]h"]indefinite dma fencesah$]h&]uh1hhjhhhhhKubh)}(hhh](h)}(h-Recoverable Hardware Page Faults Implicationsh]h-Recoverable Hardware Page Faults Implications}(hj.UhhhNhNubah}(h]h ]h"]h$]h&]uh1hhj+UhhhhhM0ubh)}(haModern hardware supports recoverable page faults, which has a lot of implications for DMA fences.h]haModern hardware supports recoverable page faults, which has a lot of implications for DMA fences.}(hjIn some ways this page fault problem is a special case of the }(hjJVhhhNhNubhtitle_reference)}(h`Infinite DMA Fences`h]hInfinite DMA Fences}(hjTVhhhNhNubah}(h]h ]h"]h$]h&]uh1jRVhjJVubhXM discussions: Infinite fences from compute workloads are allowed to depend on DMA fences, but not the other way around. And not even the page fault problem is new, because some other CPU thread in userspace might hit a page fault which holds up a userspace fence - supporting page faults on GPUs doesn’t anything fundamentally new.}(hjJVhhhNhNubeh}(h]h ]h"]h$]h&]uh1hhhhMthj+Uhhubeh}(h]-recoverable-hardware-page-faults-implicationsah ]h"]-recoverable hardware page faults implicationsah$]h&]uh1hhjhhhhhM0ubeh}(h] dma-fencesah ]h"] dma fencesah$]h&]uh1hhhhhhhhKubeh}(h]*buffer-sharing-and-synchronization-dma-bufah ]h"],buffer sharing and synchronization (dma-buf)ah$]h&]uh1hhhhhhhhKubeh}(h]h ]h"]h$]h&]sourcehuh1hcurrent_sourceN current_lineNsettingsdocutils.frontendValues)}(hN generatorN datestampN source_linkN source_urlN toc_backlinksentryfootnote_backlinksK sectnum_xformKstrip_commentsNstrip_elements_with_classesN strip_classesN report_levelK halt_levelKexit_status_levelKdebugNwarning_streamN tracebackinput_encoding utf-8-siginput_encoding_error_handlerstrictoutput_encodingutf-8output_encoding_error_handlerjVerror_encodingutf-8error_encoding_error_handlerbackslashreplace language_codeenrecord_dependenciesNconfigN id_prefixhauto_id_prefixid dump_settingsNdump_internalsNdump_transformsNdump_pseudo_xmlNexpose_internalsNstrict_visitorN_disable_configN_sourcehʌ _destinationN _config_files]7/var/lib/git/docbuild/linux/Documentation/docutils.confafile_insertion_enabled raw_enabledKline_length_limitM'pep_referencesN pep_base_urlhttps://peps.python.org/pep_file_url_templatepep-%04drfc_referencesN rfc_base_url&https://datatracker.ietf.org/doc/html/ tab_widthKtrim_footnote_reference_spacesyntax_highlightlong smart_quotessmartquotes_locales]character_level_inline_markupdoctitle_xform docinfo_xformKsectsubtitle_xform image_loadinglinkembed_stylesheetcloak_email_addressessection_self_linkenvNubreporterNindirect_targets]substitution_defs}substitution_names}refnames}( cpu access to dma buffer objects]jaimplicit fence poll support](jjdUedma buffer ioctls]jaurefids}nameids}(jVj~Vj~j{jbjbjIjFjjjujjjjj-jjjbjbjjjyVjvVj/j,j]jZjjjjj~/j{/j@j@jEjEjUKjRKjSjSj(Uj%UjqVjnVu nametypes}(jVj~jbjIjjujjjjbjjyVj/j]jjj~/j@jEjUKjSj(UjqVuh}(j~Vhj{jZjbjjFj7jjLjjjjyj-jjjj` je js jx jjjbjjj j?jDj1j6j/j4jjjcjhj"j"j%j%j_'jd'j()j-)j*j*jd-ji-j/j/j2j2jZ5j_5j6j6j8j9jZ;j_;j=j=jJ@jO@jBjBjDjDjFjFjHjHj1Qj6QjWjWjnYjsYj\j \j^j^j_j_j8aj=ajjbjbjbjRdjWdjejejgjgjijijljljojpjqjqjsjsjujujpwjuwjyjyj}j}jjjjjمjޅjjj=jBjjj/j4jjjjjjjj jjj7j<jjÛjjjDjIjѢj֢j jj4j9jҨjרjRjWjj"jvVjj,jDjZj2jj`jjjjjj$jjj/j4jjjڼj߼jjjjjjjjjCjHjjjvj{j4j9jjjjjjjMjRjjjZj_j)j.j,j1jVj[jjjjjjjjjjjjjjjgjljjj~jj:j?j3j8jjjjjZj_j>jCjjjjj j$ jH jM jqjvjjjfjkjjjsjxjjjj jjj{/jj4j9jjj[#j`#j&j&j(j(j)j)j,j,j-j-j@j/j/j/jZ1j_1jx3j}3j6j6jJ9jO9j;j ;j<j<j=j=jP?jU?jEj@j@j@joBjtBjCjDjRKj!Ej>EjCEjAGjFGjHjHjSjXKjuKj{KjMjMjwOj|OjQjQj%UjSjnVj+UjTjTu footnote_refs} citation_refs} autofootnotes]autofootnote_refs]symbol_footnotes]symbol_footnote_refs] footnotes] citations]autofootnote_startKsymbol_footnote_startK id_counter collectionsCounter}jVKsRparse_messages]transform_messages] transformerN include_log] decorationNhhub.