NVIDIA DriveOS Linux SDK API Reference

7.2.5.0 Early Access Release
nvrm_host1x.h File Reference

Go to the source code of this file.

Data Structures

struct  NvRmTimevalRec
 A structure for storing an accurate time. More...
 
struct  NvRmEngineStatusRec
 Structure that is filled by either kernel-mode-driver or engine to denote the status. More...
 

Macros

#define NVRM_MUTEX_INVALID   ((NvU32)-1)
 Invalid Module Mutex ID. More...
 

Typedefs

typedef struct NvRmChannelRec * NvRmChannelHandle
 A type-safe handle for a channel. More...
 
typedef struct NvRmContextRec * NvRmContextHandle
 A type-safe handle for a hardware context, for the engines where such a concept is applicable. More...
 
typedef struct NvRmTimevalRec NvRmTimeval
 A structure for storing an accurate time. More...
 
typedef struct NvRmEngineStatusRec NvRmEngineStatus
 Structure that is filled by either kernel-mode-driver or engine to denote the status. More...
 

Enumerations

enum  NvRmClockId {
  NvRmClockId_Unknown = 0,
  NvRmClockId_Monotonic,
  NvRmClockId_PTP
}
 Clock used to retrieve the timestamp. More...
 

Functions

NvError NvRmChannelOpenDeviceFile (NvRmDeviceHandle hDevice, NvRmChannelHandle *phChannel, const char *node)
 Opens a handle to a channel using given channel device node. More...
 
NvError NvRmChannelOpen (NvRmDeviceHandle hDevice, NvRmChannelHandle *phChannel, NvU32 NumModules, const NvRmModuleID *pModuleIDs)
 Opens a handle to a channel. More...
 
void NvRmChannelClose (NvRmChannelHandle hChannel)
 Closes a channel handle from NvRmChannelOpen() or NvRmChannelAlloc(). More...
 
NvError NvRmChannelSetErrNotifier (NvRmChannelHandle phChannel, NvU64 errLimit, NvU32 errOffset, NvU32 errMemHandle)
 Sets error notifier for a channel. More...
 
void NvRmChannelSyncPointFree (NvRmDeviceHandle hDevice, NvU32 SyncPointID)
 Do nothing. More...
 
NvError NvRmChannelGetModuleSyncPoint (NvRmChannelHandle hChannel, NvRmModuleID Module, NvU32 Index, NvU32 *pSyncPointID)
 Obtains the index of a dynamically allocated host managed sync point register for a particular <channel, module> pair. More...
 
NvError NvRmChannelGetClientManagedSyncPoint (NvRmChannelHandle hChannel, const char *name, NvU32 SyncPointIndex, NvU32 *pSyncPointID)
 Obtains the index of a dynamically allocated client managed sync point register for a particular module. More...
 
void NvRmChannelFreeClientManagedSyncPoint (NvRmChannelHandle hChannel, NvU32 SyncPointIndex, NvU32 pSyncPointID)
 Frees the dynamically allocated syncpt id. More...
 
NvU32 NvRmChannelSyncPointRead (NvRmDeviceHandle hDevice, NvU32 SyncPointID)
 Reads the current value of a particular sync point register. More...
 
void NvRmChannelSyncPointIncr (NvRmDeviceHandle hDevice, NvU32 SyncPointID)
 Increments (using the CPU) a particular sync point register. More...
 
void NvRmChannelSyncPointWait (NvRmDeviceHandle hDevice, NvU32 SyncPointID, NvU32 Threshold, NvOsSemaphoreHandle hSema)
 Waits for a sync point to reach the given threshold. More...
 
NvError NvRmFenceWait (NvRmDeviceHandle hDevice, const NvRmFence *Fence, NvU32 Timeout)
 Waits for a fence to be triggered. More...
 
NvError NvRmFencePutToFile (const char *Name, const NvRmFence *Fences, NvU32 NumFences, NvS32 *Fd)
 Creates an Android fence file from fences. More...
 
NvError NvRmFenceGetFromFile (NvS32 Fd, NvRmFence *Fences, NvU32 *NumFences)
 Extracts fences from an Android fence file. More...
 
NvError NvRmChannelSyncPointWaitTimeout (NvRmDeviceHandle hDevice, NvU32 SyncPointID, NvU32 Threshold, NvOsSemaphoreHandle hSema, NvU32 Timeout)
 Same as NvRmChannelSyncPointWait, but provides a semaphore timeout value. More...
 
NvError NvRmChannelSyncPointWaitexTimeout (NvRmDeviceHandle hDevice, NvU32 SyncPointID, NvU32 Threshold, NvOsSemaphoreHandle hSema, NvU32 Timeout, NvU32 *Actual)
 Same as NvRmChannelSyncPointWaitTimeout, but provides a pointer to memory allocated to hold the actual latest sync point. More...
 
NvError NvRmChannelSyncPointWaitmexTimeout (NvRmDeviceHandle hDevice, NvU32 SyncPointID, NvU32 Threshold, NvOsSemaphoreHandle hSema, NvU32 Timeout, NvU32 *Actual, NvRmTimeval *tv)
 Same as NvRmChannelSyncPointWaitTimeoutex, but provides information about the exact time of work completion. More...
 
NvError NvRmChannelGetModuleClockRate (NvRmChannelHandle hChannel, NvRmModuleID Module, NvU32 *Rate)
 Gets clock rate for the module. More...
 
NvError NvRmChannelSetModuleClockRate (NvRmChannelHandle hChannel, NvRmModuleID Module, NvU32 Rate)
 Sets module clock rate. More...
 
NvError NvRmChannelSetModuleBandwidth (NvRmChannelHandle hChannel, NvRmModuleID Module, NvU32 BW)
 Sets module bw rate. More...
 
NvError NvRmChannelSetModulePixelRate (NvRmChannelHandle hChannel, NvRmModuleID Module, NvU32 PixelRate)
 Set Module pixel rate. More...
 
NvError NvRmChannelSetSubmitTimeoutEx (NvRmChannelHandle hChannel, NvU32 SubmitTimeout, NvBool DisableDebugDump)
 Sets a submit buffer timeout for this stream/context. More...
 
NvError NvRmChannelSetSubmitTimeout (NvRmChannelHandle hChannel, NvU32 SubmitTimeout)
 Sets a submit buffer timeout for this stream/context. More...
 
NvError NvRmChannelRegRd (NvRmDeviceHandle device, NvRmChannelHandle ch, NvRmModuleID id, NvU32 num, const NvU32 *offsets, NvU32 *values)
 Read register values from the given module's channel using channel handle Can only be used for modules behind host. More...
 
NvError NvRmChannelRegWr (NvRmDeviceHandle device, NvRmChannelHandle ch, NvRmModuleID id, NvU32 num, const NvU32 *offset, const NvU32 *values)
 Write register values to the module's channel using channel handle Can only be used for modules behind host. More...
 
NvError NvRmChannelBlockRegRd (NvRmDeviceHandle device, NvRmChannelHandle ch, NvRmModuleID id, NvU32 num, NvU32 offset, NvU32 *values)
 Read a block of consecutive register values to the module's channel using channel handle Can only be used for modules behind host. More...
 
NvError NvRmChannelBlockRegWr (NvRmDeviceHandle device, NvRmChannelHandle ch, NvRmModuleID id, NvU32 num, NvU32 offset, NvU32 *values)
 Write a block of consecutive register values from the given module's channel using using channel handle Can only be used for modules behind host. More...
 
NvError NvRmHostCreateEventPollFd (NvRmDeviceHandle device, int *fd)
 Get poll'able file descriptor (FD) User is responsible for closing the FD. More...
 
NvError NvRmHostTriggerEventPollFd (NvRmDeviceHandle device, int fd, NvU32 syncpointID, NvU32 threshold)
 Trigger an event on poll'able FD which is allocated with NvRmHostCreateEventPollFd() More...
 
