NVIDIA DRIVE OS Linux SDK API Reference

5.1.12.0 Release

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Deep Learning Accelerator Synchronization

Detailed Description

The NvMedia DLA NvSciSync API encompasses all NvMediaDla NvSciSync handling functions.

Macros

#define NVMEDIA_DLA_NVSCISYNC_VERSION_MAJOR   1
 Major version number. More...
 
#define NVMEDIA_DLA_NVSCISYNC_VERSION_MINOR   1
 Minor version number. More...
 
#define NVMEDIA_DLA_MAX_PRENVSCISYNCFENCES   (8U)
 NvMediaDlaInsertPreNvSciSyncFence API can be called at most NVMEDIA_DLA_MAX_PRENVSCISYNCFENCES times before each Dla submit call. More...
 

Functions

NvMediaStatus NvMediaDlaNvSciSyncGetVersion (NvMediaVersion *version)
 Returns the version information for the NvMedia DLA NvSciSync library. More...
 
NvMediaStatus NvMediaDlaFillNvSciSyncAttrList (const NvMediaDla *dla, NvSciSyncAttrList attrlist, NvMediaNvSciSyncClientType clienttype)
 Fills the NvMediaDla specific NvSciSync attributes. More...
 
NvMediaStatus NvMediaDlaRegisterNvSciSyncObj (NvMediaDla *dla, NvMediaNvSciSyncObjType syncobjtype, NvSciSyncObj nvscisync)
 Registers an NvSciSyncObj with NvMediaDla. More...
 
NvMediaStatus NvMediaDlaUnregisterNvSciSyncObj (NvMediaDla *dla, NvSciSyncObj nvscisync)
 Unregisters an NvSciSyncObj with NvMediaDla. More...
 
NvMediaStatus NvMediaDlaSetNvSciSyncObjforSOF (NvMediaDla *dla, NvSciSyncObj nvscisyncSOF)
 Sets the NvSciSyncObj to be used for a Start of Frame (SOF) NvSciSyncFence. More...
 
NvMediaStatus NvMediaDlaSetNvSciSyncObjforEOF (NvMediaDla *dla, NvSciSyncObj nvscisyncEOF)
 Sets an NvSciSyncObj to be used for a End of Frame (EOF) NvSciSyncFence. More...
 
NvMediaStatus NvMediaDlaInsertPreNvSciSyncFence (NvMediaDla *dla, const NvSciSyncFence *prenvscisyncfence)
 Sets an NvSciSyncFence as a prefence for a DLA submit operation. More...
 
NvMediaStatus NvMediaDlaGetSOFNvSciSyncFence (const NvMediaDla *dla, NvSciSyncObj sofnvscisyncobj, NvSciSyncFence *sofnvscisyncfence)
 Gets an SOF NvSciSyncFence for a DLA submit operation. More...
 
NvMediaStatus NvMediaDlaGetEOFNvSciSyncFence (const NvMediaDla *dla, NvSciSyncObj eofnvscisyncobj, NvSciSyncFence *eofnvscisyncfence)
 Gets an EOF NvSciSyncFence for a DLA submit operation. More...
 

Macro Definition Documentation

#define NVMEDIA_DLA_MAX_PRENVSCISYNCFENCES   (8U)

NvMediaDlaInsertPreNvSciSyncFence API can be called at most NVMEDIA_DLA_MAX_PRENVSCISYNCFENCES times before each Dla submit call.

Definition at line 47 of file nvmedia_dla_nvscisync.h.

#define NVMEDIA_DLA_NVSCISYNC_VERSION_MAJOR   1

Major version number.

Definition at line 39 of file nvmedia_dla_nvscisync.h.

#define NVMEDIA_DLA_NVSCISYNC_VERSION_MINOR   1

Minor version number.

Definition at line 41 of file nvmedia_dla_nvscisync.h.

Function Documentation

NvMediaStatus NvMediaDlaFillNvSciSyncAttrList ( const NvMediaDla dla,
NvSciSyncAttrList  attrlist,
NvMediaNvSciSyncClientType  clienttype 
)

Fills the NvMediaDla specific NvSciSync attributes.

This API assumes that attrlist is a valid NvSciSyncAttrList.

This function sets the public attribute:

The application must not set this attribute.

Parameters
[in]dlaAn NvMedia DLA device handle.
[in,out]attrlistA pointer to an NvSciSyncAttrList structure where NvMedia places NvSciSync attributes.
[in]clienttypeIndicates whether the attrlist is requested for an NvMediaDla signaler or an NvMediaDla waiter.
Returns
NvMediaStatus, the completion status of the operation:
NvMediaStatus NvMediaDlaGetEOFNvSciSyncFence ( const NvMediaDla dla,
NvSciSyncObj  eofnvscisyncobj,
NvSciSyncFence eofnvscisyncfence 
)

Gets an EOF NvSciSyncFence for a DLA submit operation.

An EOF NvSciSyncFence is associated with a DLA submit operation and its expiry indicates that the corresponding DLA submit operation has finished. NvMediaDlaGetEOFNvSciSyncFence returns the EOF NvSciSyncFence associated with the last DLA submit call.

If you use NvMediaDlaGetEOFNvSciSyncFence(), you must call it after calling a DLA submit function.

