NVIDIA DRIVE OS Linux SDK API Reference

6.0.8 Release
nvscisync.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2019-2023, NVIDIA CORPORATION. All rights reserved.
3  *
4  * NVIDIA Corporation and its licensors retain all intellectual property
5  * and proprietary rights in and to this software, related documentation
6  * and any modifications thereto. Any use, reproduction, disclosure or
7  * distribution of this software and related documentation without an express
8  * license agreement from NVIDIA Corporation is strictly prohibited.
9  */
18 #ifndef INCLUDED_NVSCISYNC_H
19 #define INCLUDED_NVSCISYNC_H
20 
151 #if !defined (__cplusplus)
152 #include <stddef.h>
153 #include <stdbool.h>
154 #include <stdint.h>
155 #endif
156 
157 #include "nvscierror.h"
158 #include "nvsciipc.h"
159 #include "nvscibuf.h"
160 
161 #if defined (__cplusplus)
162 extern "C"
163 {
164 #endif
165 
166 #if defined __GNUC__
167  #define PACK_SYNC( __Declaration__, ... ) __Declaration__,##__VA_ARGS__ __attribute__((packed))
168 #else
169  #define PACK_SYNC( __Declaration__, ... ) __pragma(pack(push, 1)) __Declaration__,##__VA_ARGS__ __pragma(pack(pop))
170 #endif
171 
177 static const uint32_t NvSciSyncMajorVersion = 2U;
178 
184 static const uint32_t NvSciSyncMinorVersion = 7U;
185 
191 static const int64_t NvSciSyncFenceMaxTimeout = (0x7fffffffffffffff / 1000);
192 
204 typedef struct NvSciSyncModuleRec* NvSciSyncModule;
205 
216 typedef struct NvSciSyncCpuWaitContextRec* NvSciSyncCpuWaitContext;
217 
249 typedef struct NvSciSyncFence {
250  uint64_t payload[6];
252 
260 
267 typedef struct {
268  uint64_t payload[7];
270 
277 typedef struct {
279  uint64_t payload[128];
281 
304 typedef struct NvSciSyncObjRec* NvSciSyncObj;
305 
310 typedef const struct NvSciSyncObjRec* NvSciSyncObjConst;
311 
323 typedef struct NvSciSyncAttrListRec* NvSciSyncAttrList;
324 
330 typedef uint64_t NvSciSyncAccessPerm;
331 
336 #if defined(__cplusplus)
337  #define NvSciSyncAccessPerm_WaitOnly (static_cast<uint64_t>(1U) << 0U)
338 #else
339  #define NvSciSyncAccessPerm_WaitOnly ((uint64_t)1U << 0U)
340 #endif
341 
346 #if defined(__cplusplus)
347  #define NvSciSyncAccessPerm_SignalOnly (static_cast<uint64_t>(1U) << 1U)
348 #else
349  #define NvSciSyncAccessPerm_SignalOnly ((uint64_t)1U << 1U)
350 #endif
351 
357 #define NvSciSyncAccessPerm_WaitSignal (NvSciSyncAccessPerm_WaitOnly | NvSciSyncAccessPerm_SignalOnly)
358 
363 #if defined(__cplusplus)
364  #define NvSciSyncAccessPerm_Auto (static_cast<uint64_t>(1U) << 63U)
365 #else
366  #define NvSciSyncAccessPerm_Auto ((uint64_t)1U << 63U)
367 #endif
368 
380 typedef enum {
389 
395 PACK_SYNC(typedef struct {
397  uint64_t timestamp;
399  uint32_t statusEngine;
401  uint16_t subframe;
405  uint16_t status;
406 }) NvSciSyncTaskStatus;
407 
447 };
448 
455 
468 typedef enum {
626 
632 #if (NV_IS_SAFETY == 0)
633 
638 #else
639 
642 #endif
653 
661 typedef struct {
667  const void* value;
669  size_t len;
671 
706  NvSciSyncModule* newModule);
707 
748  NvSciSyncModule module);
749 
785  NvSciSyncModule module,
786  NvSciSyncCpuWaitContext* newContext);
787 
817  NvSciSyncCpuWaitContext context);
818 
854  NvSciSyncModule module,
855  NvSciSyncAttrList* attrList);
856 
886  NvSciSyncAttrList attrList);
887 
917  NvSciSyncAttrList attrList,
918  bool* isReconciled);
919 
975  NvSciSyncAttrList reconciledAttrList,
976  const NvSciSyncAttrList inputUnreconciledAttrListArray[],
977  size_t inputUnreconciledAttrListCount,
978  bool* isReconciledListValid);
979 
1029  NvSciSyncAttrList attrList,
1030  const NvSciSyncAttrKeyValuePair* pairArray,
1031  size_t pairCount);
1032 
1076  NvSciSyncAttrList attrList,
1077  NvSciSyncAttrKeyValuePair* pairArray,
1078  size_t pairCount);
1079 
1104  NvSciSyncAttrList attrList);
1105 
1162  const NvSciSyncAttrList inputUnreconciledAttrListArray[],
1163  size_t inputUnreconciledAttrListCount,
1164  NvSciSyncAttrList* newUnreconciledAttrList);
1165 
1207  NvSciSyncAttrList origAttrList,
1208  NvSciSyncAttrList* newAttrList);
1209 
1258  NvSciSyncAttrList attrList,
1259  size_t slotIndex,
1260  NvSciSyncAttrKeyValuePair* pairArray,
1261  size_t pairCount);
1262 
1271 #if (NV_IS_SAFETY == 0)
1272 
1278 #endif
1279 
1289 #if (NV_IS_SAFETY == 0)
1290 
1295 #else
1296 
1299 #endif
1300 
1315 #if (NV_IS_SAFETY == 0)
1316 
1318 #endif
1319 
1349  const NvSciSyncAttrList inputArray[],
1350  size_t inputCount,
1351  NvSciSyncAttrList* newReconciledList,
1352  NvSciSyncAttrList* newConflictList);
1353 
1354 #if (NV_IS_SAFETY == 0)
1355 
1392  NvSciSyncAttrList attrList,
1393  void** buf,
1394  size_t* len);
1395 #endif
1396 
1444 #if (NV_IS_SAFETY == 0)
1445 
1448 #endif
1449 
1472  const NvSciSyncAttrList unreconciledAttrListArray[],
1473  size_t unreconciledAttrListCount,
1474  NvSciIpcEndpoint ipcEndpoint,
1475  void** descBuf,
1476  size_t* descLen);
1477 
1524  const NvSciSyncAttrList reconciledAttrList,
1525  NvSciIpcEndpoint ipcEndpoint,
1526  void** descBuf,
1527  size_t* descLen);
1528 
1579  NvSciSyncModule module,
1580  NvSciIpcEndpoint ipcEndpoint,
1581  const void* descBuf,
1582  size_t descLen,
1583  NvSciSyncAttrList* importedUnreconciledAttrList);
1584 
1665  NvSciSyncModule module,
1666  NvSciIpcEndpoint ipcEndpoint,
1667  const void* descBuf,
1668  size_t descLen,
1669  const NvSciSyncAttrList inputUnreconciledAttrListArray[],
1670  size_t inputUnreconciledAttrListCount,
1671  NvSciSyncAttrList* importedReconciledAttrList);
1672 
1701  void* descBuf);
1702 
1731 void NvSciSyncFenceClear(
1732  NvSciSyncFence* syncFence);
1733 
1774  const NvSciSyncFence* srcSyncFence,
1775  NvSciSyncFence* dstSyncFence);
1776 
1808  const NvSciSyncFence* syncFence,
1809  uint64_t* id,
1810  uint64_t* value);
1811 
1864  NvSciSyncObj syncObj,
1865  uint64_t id,
1866  uint64_t value,
1867  NvSciSyncFence* syncFence);
1868 
1902  NvSciSyncFence* syncFence,
1903  uint32_t timestampSlot);
1904 
1938  NvSciSyncFence* syncFence,
1939  uint32_t taskStatusSlot);
1940 
1973  NvSciSyncFence* syncFence,
1974  uint32_t* timeStampSlot);
1975 
2019  NvSciSyncAttrList reconciledList,
2020  NvSciSyncObj* syncObj);
2021 
2063  NvSciSyncObj syncObj,
2064  NvSciSyncObj* dupObj);
2065 
2100  NvSciSyncObj syncObj,
2101  NvSciSyncAttrList* syncAttrList);
2102 
2141 void NvSciSyncObjFree(
2142  NvSciSyncObj syncObj);
2143 
2181 #if (NV_L4T == 1)
2182 
2186 #endif
2187 
2208  NvSciSyncObj syncObj,
2209  NvSciSyncAccessPerm permissions,
2210  NvSciIpcEndpoint ipcEndpoint,
2212 
2283  NvSciIpcEndpoint ipcEndpoint,
2284  const NvSciSyncObjIpcExportDescriptor* desc,
2285  NvSciSyncAttrList inputAttrList,
2286  NvSciSyncAccessPerm permissions,
2287  int64_t timeoutUs,
2288  NvSciSyncObj* syncObj);
2289 
2331  const NvSciSyncFence* syncFence,
2332  NvSciIpcEndpoint ipcEndpoint,
2334 
2380  NvSciSyncObj syncObj,
2382  NvSciSyncFence* syncFence);
2383 
2388 #if (NV_IS_SAFETY == 0)
2389 
2397 #else
2398 
2413 #endif
2414 
2432  NvSciSyncObj syncObj);
2433 
2449 #if (NV_IS_SAFETY == 0)
2450 
2453 #endif
2454 
2479  NvSciSyncObj syncObj,
2480  NvSciSyncFence* syncFence);
2481 
2486 #if (NV_IS_SAFETY == 0)
2487 
2490 #endif
2491 
2522  NvSciSyncObj syncObj);
2523 
2582  const NvSciSyncFence* syncFence,
2583  NvSciSyncCpuWaitContext context,
2584  int64_t timeoutUs);
2585 
2624  const NvSciSyncFence* syncFence,
2625  uint64_t* timestampUS);
2626 
2661  const NvSciSyncFence* syncFence,
2662  NvSciSyncTaskStatus* taskStatus);
2663 
2664 /*
2665  * NvSciSync Utility functions
2666  */
2667 
2708  NvSciSyncAttrList attrList,
2709  NvSciSyncAttrKey key,
2710  const void** value,
2711  size_t* len);
2712 
2730 #if (NV_IS_SAFETY == 0)
2731 
2737 #else
2738 
2741 #endif
2742 
2757 #if (NV_IS_SAFETY == 0)
2758 
2760 #endif
2761 
2789  const NvSciSyncAttrList inputArray[],
2790  size_t inputCount,
2791  NvSciSyncObj* syncObj,
2792  NvSciSyncAttrList* newConflictList);
2793 
2851  NvSciSyncObj syncObj,
2852  NvSciSyncAccessPerm permissions,
2853  NvSciIpcEndpoint ipcEndpoint,
2854  void** attrListAndObjDesc,
2855  size_t* attrListAndObjDescSize);
2856 
2887  void* attrListAndObjDescBuf);
2888 
2972  NvSciSyncModule module,
2973  NvSciIpcEndpoint ipcEndpoint,
2974  const void* attrListAndObjDesc,
2975  size_t attrListAndObjDescSize,
2976  NvSciSyncAttrList const attrList[],
2977  size_t attrListCount,
2978  NvSciSyncAccessPerm minPermissions,
2979  int64_t timeoutUs,
2980  NvSciSyncObj* syncObj);
2981 
3017 #if (NV_IS_SAFETY == 0)
3018 
3021 #endif
3023  uint32_t majorVer,
3024  uint32_t minorVer,
3025  bool* isCompatible);
3026 
3073  NvSciSyncObj syncObj,
3074  const NvSciSyncAttrList inputArray[],
3075  size_t inputCount);
3076 
3111  NvSciSyncAttrList unrecAttrList,
3112  NvSciSyncAccessPerm permissions);
3113 
3120 #if (NV_IS_SAFETY == 0)
3121 
3132 #else
3133 
3154 #endif
3155 
3173  NvSciSyncAttrList reconciledAttrList,
3174  const NvSciSyncAttrKeyValuePair* pairArray,
3175  size_t pairCount,
3176  NvSciSyncAccessPerm permissions);
3177 
3178 #if defined(__cplusplus)
3179 }
3180 #endif // __cplusplus
3181 
3182 #endif // INCLUDED_NVSCISYNC_H
NvSciSyncFenceClear
void NvSciSyncFenceClear(NvSciSyncFence *syncFence)
Frees any resources allocated for the NvSciSyncFence.
NvSciSyncAttrValPrimitiveType_VidmemSemaphorePayload64b
@ NvSciSyncAttrValPrimitiveType_VidmemSemaphorePayload64b
16 bytes semaphore backed by video memory.
Definition: nvscisync.h:444
NvSciSyncAttrKey_RequireDeterministicFences
@ NvSciSyncAttrKey_RequireDeterministicFences
(bool, inout) Specifies if deterministic primitives are required.
Definition: nvscisync.h:574
NvSciSyncAccessPerm
uint64_t NvSciSyncAccessPerm
Describes NvSciSyncObj access permissions.
Definition: nvscisync.h:330
NvSciSyncObjValidate
NvSciError NvSciSyncObjValidate(NvSciSyncObj syncObj)
Validates the NvSciSyncObj satisfies the constraints of the NvSciSyncAttrList that it is associated w...
NvSciError
NvSciError
Return/error codes for all NvSci functions.
Definition: nvscierror.h:45
NvSciSyncAttrListAndObjFreeDesc
void NvSciSyncAttrListAndObjFreeDesc(void *attrListAndObjDescBuf)
Frees an NvSciSyncIpcExportAttrListAndObj descriptor returned by a successful call to NvSciSyncIpcExp...
NvSciSyncIpcImportFence
NvSciError NvSciSyncIpcImportFence(NvSciSyncObj syncObj, const NvSciSyncFenceIpcExportDescriptor *desc, NvSciSyncFence *syncFence)
Fills in the NvSciSyncFence based on the input binary descriptor.
NvSciSyncAttrKey_NeedCpuAccess
@ NvSciSyncAttrKey_NeedCpuAccess
(bool, inout) Specifies if CPU access is required.
Definition: nvscisync.h:498
NvSciSyncObjIpcExport
NvSciError NvSciSyncObjIpcExport(NvSciSyncObj syncObj, NvSciSyncAccessPerm permissions, NvSciIpcEndpoint ipcEndpoint, NvSciSyncObjIpcExportDescriptor *desc)
Exports an NvSciSyncObj into an NvSciIpc-transferable object binary descriptor.
NvSciSyncObjIpcImport
NvSciError NvSciSyncObjIpcImport(NvSciIpcEndpoint ipcEndpoint, const NvSciSyncObjIpcExportDescriptor *desc, NvSciSyncAttrList inputAttrList, NvSciSyncAccessPerm permissions, int64_t timeoutUs, NvSciSyncObj *syncObj)
Creates and returns an NvSciSyncObj based on the supplied binary descriptor describing an exported Nv...
NvSciSyncAttrListFreeDesc
void NvSciSyncAttrListFreeDesc(void *descBuf)
Frees an exported NvSciSyncAttrList descriptor previously returned by any NvSciSyncAttrList exporting...
NvSciSyncAttrValPrimitiveType_SysmemSemaphore
@ NvSciSyncAttrValPrimitiveType_SysmemSemaphore
16 bytes semaphore backed by system memory.
Definition: nvscisync.h:426
NvSciSyncTaskStatus_Failure
@ NvSciSyncTaskStatus_Failure
The task has failed.
Definition: nvscisync.h:384
NvSciSyncIpcImportAttrListAndObj
NvSciError NvSciSyncIpcImportAttrListAndObj(NvSciSyncModule module, NvSciIpcEndpoint ipcEndpoint, const void *attrListAndObjDesc, size_t attrListAndObjDescSize, NvSciSyncAttrList const attrList[], size_t attrListCount, NvSciSyncAccessPerm minPermissions, int64_t timeoutUs, NvSciSyncObj *syncObj)
Creates an NvSciSyncObj based on the supplied binary descriptor returned from a successful call to Nv...
NvSciSyncAttrValPrimitiveType_Syncpoint
@ NvSciSyncAttrValPrimitiveType_Syncpoint
Syncpoint.
Definition: nvscisync.h:420
NvSciSyncAttrKeyValuePair::len
size_t len
Length of the value in bytes.
Definition: nvscisync.h:669
NvSciSyncTaskStatusVal
NvSciSyncTaskStatusVal
Status of the signaler's task that signals a particular NvSciSyncFence.
Definition: nvscisync.h:380
NvSciSyncFence::payload
uint64_t payload[6]
Definition: nvscisync.h:250
NvSciSyncAttrKey_LowerBound
@ NvSciSyncAttrKey_LowerBound
Specifies the lower bound - for NvSciSync internal use only.
Definition: nvscisync.h:470
NvSciSyncTaskStatus_Invalid
@ NvSciSyncTaskStatus_Invalid
The signaler did not report any task status.
Definition: nvscisync.h:387
NvSciSyncCpuWaitContextFree
void NvSciSyncCpuWaitContextFree(NvSciSyncCpuWaitContext context)
Releases the NvSciSyncCpuWaitContext.
NvSciSyncAttrListSetAttrs
NvSciError NvSciSyncAttrListSetAttrs(NvSciSyncAttrList attrList, const NvSciSyncAttrKeyValuePair *pairArray, size_t pairCount)
Sets the values for NvSciSyncAttrKey(s) in slot 0 of the input NvSciSyncAttrList.
NvSciSyncFenceAddTaskStatusSlot
NvSciError NvSciSyncFenceAddTaskStatusSlot(NvSciSyncFence *syncFence, uint32_t taskStatusSlot)
Sets the current task status slot index to the NvSciSyncFence.
NvSciSyncAttrKeyValuePair::attrKey
NvSciSyncAttrKey attrKey
NvSciSyncAttrKey for which value needs to be set/retrieved.
Definition: nvscisync.h:665
NvSciSyncIpcExportFence
NvSciError NvSciSyncIpcExportFence(const NvSciSyncFence *syncFence, NvSciIpcEndpoint ipcEndpoint, NvSciSyncFenceIpcExportDescriptor *desc)
Exports the input NvSciSyncFence into a binary descriptor shareable across the NvSciIpc channel.
NvSciSyncAttrListIpcImportReconciled
NvSciError NvSciSyncAttrListIpcImportReconciled(NvSciSyncModule module, NvSciIpcEndpoint ipcEndpoint, const void *descBuf, size_t descLen, const NvSciSyncAttrList inputUnreconciledAttrListArray[], size_t inputUnreconciledAttrListCount, NvSciSyncAttrList *importedReconciledAttrList)
Translates an exported reconciled NvSciSyncAttrList descriptor (potentially received from any process...
NvSciSyncMajorVersion
static const uint32_t NvSciSyncMajorVersion
NvSciSync major version number.
Definition: nvscisync.h:177
NvSciSyncAttrKey_PeerHwEngineArray
@ NvSciSyncAttrKey_PeerHwEngineArray
(NvSciBufPeerHwEngine[], inout) An attribute indicating engine information of late peer which are goi...
Definition: nvscisync.h:649
NvSciSyncAttrList
struct NvSciSyncAttrListRec * NvSciSyncAttrList
A container constituting an NvSciSyncAttrList which contains:
Definition: nvscisync.h:323
NvSciSyncAttrValPrimitiveType
enum NvSciSyncAttrValPrimitiveTypeRec NvSciSyncAttrValPrimitiveType
Alias for enum NvSciSyncAttrValPrimitiveTypeRec.
Definition: nvscisync.h:454
NvSciSyncCpuWaitContextAlloc
NvSciError NvSciSyncCpuWaitContextAlloc(NvSciSyncModule module, NvSciSyncCpuWaitContext *newContext)
Allocates a new NvSciSyncCpuWaitContext.
NvSciSyncAttrKey_NumTimestampSlots
@ NvSciSyncAttrKey_NumTimestampSlots
(uint32_t, out) Specifies the total number of slots in the timestamps buffer.
Definition: nvscisync.h:584
NvSciSyncObjFree
void NvSciSyncObjFree(NvSciSyncObj syncObj)
Destroys a valid NvSciSyncObj and frees any resources that were allocated for it.
NvSciSyncAttrKey_WaiterRequireTimestamps
@ NvSciSyncAttrKey_WaiterRequireTimestamps
(bool, inout) Specifies if timestamps are required.
Definition: nvscisync.h:562
NvSciSyncAttrKeyValuePair::value
const void * value
Memory which contains the value corresponding to the key.
Definition: nvscisync.h:667
NvSciSyncAttrKey_MaxPrimitiveValue
@ NvSciSyncAttrKey_MaxPrimitiveValue
(uint64_t, out) Specifies the maximum value of the reconciled primitive.
Definition: nvscisync.h:602
NvSciSyncFenceMaxTimeout
static const int64_t NvSciSyncFenceMaxTimeout
Maximum supported timeout value.
Definition: nvscisync.h:191
NvSciSyncObjGenerateFence
NvSciError NvSciSyncObjGenerateFence(NvSciSyncObj syncObj, NvSciSyncFence *syncFence)
Generates next point on sync timeline of an NvSciSyncObj and fills in the supplied NvSciSyncFence obj...
NvSciSyncAttrListGetAttrs
NvSciError NvSciSyncAttrListGetAttrs(NvSciSyncAttrList attrList, NvSciSyncAttrKeyValuePair *pairArray, size_t pairCount)
Gets the value of NvSciSyncAttrKey from slot 0 of the input NvSciSyncAttrList.
NvSciSyncAttrKey_PeerLocationInfo
@ NvSciSyncAttrKey_PeerLocationInfo
(NvSciBufPeerLocationInfo[], inout) An attribute indicating location information of late peer which a...
Definition: nvscisync.h:631
NvSciSyncAttrListIsReconciled
NvSciError NvSciSyncAttrListIsReconciled(NvSciSyncAttrList attrList, bool *isReconciled)
Checks whether the NvSciSyncAttrList is reconciled.
NvSciSyncFillC2cAttrs
NvSciError NvSciSyncFillC2cAttrs(NvSciSyncAttrList unrecAttrList, NvSciSyncAccessPerm permissions)
Fills appropriate attributes for C2C copy in the input NvSciSyncAttrList.
NvSciSyncAttrKey_PrimitiveInfo
@ NvSciSyncAttrKey_PrimitiveInfo
(NvSciSyncAttrValPrimitiveType[], inout) supported primitive types.
Definition: nvscisync.h:625
NvSciSyncObjAttachPeer
NvSciError NvSciSyncObjAttachPeer(NvSciSyncObj syncObj, const NvSciSyncAttrList inputArray[], size_t inputCount)
Allows remote peer NvSciIpcEndpoint to gain access to already allocated NvSciSyncObj.
NvSciSyncFenceGetTimestamp
NvSciError NvSciSyncFenceGetTimestamp(const NvSciSyncFence *syncFence, uint64_t *timestampUS)
Read the timestamp associated with the NvSciSyncFence.
NvSciSyncObjConst
const struct NvSciSyncObjRec * NvSciSyncObjConst
A reference, that is not modifiable, to a particular Synchronization Object.
Definition: nvscisync.h:310
NvSciSyncModuleClose
void NvSciSyncModuleClose(NvSciSyncModule module)
Closes an instance of the NvSciSyncModule that was obtained through an earlier call to NvSciSyncModul...
NvSciSyncObjIpcExportDescriptor
Defines the exported form of NvSciSyncObj intended to be shared across an NvSciIpc channel.
Definition: nvscisync.h:277
NvSciSyncAttrValPrimitiveType_SysmemSemaphorePayload64b
@ NvSciSyncAttrValPrimitiveType_SysmemSemaphorePayload64b
16 bytes semaphore backed by system memory.
Definition: nvscisync.h:438
nvsciipc.h
NVIDIA Software Communications Interface (SCI) : NvSci Inter-Process Communication
NvSciSyncAttrValPrimitiveType_VidmemSemaphore
@ NvSciSyncAttrValPrimitiveType_VidmemSemaphore
16 bytes semaphore backed by video memory.
Definition: nvscisync.h:432
NvSciSyncAttrListGetAttr
NvSciError NvSciSyncAttrListGetAttr(NvSciSyncAttrList attrList, NvSciSyncAttrKey key, const void **value, size_t *len)
Gets the attribute value from the slot 0 of the passed NvSciSyncAttrList with the given NvSciSyncAttr...
NvSciSyncAttrKey
NvSciSyncAttrKey
Describes the NvSciSync public attribute keys holding the corresponding values specifying synchroniza...
Definition: nvscisync.h:468
NvSciSyncObjAlloc
NvSciError NvSciSyncObjAlloc(NvSciSyncAttrList reconciledList, NvSciSyncObj *syncObj)
Allocates and initializes a NvSciSyncObj that meets all the constraints specified in the given reconc...
NvSciSyncAttrKey_GpuId
@ NvSciSyncAttrKey_GpuId
(NvSciRmGpuId[], inout) GpuID of the GPU in the system that will access the semaphore buffer.
Definition: nvscisync.h:643
NvSciIpcEndpoint
uint64_t NvSciIpcEndpoint
Handle to the NvSciIpc endpoint.
Definition: nvsciipc.h:322
NvSciSyncObjDup
NvSciError NvSciSyncObjDup(NvSciSyncObj syncObj, NvSciSyncObj *dupObj)
Creates a new NvSciSyncObj holding a reference to the original resources to which the input NvSciSync...
NvSciSyncCheckVersionCompatibility
NvSciError NvSciSyncCheckVersionCompatibility(uint32_t majorVer, uint32_t minorVer, bool *isCompatible)
Checks if the loaded library version is compatible with the version the application was compiled agai...
NvSciSyncAttrListIpcExportUnreconciled
NvSciError NvSciSyncAttrListIpcExportUnreconciled(const NvSciSyncAttrList unreconciledAttrListArray[], size_t unreconciledAttrListCount, NvSciIpcEndpoint ipcEndpoint, void **descBuf, size_t *descLen)
Transforms the input unreconciled NvSciSyncAttrList(s) to an exportable unreconciled NvSciSyncAttrLis...
NvSciSyncAttrKeyValuePair
This structure defines a key/value pair used to get or set the NvSciSyncAttrKey(s) and their correspo...
Definition: nvscisync.h:661
NvSciSyncFenceExtractFence
NvSciError NvSciSyncFenceExtractFence(const NvSciSyncFence *syncFence, uint64_t *id, uint64_t *value)
Extracts the id and value from the input NvSciSyncFence.
NvSciSyncAttrKey_RequiredPerm
@ NvSciSyncAttrKey_RequiredPerm
(NvSciSyncAccessPerm, inout) Specifies the required access permissions.
Definition: nvscisync.h:506
NvSciSyncAttrValPrimitiveTypeRec
NvSciSyncAttrValPrimitiveTypeRec
Types of synchronization primitives.
Definition: nvscisync.h:413
NvSciSyncAttrListIpcImportUnreconciled
NvSciError NvSciSyncAttrListIpcImportUnreconciled(NvSciSyncModule module, NvSciIpcEndpoint ipcEndpoint, const void *descBuf, size_t descLen, NvSciSyncAttrList *importedUnreconciledAttrList)
Transforms an exported unreconciled NvSciSyncAttrList descriptor (potentially received from any proce...
NvSciSyncMinorVersion
static const uint32_t NvSciSyncMinorVersion
NvSciSync minor version number.
Definition: nvscisync.h:184
NvSciSyncObjSignal
NvSciError NvSciSyncObjSignal(NvSciSyncObj syncObj)
Signals the NvSciSyncObj using the reconciled primitive that was allocated along with the NvSciSyncOb...
NvSciSyncFenceAddTimestampSlot
NvSciError NvSciSyncFenceAddTimestampSlot(NvSciSyncFence *syncFence, uint32_t timestampSlot)
Sets the current timestamp slot index in the NvSciSyncFence.
NvSciSyncAttrValPrimitiveType_LowerBound
@ NvSciSyncAttrValPrimitiveType_LowerBound
For NvSciSync internal use only.
Definition: nvscisync.h:415
NvSciSyncAttrListReconcile
NvSciError NvSciSyncAttrListReconcile(const NvSciSyncAttrList inputArray[], size_t inputCount, NvSciSyncAttrList *newReconciledList, NvSciSyncAttrList *newConflictList)
Reconciles the input unreconciled NvSciSyncAttrLists into a new reconciled NvSciSyncAttrList.
NvSciSyncFenceWait
NvSciError NvSciSyncFenceWait(const NvSciSyncFence *syncFence, NvSciSyncCpuWaitContext context, int64_t timeoutUs)
Performs a synchronous wait on the NvSciSyncFence object until the NvSciSyncFence has been signaled o...
NvSciSyncModuleOpen
NvSciError NvSciSyncModuleOpen(NvSciSyncModule *newModule)
Initializes and returns a new NvSciSyncModule with no NvSciSyncAttrLists, NvSciSyncCpuWaitContexts,...
NvSciSyncAttrListReconcileAndObjAlloc
NvSciError NvSciSyncAttrListReconcileAndObjAlloc(const NvSciSyncAttrList inputArray[], size_t inputCount, NvSciSyncObj *syncObj, NvSciSyncAttrList *newConflictList)
Reconciles the input unreconciled NvSciSyncAttrList(s) into a new reconciled NvSciSyncAttrList.
NvSciSyncAttrListDebugDump
NvSciError NvSciSyncAttrListDebugDump(NvSciSyncAttrList attrList, void **buf, size_t *len)
Dumps the NvSciSyncAttrList into a binary descriptor.
NvSciSyncFence
struct NvSciSyncFence NvSciSyncFence
Defines the opaque NvSciSyncFence.
NvSciSyncFence
Defines the opaque NvSciSyncFence.
Definition: nvscisync.h:249
NvSciSyncAttrListValidateReconciledAgainstAttrs
NvSciError NvSciSyncAttrListValidateReconciledAgainstAttrs(NvSciSyncAttrList reconciledAttrList, const NvSciSyncAttrKeyValuePair *pairArray, size_t pairCount, NvSciSyncAccessPerm permissions)
Validates reconciledAttrList against the set of input attributes that the user has set in the unrecon...
NvSciSyncObjGetAttrList
NvSciError NvSciSyncObjGetAttrList(NvSciSyncObj syncObj, NvSciSyncAttrList *syncAttrList)
Retrieves the reconciled NvSciSyncAttrList associated with an input NvSciSyncObj.
nvscibuf.h
NVIDIA Software Communications Interface (SCI) : NvSciBuf
NvSciSyncFenceGetTaskStatus
NvSciError NvSciSyncFenceGetTaskStatus(const NvSciSyncFence *syncFence, NvSciSyncTaskStatus *taskStatus)
Reads the task status associated with the NvSciSyncFence and stores it in the user provided out param...
NvSciSyncAttrListValidateReconciled
NvSciError NvSciSyncAttrListValidateReconciled(NvSciSyncAttrList reconciledAttrList, const NvSciSyncAttrList inputUnreconciledAttrListArray[], size_t inputUnreconciledAttrListCount, bool *isReconciledListValid)
Validates a reconciled NvSciSyncAttrList against a set of input unreconciled NvSciSyncAttrLists.
NvSciSyncAttrKey_NumTaskStatusSlots
@ NvSciSyncAttrKey_NumTaskStatusSlots
(uint32_t, out) Specifies the total number of slots in the task status buffer.
Definition: nvscisync.h:594
NvSciSyncAttrKey_ActualPerm
@ NvSciSyncAttrKey_ActualPerm
(NvSciSyncAccessPerm, out) Actual permission granted after reconciliation.
Definition: nvscisync.h:537
NvSciSyncFenceExtractTimestampSlot
NvSciError NvSciSyncFenceExtractTimestampSlot(NvSciSyncFence *syncFence, uint32_t *timeStampSlot)
Reads the current timestamp slot index from the NvSciSyncFence.
NvSciSyncAttrValPrimitiveType_UpperBound
@ NvSciSyncAttrValPrimitiveType_UpperBound
For NvSciSync internal use only.
Definition: nvscisync.h:446
NvSciSyncAttrListSlotGetAttrs
NvSciError NvSciSyncAttrListSlotGetAttrs(NvSciSyncAttrList attrList, size_t slotIndex, NvSciSyncAttrKeyValuePair *pairArray, size_t pairCount)
Gets the value(s) of NvSciSyncAttrKey(s) from an NvSciSyncAttrList at given slot index in a multi-slo...
NvSciSyncAttrListFree
void NvSciSyncAttrListFree(NvSciSyncAttrList attrList)
Frees the NvSciSyncAttrList and removes its association with the NvSciSyncModule with which it was cr...
NvSciSyncAttrListGetSlotCount
size_t NvSciSyncAttrListGetSlotCount(NvSciSyncAttrList attrList)
Gets the slot count of the given NvSciSyncAttrList.
NvSciSyncModule
struct NvSciSyncModuleRec * NvSciSyncModule
Represents an instance of the NvSciSyncModule.
Definition: nvscisync.h:204
NvSciSyncFenceUpdateFence
NvSciError NvSciSyncFenceUpdateFence(NvSciSyncObj syncObj, uint64_t id, uint64_t value, NvSciSyncFence *syncFence)
Populates the input NvSciSyncFence based on the input id and value.
nvscierror.h
NvSciSyncAttrKey_UpperBound
@ NvSciSyncAttrKey_UpperBound
Specifies the upper bound - for NvSciSync internal use only.
Definition: nvscisync.h:651
NvSciSyncFenceInitializer
static const NvSciSyncFence NvSciSyncFenceInitializer
Defines the value used to zero-initialize the NvSciSyncFence object.
Definition: nvscisync.h:259
NvSciSyncObj
struct NvSciSyncObjRec * NvSciSyncObj
A Synchronization Object is a container holding the reconciled NvSciSyncAttrList defining constraints...
Definition: nvscisync.h:304
NvSciSyncAttrListCreate
NvSciError NvSciSyncAttrListCreate(NvSciSyncModule module, NvSciSyncAttrList *attrList)
Creates a new, single-slot unreconciled NvSciSyncAttrList associated with the input NvSciSyncModule w...
PACK_SYNC
#define PACK_SYNC(__Declaration__,...)
Definition: nvscisync.h:169
NvSciSyncAttrListAppendUnreconciled
NvSciError NvSciSyncAttrListAppendUnreconciled(const NvSciSyncAttrList inputUnreconciledAttrListArray[], size_t inputUnreconciledAttrListCount, NvSciSyncAttrList *newUnreconciledAttrList)
Appends multiple unreconciled NvSciSyncAttrLists together, forming a single new unreconciled NvSciSyn...
NvSciSyncAttrListIpcExportReconciled
NvSciError NvSciSyncAttrListIpcExportReconciled(const NvSciSyncAttrList reconciledAttrList, NvSciIpcEndpoint ipcEndpoint, void **descBuf, size_t *descLen)
Transforms the reconciled NvSciSyncAttrList to an exportable reconciled NvSciSyncAttrList descriptor ...
NvSciSyncFenceIpcExportDescriptor
Defines the exported form of NvSciSyncFence intended to be shared across an NvSciIpc channel.
Definition: nvscisync.h:267
NvSciSyncIpcExportAttrListAndObj
NvSciError NvSciSyncIpcExportAttrListAndObj(NvSciSyncObj syncObj, NvSciSyncAccessPerm permissions, NvSciIpcEndpoint ipcEndpoint, void **attrListAndObjDesc, size_t *attrListAndObjDescSize)
Exports an NvSciSyncAttrList and NvSciSyncObj into an NvSciIpc-transferable object binary descriptor ...
NvSciSyncTaskStatus_Success
@ NvSciSyncTaskStatus_Success
The task has completed successfully.
Definition: nvscisync.h:382
NvSciSyncAttrListClone
NvSciError NvSciSyncAttrListClone(NvSciSyncAttrList origAttrList, NvSciSyncAttrList *newAttrList)
Clones an NvSciSyncAttrList.
NvSciSyncAttrKey_WaiterContextInsensitiveFenceExports
@ NvSciSyncAttrKey_WaiterContextInsensitiveFenceExports
(bool, inout) Importing and then exporting an NvSciSyncFenceIpcExportDescriptor has no side effects a...
Definition: nvscisync.h:556
NvSciSyncCpuWaitContext
struct NvSciSyncCpuWaitContextRec * NvSciSyncCpuWaitContext
Represents the right to perform a CPU wait on an NvSciSyncFence.
Definition: nvscisync.h:216
NvSciSyncFenceDup
NvSciError NvSciSyncFenceDup(const NvSciSyncFence *srcSyncFence, NvSciSyncFence *dstSyncFence)
Duplicates the given NvSciSyncFence, such that any wait on duplicated NvSciSyncFence will complete at...