NvError NvRmHost1xChannelGetModuleClockRate (NvRmHost1xChannelHandle channel, NvRmModuleID moduleId, NvU32 *rate)
 Gets clock rate for the module. More...
 
NvError NvRmHost1xChannelSetModuleClockRate (NvRmHost1xChannelHandle channel, NvRmModuleID moduleId, NvU32 rate)
 Sets module clock rate. More...
 
NvError NvRmHost1xChannelSetModulePixelRate (NvRmHost1xChannelHandle channel, NvRmModuleID moduleId, NvU32 pixelRate)
 Set Module pixel rate. More...
 
NvError NvRmHost1xChannelSetModuleBandwidth (NvRmHost1xChannelHandle channel, NvRmModuleID moduleId, NvU32 bandwidth)
 Sets module bw rate. More...
 
static NV_INLINE NvBool NvSchedValueIsBetween (const NvU32 a, const NvU32 b, const NvU32 c)
 
static NV_INLINE NvBool NvSchedValueWrappingComparison (const NvU32 x, const NvU32 y)
 

Macro Definition Documentation

◆ NVRM_MUTEX_INVALID

#define NVRM_MUTEX_INVALID   ((NvU32)-1)

Invalid Module Mutex ID.

Definition at line 79 of file nvrm_host1x.h.

Typedef Documentation

◆ NvRmChannelHandle

typedef struct NvRmChannelRec* NvRmChannelHandle

A type-safe handle for a channel.

Definition at line 29 of file nvrm_host1x.h.

◆ NvRmContextHandle

typedef struct NvRmContextRec* NvRmContextHandle

A type-safe handle for a hardware context, for the engines where such a concept is applicable.

Definition at line 35 of file nvrm_host1x.h.

◆ NvRmEngineStatus

Structure that is filled by either kernel-mode-driver or engine to denote the status.

◆ NvRmTimeval

typedef struct NvRmTimevalRec NvRmTimeval

A structure for storing an accurate time.

Enumeration Type Documentation

◆ NvRmClockId

Clock used to retrieve the timestamp.

Enumerator
NvRmClockId_Unknown 
NvRmClockId_Monotonic 
NvRmClockId_PTP 

Definition at line 40 of file nvrm_host1x.h.

Function Documentation

◆ NvRmChannelBlockRegRd()

NvError NvRmChannelBlockRegRd ( NvRmDeviceHandle  device,
NvRmChannelHandle  ch,
NvRmModuleID  id,
NvU32  num,
NvU32  offset,
NvU32 *  values 
)

Read a block of consecutive register values to the module's channel using channel handle Can only be used for modules behind host.

Parameters
deviceThe RM instance
chThe channel handle
idThe module id to write to
numNumber of registers to write
offsetOffset the first register to write
valuesValues read into the registers

See the comment above regarding byte addressing.

◆ NvRmChannelBlockRegWr()

NvError NvRmChannelBlockRegWr ( NvRmDeviceHandle  device,
NvRmChannelHandle  ch,
NvRmModuleID  id,
NvU32  num,
NvU32  offset,
NvU32 *  values 
)

Write a block of consecutive register values from the given module's channel using using channel handle Can only be used for modules behind host.

Parameters
deviceThe RM instance
chThe channel handle
idThe module id to read from
numNumber of registers to read
offsetOffset of the first register to read
valuesStorage for the register values

The offset is a byte address, not a word address. Some of the hardware specs have word addresses, so the offsets need to be mutlipled by 4.

◆ NvRmChannelClose()

void NvRmChannelClose ( NvRmChannelHandle  hChannel)

Closes a channel handle from NvRmChannelOpen() or NvRmChannelAlloc().

This API will never fail.

Parameters
hChannelThe channel handle to close. If hChannel is NULL, this API will do nothing.

◆ NvRmChannelFreeClientManagedSyncPoint()

void NvRmChannelFreeClientManagedSyncPoint ( NvRmChannelHandle  hChannel,
NvU32  SyncPointIndex,
NvU32  pSyncPointID 
)

Frees the dynamically allocated syncpt id.