Parameters
[in]dlaAn NvMedia DLA device handle.
[in]eofnvscisyncobjAn EOF NvSciSyncObj associated with the NvSciSyncFence being requested. This structure will be modified by this function.
[out]eofnvscisyncfenceA pointer to the EOF NvSciSyncFence.
Returns
NvMediaStatus, the completion status of the operation:
NvMediaStatus NvMediaDlaGetSOFNvSciSyncFence ( const NvMediaDla dla,
NvSciSyncObj  sofnvscisyncobj,
NvSciSyncFence sofnvscisyncfence 
)

Gets an SOF NvSciSyncFence for a DLA submit operation.

Note: This API is currently not supported.

An SOF NvSciSyncFence is associated with a DLA submit operation, and its expiry indicates that the corresponding DLA submit operation has started. NvMediaDlaGetSOFNvSciSyncFence() returns the SOF NvSciSyncFence associated with the last DLA submit call.

If you use NvMediaDlaGetSOFNvSciSyncFence(), you must call it after calling the DLA submit function.

Parameters
[in]dlaAn NvMedia DLA device handle.
[in]sofnvscisyncobjThe SOF NvSciSyncObj associated with the NvSciSyncFence being requested. This structure will be modified by this function.
[out]sofnvscisyncfenceA pointer to the SOF NvSciSyncFence.
Returns
NvMediaStatus, the completion status of the operation:
NvMediaStatus NvMediaDlaInsertPreNvSciSyncFence ( NvMediaDla dla,
const NvSciSyncFence prenvscisyncfence 
)

Sets an NvSciSyncFence as a prefence for a DLA submit operation.

If you use NvMediaDlaInsertPreNvSciSyncFence(), the application must call it before calling a DLA submit API. The following DLA submit operation is started only after the expiry of the prenvscisyncfence.

You can set a maximum of NVMEDIA_DLA_MAX_PRENVSCISYNCFENCES prefences by calling NvMediaDlaInsertPreNvSciSyncFence() before calling a DLA submit function.

After a call to the DLA submit function, all NvSciSyncFences previously inserted by NvMediaDlaInsertPreNvSciSyncFence() are cleared, and they are not reused for subsequent DLA submit calls.

Parameters
[in]dlaAn NvMedia DLA device handle.
[in]prenvscisyncfenceA pointer to NvSciSyncFence.
Returns
NvMediaStatus, the completion status of the operation:
NvMediaStatus NvMediaDlaNvSciSyncGetVersion ( NvMediaVersion version)

Returns the version information for the NvMedia DLA NvSciSync library.

Parameters
[out]versionA pointer to an NvMediaVersion structure filled by the DLA NvSciSync library.
Returns
NvMediaStatus, the completion status of the operation:
NvMediaStatus NvMediaDlaRegisterNvSciSyncObj ( NvMediaDla dla,
NvMediaNvSciSyncObjType  syncobjtype,
NvSciSyncObj  nvscisync 
)

Registers an NvSciSyncObj with NvMediaDla.

Every NvSciSyncObj(even duplicate objects) used by NvMediaDla must be registered by a call to this function before it is used. Only the exact same registered NvSciSyncObj can be passed to the run time APIs.

For a given NvMediaDla handle, one NvSciSyncObj can be registered as one NvMediaNvSciSyncObjType only. For each NvMediaNvSciSyncObjType, a maximum of 16 NvSciSyncObj objects can be registered.

Parameters
[in]dlaAn NvMedia DLA device handle.
[in]syncobjtypeDetermines how nvscisync is used by dla.
[in]nvscisyncThe NvSciSyncObj to be registered with dla.
Returns
NvMediaStatus, the completion status of the operation:
NvMediaStatus NvMediaDlaSetNvSciSyncObjforEOF ( NvMediaDla dla,
NvSciSyncObj  nvscisyncEOF 
)

Sets an NvSciSyncObj to be used for a End of Frame (EOF) NvSciSyncFence.

To use NvMediaDlaGetEOFNvSciSyncFence(), the application must call this function before the calling the first DLA submit API. NvMedia DLA currently accepts only one EOF NvSciSyncObj.

Parameters
[in]dlaAn NvMedia DLA device handle.
[in]nvscisyncEOFA registered NvSciSyncObj which is to be associated with EOF NvSciSyncFence.
Returns
NvMediaStatus, the completion status of the operation:
NvMediaStatus NvMediaDlaSetNvSciSyncObjforSOF ( NvMediaDla dla,
NvSciSyncObj  nvscisyncSOF 
)

Sets the NvSciSyncObj to be used for a Start of Frame (SOF) NvSciSyncFence.

Note
This API is currently not supported.

To use NvMediaDlaGetSOFNvSciSyncFence(), the application must call this function before the first DLA submit API. NvMedia DlA currently accepts only one SOF NvSciSyncObj.

Parameters
[in]dlaAn NvMedia DLA device handle.
[in]nvscisyncSOFA registered NvSciSyncObj to be associated with SOF NvSciSyncFence.
Returns
NvMediaStatus, the completion status of the operation:
NvMediaStatus NvMediaDlaUnregisterNvSciSyncObj ( NvMediaDla dla,
NvSciSyncObj  nvscisync 
)

Unregisters an NvSciSyncObj with NvMediaDla.

During teardown, every NvSciSyncObj registered with NvMediaDla must be unregistered before calling NvMediaDlaDestroy().

Before the application calls this function, it must ensure that the application is in teardown mode, and any NvMediaDla operation using this nvscisync has completed. If the function is called while nvscisync is still in use by any NvMediaDla operations, the behavior is undefined.

Parameters
[in]dlaAn NvMedia DLA device handle.
[in]nvscisyncAn NvSciSyncObj to be unregistered with dla.
Returns
NvMediaStatus, the completion status of the operation: