NVIDIA DRIVE OS Linux SDK API Reference

5.1.6.0 Release

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages

Detailed Description

List of APIs to transport NvSciBuf buffers and attribute list objects across various communication boundaries that interact using NvSciIpc.

Functions

NvSciError NvSciBufIpcExportAttrListAndObj (NvSciBufObj bufObj, NvSciBufAttrValAccessPerm permissions, NvSciIpcEndpoint ipcEndpoint, void **attrListAndObjDesc, size_t *attrListAndObjDescSize)
 Exports an NvSciBuf attribute list and object into an NvSciIpc-transferable object binary descriptor. More...
 
NvSciError NvSciBufIpcImportAttrListAndObj (NvSciBufModule module, NvSciIpcEndpoint ipcEndpoint, const void *attrListAndObjDesc, size_t attrListAndObjDescSize, const NvSciBufAttrList attrList[], size_t count, NvSciBufAttrValAccessPerm minPermissions, int64_t timeoutUs, NvSciBufObj *bufObj)
 This API is invoked by importing process after it receives the binary blob sent by the other process who has created the binary descriptor. More...
 
void NvSciiBufAttrListAndObjFreeDesc (void *attrListAndObjDescBuf)
 Frees the descriptor used for exporting/importing both attrlist and NvSciBuf Object together. More...
 
NvSciError NvSciBufObjIpcExport (NvSciBufObj bufObj, NvSciBufAttrValAccessPerm accPerm, NvSciIpcEndpoint ipcEndPoint, NvSciBufObjIpcExportDescriptor *exportData)
 Exports a NvSciBuf object into an NvSciIpc-transferable object binary descriptor. More...
 
NvSciError NvSciBufObjIpcImport (NvSciIpcEndpoint ipcEndPoint, const NvSciBufObjIpcExportDescriptor *desc, NvSciBufAttrList reconciledAttrList, NvSciBufAttrValAccessPerm minPermissions, int64_t timeoutUs, NvSciBufObj *bufObj)
 Creates a NvSciBuf object based on supplied binary descriptor and returns the NvSciBuf object. More...
 
NvSciError NvSciBufAttrListIpcExportUnreconciled (NvSciBufAttrList unreconciledAttrListArray[], size_t unreconciledAttrListCount, NvSciIpcEndpoint ipcEndpoint, void **descBuf, size_t *descLen)
 Transforms the input attribute list(s) to an exported attribute list descriptor that can be transported by the application to any remote process as serialized set of bytes over an IPC/IVC/nvIPC channel. More...
 
NvSciError NvSciBufAttrListIpcExportReconciled (NvSciBufAttrList reconciledAttrList, NvSciIpcEndpoint ipcEndpoint, void **descBuf, size_t *descLen)
 Transforms the input attribute list(s) to an exported attribute list descriptor that can be transported by the application to any remote process as serialized set of bytes over an IPC/IVC/nvIPC channel. More...
 
NvSciError NvSciBufAttrListIpcImportUnreconciled (NvSciBufModule module, NvSciIpcEndpoint ipcEndpoint, const void *descBuf, size_t descLen, NvSciBufAttrList *importedUnreconciledAttrList)
 Retrieves the attribute list from the attribute descriptor received over IPC channel. More...
 
NvSciError NvSciBufAttrListIpcImportReconciled (NvSciBufModule module, NvSciIpcEndpoint ipcEndpoint, const void *descBuf, size_t descLen, NvSciBufAttrList inputUnreconciledAttrListArray[], size_t inputUnreconciledAttrListCount, NvSciBufAttrList *importedReconciledAttrList)
 Retrieves the attribute list from the attribute descriptor received over IPC channel. More...
 
void NvSciBufAttrListFreeDesc (void *descBuf)
 Frees the NvSciBuf exported attribute list descriptor. More...
 

Function Documentation

void NvSciBufAttrListFreeDesc ( void *  descBuf)

Frees the NvSciBuf exported attribute list descriptor.

Parameters
[in]descBufAttribute list descriptor to be freed.
Returns
void
NvSciError NvSciBufAttrListIpcExportReconciled ( NvSciBufAttrList  reconciledAttrList,
NvSciIpcEndpoint  ipcEndpoint,
void **  descBuf,
size_t *  descLen 
)

Transforms the input attribute list(s) to an exported attribute list descriptor that can be transported by the application to any remote process as serialized set of bytes over an IPC/IVC/nvIPC channel.

Parameters
[in]reconciledAttrListReconciled attribute list.
[in]ipcEndpointThe NvSciIpc endpoint through which the caller may send the exported attribute list descriptor provided by this function.
[out]descBufAddress at which pointer to exported attribute list descriptor is to be stored.
[out]descLenAddress at which the size of the exported attribute list descriptor is to be stored.
Returns
NvSciError, the completion code of this operation:
NvSciError NvSciBufAttrListIpcExportUnreconciled ( NvSciBufAttrList  unreconciledAttrListArray[],
size_t  unreconciledAttrListCount,
NvSciIpcEndpoint  ipcEndpoint,
void **  descBuf,
size_t *  descLen 
)

Transforms the input attribute list(s) to an exported attribute list descriptor that can be transported by the application to any remote process as serialized set of bytes over an IPC/IVC/nvIPC channel.

Parameters
[in]unreconciledAttrListArray[]Array of unreconciled attribute lists.
[in]unreconciledAttrListCountNumber of unreconciled attribute lists in unreconciledAttrListArray[].
[in]ipcEndpointThe NvSciIpc endpoint through which the caller may send the exported attribute list descriptor provided by this function.
[out]descBufAddress at which the pointer to exported attribute list descriptor is to be stored.
[out]descLenAddress at which the size of the exported attribute list descriptor is to be stored.
Returns
NvSciError, the completion code of this operation:
NvSciError NvSciBufAttrListIpcImportReconciled ( NvSciBufModule  module,
NvSciIpcEndpoint  ipcEndpoint,
const void *  descBuf,
size_t  descLen,
NvSciBufAttrList  inputUnreconciledAttrListArray[],
size_t  inputUnreconciledAttrListCount,
NvSciBufAttrList importedReconciledAttrList 
)

Retrieves the attribute list from the attribute descriptor received over IPC channel.

When importing a reconciled attribute list, it will also validate the attribute list to be imported against the provided input unreconciled attribute lists. (This is required while importing a reconciled attribute list to cause NvSciBuf to validate the reconciled attributes against the input attributes so that the process can be sure that a buffer consistent with the imported reconciled list will satisfy the input constraints.)

Parameters
[in]moduleThe NvSciBuf module instance with which to associate the imported NvSciBufAttrList.
[in]ipcEndpointThe NvSciIpc endpoint through which the caller may send the exported attribute list descriptor provided by this function.
[in]descBufAddress at which pointer to imported attribute list descriptor is to be stored.
[in]descLenThe size of the imported attribute list descriptor.
[in]inputUnreconciledAttrListArrayArray of unreconciled list against imported reconciled list will be verified.
[in]inputUnreconciledAttrListCountNumber of unreconciled attribute list in unreconciledAttrListArray[].
[out]importedReconciledAttrListThe imported reconciled attribute list.
Returns
NvSciError, the completion code of this operation:
NvSciError NvSciBufAttrListIpcImportUnreconciled ( NvSciBufModule  module,
NvSciIpcEndpoint  ipcEndpoint,
const void *  descBuf,
size_t  descLen,
NvSciBufAttrList importedUnreconciledAttrList 
)

Retrieves the attribute list from the attribute descriptor received over IPC channel.

When importing a reconciled attribute list, it will also validate the attribute list to be imported against the provided input unreconciled attribute lists. (This is required while importing a reconciled attribute list to cause NvSciBuf to validate the reconciled attributes against the input attributes so that the process can be sure that a buffer consistent with the imported reconciled list will satisfy the input constraints.)

Parameters
[in]moduleThe NvSciBuf module instance with which to associate the imported NvSciBufAttrList.
[in]ipcEndpointThe NvSciIpc endpoint through which the caller may send the exported attribute list descriptor provided by this function.
[in]descBufAddress at which pointer to imported attribute list descriptor is to be stored.
[in]descLenThe size of the imported attribute list descriptor.
[out]importedUnreconciledAttrListThe imported unreconciled attribute list.
Returns
NvSciError, the completion code of this operation:
NvSciError NvSciBufIpcExportAttrListAndObj ( NvSciBufObj  bufObj,
NvSciBufAttrValAccessPerm  permissions,
NvSciIpcEndpoint  ipcEndpoint,
void **  attrListAndObjDesc,
size_t *  attrListAndObjDescSize 
)