Parameters
SyncPointIndexIndex for the module.
pSyncPointIDThe sync point id, which needs to be freed.

◆ NvRmChannelGetClientManagedSyncPoint()

NvError NvRmChannelGetClientManagedSyncPoint ( NvRmChannelHandle  hChannel,
const char *  name,
NvU32  SyncPointIndex,
NvU32 *  pSyncPointID 
)

Obtains the index of a dynamically allocated client managed sync point register for a particular module.

It is not allowed to set priority on a channel or stream which has (or will have) retrieved syncpoint IDs via this call.

Parameters
nameThe name to be given to syncpt for debugging purpose
SyncPointIndexIndex for the module.
pSyncPointIDThe sync point, if a free sync point is found for the given module, otherwise an error is returned.

◆ NvRmChannelGetModuleClockRate()

NvError NvRmChannelGetModuleClockRate ( NvRmChannelHandle  hChannel,
NvRmModuleID  Module,
NvU32 *  Rate 
)

Gets clock rate for the module.

Parameters
hChannelHandle to the channel
ModuleModule Id for which get the clock rate
RatePointer to be filled with the rate read from kernel

◆ NvRmChannelGetModuleSyncPoint()

NvError NvRmChannelGetModuleSyncPoint ( NvRmChannelHandle  hChannel,
NvRmModuleID  Module,
NvU32  Index,
NvU32 *  pSyncPointID 
)

Obtains the index of a dynamically allocated host managed sync point register for a particular <channel, module> pair.

It is not allowed to set priority on a channel or stream which has (or will have) retrieved syncpoint IDs via this call.

Parameters
hChannelChannel handle obtained from NvRmChannelOpen().
ModuleModule that we need the preallocated sync point for.
IndexIndex for the module.
pSyncPointIDThe sync point, if a free sync point is found for the given module, otherwise an error is returned.

◆ NvRmChannelOpen()

NvError NvRmChannelOpen ( NvRmDeviceHandle  hDevice,
NvRmChannelHandle *  phChannel,
NvU32  NumModules,
const NvRmModuleID *  pModuleIDs 
)

Opens a handle to a channel.

Most likely, you will be sharing this channel with many other clients.

To decide what channel you get, RM needs to know what modules you plan to use. It is very important to fill out this information correctly, because only a subset of [channel, module] pairs may have sync points associated with them. If you fail to declare that you are going to use a module, your NvRmStreamFlush() calls may fail. XXX In the future, this should be updated to say "your NvRmStreamInit call", once NvRmStreamInit takes an engine argument.

Parameters
hDeviceHandle to device the channel is for.
phChannelPointer to to be filled in with the channel handle.
NumModulesNumber of modules in the pModuleIDs array. Currently zero is allowed, but please fix your code to not rely on this.
pModuleIDsList of modules you are planning on using. Currently NULL is allowed, but please fix your code to not rely on this.

◆ NvRmChannelOpenDeviceFile()

NvError NvRmChannelOpenDeviceFile ( NvRmDeviceHandle  hDevice,
NvRmChannelHandle *  phChannel,
const char *  node 
)

Opens a handle to a channel using given channel device node.

Most likely, you will be sharing this channel with many other clients.

To decide what channel you get, RM needs to know what modules you plan to use. It is very important to fill out this information correctly, because only a subset of [channel, module] pairs may have sync points associated with them. If you fail to declare that you are going to use a module, your NvRmStreamFlush() calls may fail. XXX In the future, this should be updated to say "your NvRmStreamInit call", once NvRmStreamInit takes an engine argument.

Parameters
hDeviceHandle to device the channel is for.
phChannelPointer to to be filled in with the channel handle.
nodeDevice file name

◆ NvRmChannelRegRd()

NvError NvRmChannelRegRd ( NvRmDeviceHandle  device,
NvRmChannelHandle  ch,
NvRmModuleID  id,
NvU32  num,
const NvU32 *  offsets,
NvU32 *  values 
)

Read register values from the given module's channel using channel handle Can only be used for modules behind host.

