![]() |
PDK API Guide for J721E
|
Functions | |
uint32_t | CSL_psilcfgGetRevision (const CSL_psilcfgRegs *pRegs) |
Return revision of the PSILCFG module. More... | |
bool | CSL_psilcfgWrite (const CSL_psilcfgRegs *pRegs, uint32_t threadId, uint32_t regId, uint32_t data) |
Write a value to a PSI-L periperal using the PSI-L configuration proxy. More... | |
bool | CSL_psilcfgRead (const CSL_psilcfgRegs *pRegs, uint32_t threadId, uint32_t regId, uint32_t *pData) |
Read a value from a PSI-L periperal using the PSI-L configuration proxy. More... | |
bool | CSL_psilcfgSetThreadEnable (const CSL_psilcfgRegs *pRegs, uint32_t threadId, bool bEnable) |
Enable or disable a thread. More... | |
bool | CSL_psilcfgSetThreadRealtimeEnable (const CSL_psilcfgRegs *pRegs, uint32_t threadId, bool bEnable) |
Enable or disable a thread via the realtime register. More... | |
bool | CSL_psilcfgTeardownThread (const CSL_psilcfgRegs *pRegs, uint32_t threadId) |
Teardown a thread. More... | |
bool | CSL_psilcfgClrTeardown (const CSL_psilcfgRegs *pRegs, uint32_t threadId) |
Clear a thread's teardown and flush bits. More... | |
bool | CSL_psilcfgFlushThread (const CSL_psilcfgRegs *pRegs, uint32_t threadId) |
Flush data from a destination thread. More... | |
bool | CSL_psilcfgSetThreadPause (const CSL_psilcfgRegs *pRegs, uint32_t threadId, bool bPause) |
Pause or un-pause a thread. More... | |
bool | CSL_psilcfgCreateRoute (const CSL_psilcfgRegs *pRegs, uint32_t srcThreadId, uint32_t dstThreadId) |
Create a route through the PSI-L switch. More... | |
bool | CSL_psilcfgCreateLink (const CSL_psilcfgRegs *pRegs, uint32_t srcThreadId, uint32_t dstThreadId) |
Create a link through the PSI-L switch. More... | |
bool | CSL_psilcfgIsThreadIdle (const CSL_psilcfgRegs *pRegs, uint32_t threadId) |
Determine if a disabled or paused thread is idle. More... | |
uint32_t CSL_psilcfgGetRevision | ( | const CSL_psilcfgRegs * | pRegs | ) |
Return revision of the PSILCFG module.
This function returns the contents of the PSILCFG revision register. Consult the PSILCFG module documentation for a description of the contents of the revision register.
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
bool CSL_psilcfgWrite | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | threadId, | ||
uint32_t | regId, | ||
uint32_t | data | ||
) |
Write a value to a PSI-L periperal using the PSI-L configuration proxy.
This function submits a write command to the PSI-L periperal specified by the thread 'threadId' at address specified by 'regId'. It then waits for the write command to complete before returning.
Note: This command will return false if the PSI-L peripheral specified by the thread 'threadId' is invalid, the regId is invalid, or the peripheral is powered down or is in reset.
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
threadId | [IN] Thread identifying the PSI-L peripheral to write to |
regId | [IN] Register of the PSI-L peripheral to write to. See CSL_PsilCfgReg. |
data | [IN] Data to write |
bool CSL_psilcfgRead | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | threadId, | ||
uint32_t | regId, | ||
uint32_t * | pData | ||
) |
Read a value from a PSI-L periperal using the PSI-L configuration proxy.
This function submits a read command to the PSI-L periperal specified by the thread 'threadId' at address specified by 'regId', waits for the read command to complete, then reads and returns the data value in pData.
Note: This command will return false if the PSI-L peripheral specified by the thread 'threadId' is invalid, the regId is invalid, or the peripheral is powered down or is in reset.
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
threadId | [IN] Thread identifying the PSI-L peripheral to write to |
regId | [IN] Register of the PSI-L peripheral to read from. See CSL_PsilCfgReg. |
pData | [OUT] A pointer where to store the 32-bit data value read |
bool CSL_psilcfgSetThreadEnable | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | threadId, | ||
bool | bEnable | ||
) |
Enable or disable a thread.
This function enables or disables the specified thread.
Software should only disable a thread if the thread is to be reset before being re-enabled. Otherwise, a teardown command CSL_psilcfgTeardownThread should be used to gracefully disable a thread.
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
threadId | [IN] Thread identifying the PSI-L peripheral |
bEnable | [IN] 0 = thread is disabled, 1 = thread is enabled |
bool CSL_psilcfgSetThreadRealtimeEnable | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | threadId, | ||
bool | bEnable | ||
) |
Enable or disable a thread via the realtime register.
This function enables or disables the specified thread via the realtime register.
Software should only disable a thread if the thread is to be reset before being re-enabled. Otherwise, a teardown command CSL_psilcfgTeardownThread should be used to gracefully disable a thread.
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
threadId | [IN] Thread identifying the PSI-L peripheral |
bEnable | [IN] 0 = thread is disabled, 1 = thread is enabled |
bool CSL_psilcfgTeardownThread | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | threadId | ||
) |
Teardown a thread.
This function tears down the specified thread.
For a source thread:
A teardown command will stop transferring data on a boundary which is appropriate for the type of attached peripheral and clear and mask any peripheral specific functionality (DMA event counters, etc.). After stopping data transfer, the source thread sends a 'NULL data' teardown message to the destination thread. Once the thread teardown is complete and ready to be reused, the enable bit is cleared.
For a destination thread:
To perform a destination thread teardown, it is recommended that the teardown command be set in the source thread and it will automatically propagate to destination thread with the normal flow of peripheral data via the tdown bit. As a result, if a destination thread is specified in this function, then nothing is done and false is returned.
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
threadId | [IN] Thread identifying the PSI-L peripheral |
bool CSL_psilcfgClrTeardown | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | threadId | ||
) |
Clear a thread's teardown and flush bits.
This function clears the teardown and flush bits in the specified thread's PSIL realtime enable register.
Software can call this function following a thread teardown via the CSL_psilcfgTeardownThread function to clear the thread's teardown and flush bits prior to re-enabling this thread again.
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
threadId | [IN] Thread identifying the PSI-L peripheral |
bool CSL_psilcfgFlushThread | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | threadId | ||
) |
Flush data from a destination thread.
This function flushes data in the specified destination thread.
This function only operates with destination threads. The flush command causes all destination thread data to be discarded instead of being written to the peripheral.
The flush command should be called only when a thread fails to complete its teardown procedure normally, because a peripheral is no longer functioning or because some other factor is causing a deadlock beyond the PSI-L interface.
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
threadId | [IN] Thread identifying the PSI-L peripheral |
bool CSL_psilcfgSetThreadPause | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | threadId, | ||
bool | bPause | ||
) |
Pause or un-pause a thread.
This function pauses or un-pauses the specified thread.
While paused, data transfers will no longer occur but other application specific actions may still occur (DMA event increments, etc.).
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
threadId | [IN] Thread identifying the PSI-L peripheral |
bPause | [IN] 0 = thread is un-paused, 1 = thread is paused |
bool CSL_psilcfgCreateRoute | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | srcThreadId, | ||
uint32_t | dstThreadId | ||
) |
Create a route through the PSI-L switch.
This function creates a route through the PSI-L switch between the specified source and destination thread ID's. It reads the thread width and credit count from the destination thread and sets the source thread to use these values. It then enables the credit passing functionality for both threads.
In addition, this function also enables both threads via their psil real-time enable configuration register.
srcThreadId must not have bit 15 set to 1. If it does, this function does nothing and false is returned.
This function forces bit 15 of dstThreadId to 1.
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
srcThreadId | [IN] Thread identifying the source PSI-L peripheral |
dstThreadId | [IN] Thread identifying the destination PSI-L peripheral |
bool CSL_psilcfgCreateLink | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | srcThreadId, | ||
uint32_t | dstThreadId | ||
) |
Create a link through the PSI-L switch.
This function creates a link through the PSI-L switch between the specified source and destination thread ID's. It reads the thread width and credit count from the destination thread and sets the source thread to use these values. It then enables the credit passing functionality for both threads.
Unlike the CSL_psilcfgCreateRoute() function, this function does not enable either thread via their real-time enable configuration register. Software must use the udmap CSL-FL CSL_udmapEnableLink() function to accomplish this.
srcThreadId must not have bit 15 set to 1. If it does, this function does nothing and false is returned.
This function forces bit 15 of dstThreadId to 1.
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
srcThreadId | [IN] Thread identifying the source PSI-L peripheral |
dstThreadId | [IN] Thread identifying the destination PSI-L peripheral |
bool CSL_psilcfgIsThreadIdle | ( | const CSL_psilcfgRegs * | pRegs, |
uint32_t | threadId | ||
) |
Determine if a disabled or paused thread is idle.
This function returns the idle status of the specified thread.
A thread will return a true idle status under the following conditions: o For destination threads: the thread is disabled and is also idle (no active transactions) o For source threads: the thread is paused or disabled and is also idle (no active transactions)
pRegs | [IN] Pointer to the CSL_psilcfgRegs register structure |
threadId | [IN] Thread identifying the PSI-L peripheral |