Exports an NvSciBuf attribute list and object into an NvSciIpc-transferable object binary descriptor.

The blob can be transferred to the other processes to create a matching NvSciBuf object.

Parameters
[in]bufObjNvSciBuf Object to export.
[in]permissionsFlag indicating the expected access permission (see NvSciBufAttrValAccessPerm).
[in]ipcEndpointNvSciIpcEndpoint to identify the peer process.
[out]attrListAndObjDescNvSciBuf allocates and fills in the exported form of NvSciBufObj and its corresponding attribute list to be shared across an NvSciIpc channel.
[out]attrListAndObjDescSizeSize of the exported blob.
Returns
NvSciError, the completion code of this operation:
NvSciError NvSciBufIpcImportAttrListAndObj ( NvSciBufModule  module,
NvSciIpcEndpoint  ipcEndpoint,
const void *  attrListAndObjDesc,
size_t  attrListAndObjDescSize,
const NvSciBufAttrList  attrList[],
size_t  count,
NvSciBufAttrValAccessPerm  minPermissions,
int64_t  timeoutUs,
NvSciBufObj bufObj 
)

This API is invoked by importing process after it receives the binary blob sent by the other process who has created the binary descriptor.

Importing process will create its own NvSciBuf object and return as output.

Parameters
[in]moduleInstance of the NvSciBufModule to be used for importing NvSciBuf Object.
[in]ipcEndpointNvSciIpcEndpoint to identify the peer process.
[in]attrListAndObjDescThe exported form of attribute list and NvSciBufObj.
[in]attrListAndObjDescSizeSize of the imported blob.
[in]attrList[]Receiver side array of attribute lists against which the imported attrList has to be validated.
[in]countNumber of NvSciBufAttrList objects in the array.
[in]minPermissionsMinimum permissions of the buffer that the process is expecting to import the buffer (see NvSciBufAttrValAccessPerm).
[in]timeoutUsMaximum delay (in microseconds) before an NvSciBuf object times out.
[out]bufObjNvSciBuf Object duplicated and exported during the importing process. It contains the attribute list to be shared across an NvSciIpc channel.
[out]attrListAndObjDescSizeSize of the exported blob.
Returns
NvSciError, the completion code of this operation:
NvSciError NvSciBufObjIpcExport ( NvSciBufObj  bufObj,
NvSciBufAttrValAccessPerm  accPerm,
NvSciIpcEndpoint  ipcEndPoint,
NvSciBufObjIpcExportDescriptor exportData 
)

Exports a NvSciBuf object into an NvSciIpc-transferable object binary descriptor.

Descriptor can be transferred to other end of IPC where matching NvSciBuf object can be created from the descriptor.

Parameters
[in]bufObjNvSciBuf object to export.
[in]accPermFlag indicating the expected access permission (see NvSciBufAttrValAccessPerm).
[in]ipcEndPointHandle to IPC endpoint.
[out]exportDataNvSciBuf populates the return value with exported form of NvSciBufObj shared across an NvSciIpc channel.
Returns
NvSciError, the completion code of this operation:
NvSciError NvSciBufObjIpcImport ( NvSciIpcEndpoint  ipcEndPoint,
const NvSciBufObjIpcExportDescriptor desc,
NvSciBufAttrList  reconciledAttrList,
NvSciBufAttrValAccessPerm  minPermissions,
int64_t  timeoutUs,
NvSciBufObj bufObj 
)

Creates a NvSciBuf object based on supplied binary descriptor and returns the NvSciBuf object.

Parameters
[in]ipcEndPointIdentifier of type NvSciIpcEndpoint.
[in]descA pointer to an NvSciBufObjIpcExportedDescriptor, an exported form of NvSciBufObj received via the NvIpc channel.
[in]reconciledAttrListReconciled attribute list returned by NvSciBufAttrListImport().
[in]minPermissionsFlag indicating the expected access permission.
[in]timeoutUsImport timeout in micro seconds, -1 for infinite wait.
[out]bufObjImported NvSciBufObj created from the descriptor.
Returns
NvSciError, the completion code of this operation:
void NvSciiBufAttrListAndObjFreeDesc ( void *  attrListAndObjDescBuf)

Frees the descriptor used for exporting/importing both attrlist and NvSciBuf Object together.

Parameters
[in]attrListAndObjDescBufDescriptor to be freed.