Parameters
deviceThe RM instance
chThe channel handle
idThe module id to read from
numNumber of registers to read
offsetsOffset list of the registers to read
valuesStorage for the register values

The offset is a byte address, not a word address. Some of the hardware specs have word addresses, so the offsets need to be mutlipled by 4.

◆ NvRmChannelRegWr()

NvError NvRmChannelRegWr ( NvRmDeviceHandle  device,
NvRmChannelHandle  ch,
NvRmModuleID  id,
NvU32  num,
const NvU32 *  offset,
const NvU32 *  values 
)

Write register values to the module's channel using channel handle Can only be used for modules behind host.

Parameters
deviceThe RM instance
chThe channel handle
idThe module id to write to
numNumber of registers to write
offsetsOffset list of the registers to write
valuesValues to write into the registers

See the comment above regarding byte addressing.

◆ NvRmChannelSetErrNotifier()

NvError NvRmChannelSetErrNotifier ( NvRmChannelHandle  phChannel,
NvU64  errLimit,
NvU32  errOffset,
NvU32  errMemHandle 
)

Sets error notifier for a channel.

Parameters
phChannelThe channel handle to set error notifiers.
errLimitLimit for error notifiers.
errOffsetOffset to set in error notifiers.
errMemHandlememory handle in set error notifiers.

◆ NvRmChannelSetModuleBandwidth()

NvError NvRmChannelSetModuleBandwidth ( NvRmChannelHandle  hChannel,
NvRmModuleID  Module,
NvU32  BW 
)

Sets module bw rate.

Parameters
hChannelHandle to the channel
ModuleModule Id for which set the clock rate
Bandwidthto set, unit is KBps

◆ NvRmChannelSetModuleClockRate()

NvError NvRmChannelSetModuleClockRate ( NvRmChannelHandle  hChannel,
NvRmModuleID  Module,
NvU32  Rate 
)

Sets module clock rate.

Parameters
hChannelHandle to the channel
ModuleModule Id for which set the clock rate
RateClock rate to set

◆ NvRmChannelSetModulePixelRate()

NvError NvRmChannelSetModulePixelRate ( NvRmChannelHandle  hChannel,
NvRmModuleID  Module,
NvU32  PixelRate 
)

Set Module pixel rate.

Parameters
hChannelHandle to the channel
Moduleid for which to add Bandwidth
PixelRate(pixels/second)

◆ NvRmChannelSetSubmitTimeout()

NvError NvRmChannelSetSubmitTimeout ( NvRmChannelHandle  hChannel,
NvU32  SubmitTimeout 
)

Sets a submit buffer timeout for this stream/context.

Parameters
hChannelHandle to the channel for NvRmStream submits
SubmitTimeoutTime, in milliseconds, a buffer is allowed to run

◆ NvRmChannelSetSubmitTimeoutEx()

NvError NvRmChannelSetSubmitTimeoutEx ( NvRmChannelHandle  hChannel,
NvU32  SubmitTimeout,
NvBool  DisableDebugDump 
)

Sets a submit buffer timeout for this stream/context.

Parameters
hChannelHandle to the channel for NvRmStream submits
SubmitTimeoutTime, in milliseconds, a buffer is allowed to run
DisableDebugDumpThis flag allows disabling the timeout debug dump

◆ NvRmChannelSyncPointFree()

void NvRmChannelSyncPointFree ( NvRmDeviceHandle  hDevice,
NvU32  SyncPointID 
)

Do nothing.

Parameters
hDeviceIgnored.
SyncPointIDIgnored.
Deprecated:
This API is only left here since some users are incorrectly calling it.

◆ NvRmChannelSyncPointIncr()

void NvRmChannelSyncPointIncr ( NvRmDeviceHandle  hDevice,
NvU32  SyncPointID 
)

Increments (using the CPU) a particular sync point register.

This API will never fail.

Parameters
hDeviceHandle to RM device.
SyncPointIDThe ID of the syncpoint to increment.
Deprecated:
This function is inherently unsafe, as it allows to increment any syncpoint without permission checks.

◆ NvRmChannelSyncPointRead()

NvU32 NvRmChannelSyncPointRead ( NvRmDeviceHandle  hDevice,
NvU32  SyncPointID 
)

Reads the current value of a particular sync point register.

Do not use this API to poll for completion. Use NvRmChannelSyncPointWait() instead.

Parameters
hDeviceHandle to RM device.
SyncPointIDThe ID of the sync point register to read.

◆ NvRmChannelSyncPointWait()

void NvRmChannelSyncPointWait ( NvRmDeviceHandle  hDevice,
NvU32  SyncPointID,
NvU32  Threshold,
NvOsSemaphoreHandle  hSema 
)

Waits for a sync point to reach the given threshold.

Will block on the given semaphore if the sync point has not reached the threashold. This handles clocking of the hardware and will short circuit the semaphore wait/signal if possible.

Parameters
hDeviceAn RM device handle.
SyncPointIDWhich sync point register to wait on.
ThresholdThe value to wait for the sync point register to obtain.
hSemaThe OS semaphore to be signaled when the threshold is attained.

◆ NvRmChannelSyncPointWaitexTimeout()

NvError NvRmChannelSyncPointWaitexTimeout ( NvRmDeviceHandle  hDevice,
NvU32  SyncPointID,
NvU32  Threshold,
NvOsSemaphoreHandle  hSema,
NvU32  Timeout,
NvU32 *  Actual 
)

Same as NvRmChannelSyncPointWaitTimeout, but provides a pointer to memory allocated to hold the actual latest sync point.

NvError_Timeout will be returned if the sync point isn't signaled by the given timeout.

Parameters
hDeviceAn RM device handle.
SyncPointIDWhich sync point register to wait on.
ThresholdThe value to wait for the sync point register to obtain.
hSemaThe OS semaphore to be signaled when the threshold is attained.
TimeoutThe timeout value, in milliseconds, for the semaphore. Use NV_WAIT_INFINITE to wait infinitely.

◆ NvRmChannelSyncPointWaitmexTimeout()

NvError NvRmChannelSyncPointWaitmexTimeout ( NvRmDeviceHandle  hDevice,
NvU32  SyncPointID,
NvU32  Threshold,
NvOsSemaphoreHandle  hSema,
NvU32  Timeout,
NvU32 *  Actual,
NvRmTimeval *  tv 
)

Same as NvRmChannelSyncPointWaitTimeoutex, but provides information about the exact time of work completion.

NvError_Timeout will be returned if the sync point isn't signaled by the given timeout.

Parameters
hDeviceAn RM device handle.
SyncPointIDWhich sync point register to wait on.
ThresholdThe value to wait for the sync point register to obtain.
hSemaThe OS semaphore to be signaled when the threshold is attained.
TimeoutThe timeout value, in milliseconds, for the semaphore. Use NV_WAIT_INFINITE to wait infinitely.

◆ NvRmChannelSyncPointWaitTimeout()

NvError NvRmChannelSyncPointWaitTimeout ( NvRmDeviceHandle  hDevice,
NvU32  SyncPointID,
NvU32  Threshold,
NvOsSemaphoreHandle  hSema,
NvU32  Timeout 
)

Same as NvRmChannelSyncPointWait, but provides a semaphore timeout value.

NvError_Timeout will be returned if the sync point isn't signaled by the given timeout.

Parameters
hDeviceAn RM device handle.
SyncPointIDWhich sync point register to wait on.
ThresholdThe value to wait for the sync point register to obtain.
hSemaThe OS semaphore to be signaled when the threshold is attained.
TimeoutThe timeout value, in milliseconds, for the semaphore. Use NV_WAIT_INFINITE to wait infinitely.

◆ NvRmFenceGetFromFile()

NvError NvRmFenceGetFromFile ( NvS32  Fd,
NvRmFence *  Fences,
NvU32 *  NumFences 
)

Extracts fences from an Android fence file.

Parameters
FdThe file descriptor of the fence file.
FencesPointer to a fence buffer that stores the fences. Pass NULL to only extract the number of fences in the file.
NumFencesThe number of fences that can be written into the Fences array. Is updated with the number of actually written.

◆ NvRmFencePutToFile()

NvError NvRmFencePutToFile ( const char *  Name,
const NvRmFence *  Fences,
NvU32  NumFences,
NvS32 *  Fd 
)

Creates an Android fence file from fences.

Parameters
NameName of the fence file (optional, NULL is fine).
FencesFences to put into the file.
NumFencesThe number of fences in the Fences array.
FdThe file descriptor of the created fence file.

◆ NvRmFenceWait()

NvError NvRmFenceWait ( NvRmDeviceHandle  hDevice,
const NvRmFence *  Fence,
NvU32  Timeout 
)

Waits for a fence to be triggered.

Parameters
hDeviceAn RM device handle.
FenceFence to wait on
hSemaThe OS semaphore to be signaled when the threshold is attained.

◆ NvRmHost1xChannelGetModuleClockRate()

NvError NvRmHost1xChannelGetModuleClockRate ( NvRmHost1xChannelHandle  channel,
NvRmModuleID  moduleId,
NvU32 *  rate 
)

Gets clock rate for the module.

Parameters
channelHandle of the opened channel
moduleIdModule Id for which get the clock rate
ratePointer to be filled with the rate read from kernel

◆ NvRmHost1xChannelSetModuleBandwidth()

NvError NvRmHost1xChannelSetModuleBandwidth ( NvRmHost1xChannelHandle  channel,
NvRmModuleID  moduleId,
NvU32  bandwidth 
)

Sets module bw rate.

Parameters
hChannelHandle to the channel
ModuleModule Id for which set the clock rate
Bandwidthto set, unit is KBps

◆ NvRmHost1xChannelSetModuleClockRate()

NvError NvRmHost1xChannelSetModuleClockRate ( NvRmHost1xChannelHandle  channel,
NvRmModuleID  moduleId,
NvU32  rate 
)

Sets module clock rate.

Parameters
channelHandle to the channel
moduleIdModule Id for which set the clock rate
rateClock rate to set

◆ NvRmHost1xChannelSetModulePixelRate()

NvError NvRmHost1xChannelSetModulePixelRate ( NvRmHost1xChannelHandle  channel,
NvRmModuleID  moduleId,
NvU32  pixelRate 
)

Set Module pixel rate.

Parameters
channelHandle to the channel
moduleIdid for which to add pixel rate
pixelRate(pixels/second)

◆ NvRmHostCreateEventPollFd()

NvError NvRmHostCreateEventPollFd ( NvRmDeviceHandle  device,
int *  fd 
)

Get poll'able file descriptor (FD) User is responsible for closing the FD.

See NvRmHostTriggerEventPollFd() on how to trigger the event

Parameters
deviceThe RM instance
fdThe file descriptor to be returned

◆ NvRmHostTriggerEventPollFd()

NvError NvRmHostTriggerEventPollFd ( NvRmDeviceHandle  device,
int  fd,
NvU32  syncpointID,
NvU32  threshold 
)

Trigger an event on poll'able FD which is allocated with NvRmHostCreateEventPollFd()

API receives the file descriptor, syncpoint id, and threshold

On success, an event will be delivered to polling FD when Syncpoing value matches the threshold

Parameters
deviceThe RM instance
fdThe file descriptor
syncpointIDThe syncpoint ID
thresholdThreshold value

◆ NvSchedValueIsBetween()

static NV_INLINE NvBool NvSchedValueIsBetween ( const NvU32  a,
const NvU32  b,
const NvU32  c 
)
static
Returns
NV_TRUE if a <= b < c using wrapping comparison; NV_FALSE otherwise

Definition at line 619 of file nvrm_host1x.h.

Referenced by NvSchedValueWrappingComparison().

◆ NvSchedValueWrappingComparison()

static NV_INLINE NvBool NvSchedValueWrappingComparison ( const NvU32  x,
const NvU32  y 
)
static

Definition at line 630 of file nvrm_host1x.h.

References NvSchedValueIsBetween().