SDL API Guide for J721E

Introduction

Functions

int32_t SDL_RAT_isRegionTranslationEnabled (const SDL_ratRegs *pRatRegs, uint32_t regionIndex)
 This function returns the enable status of the specified region address translation. More...
 
uint32_t SDL_RAT_getMaxRegions (const SDL_ratRegs *pRatRegs)
 
int32_t SDL_RAT_setErrMsgDestId (SDL_ratRegs *pRatRegs, uint32_t destId)
 This function is used to set the destination ID for error messages. More...
 
int32_t SDL_RAT_getErrMsgDestId (const SDL_ratRegs *pRatRegs, uint32_t *pDestId)
 This function is used to read the destination ID for error messages. More...
 
int32_t SDL_RAT_enableExceptionLog (SDL_ratRegs *pRatRegs)
 This function enables the exception logging capability. It also enables exception interrupt generation. The module's exception interrupt signal is asserted if the exception logging capability is enabled and the exception interrupt source is enabled by calling the. More...
 
int32_t SDL_RAT_disableExceptionLog (SDL_ratRegs *pRatRegs)
 This function disables the exception logging capability. It also disables the module's exception interrupt signal generation, regardless of whether the exception interrupt source is enabled or disabled. More...
 
int32_t SDL_RAT_isIntrPending (const SDL_ratRegs *pRatRegs, SDL_RAT_intrSrcTypes intrSrc)
 This function returns the pending interrupt status of the specified interrupt source. More...
 
int32_t SDL_RAT_setIntrPending (SDL_ratRegs *pRatRegs, SDL_RAT_intrSrcTypes intrSrc)
 This function is used to forceably set the pending status of the specified interrupt source. More...
 
int32_t SDL_RAT_clrIntrPending (SDL_ratRegs *pRatRegs, SDL_RAT_intrSrcTypes intrSrc)
 This function is used to clear the pending status of the specified interrupt source. More...
 
int32_t SDL_RAT_ackIntr (SDL_ratRegs *pRatRegs, SDL_RAT_intrSrcTypes intrSrc)
 This function is used to acknowledge the specified interrupt source. More...
 
int32_t SDL_RAT_enableIntr (SDL_ratRegs *pRatRegs, SDL_RAT_intrSrcTypes intrSrc)
 This function enables the specified interrupt source. It also calls SDL_RAT_enableExceptionLog to enable exception logging as there is no valid reason to enable the exception interrupt source and not log the exception information and assert the module's exception interrupt signal. More...
 
int32_t SDL_RAT_disableIntr (SDL_ratRegs *pRatRegs, SDL_RAT_intrSrcTypes intrSrc)
 This function disables the specified interrupt source. This prevents the module's exception interrupt signal from being asserted. Note that software can still call SDL_RAT_isIntrPending to poll for an exception event and call SDL_RAT_getExceptionInfo to read exception event information if exception logging is enabled. More...
 
int32_t SDL_RAT_getExceptionInfo (SDL_ratRegs *pRatRegs, SDL_ratExceptionInfo *pExceptionInfo)
 This function is used to get information for the last boundary crossing transaction exception captured. The log is automatically cleared by this function so that a future exception can be captured. More...
 
int32_t SDL_RAT_enableRegionTranslation (SDL_ratRegs *pRatRegs, uint32_t regionIndex)
 This function enables address translation for the specified region. More...
 
int32_t SDL_RAT_disableRegionTranslation (SDL_ratRegs *pRatRegs, uint32_t regionIndex)
 This function disables address translation for the specified region. More...
 
int32_t SDL_RAT_configRegionTranslation (SDL_ratRegs *pRatRegs, uint32_t regionIndex, SDL_ratTranslationCfgInfo *pTranslationCfg)
 This function is used to configure a region address translation for the specified region index. The translation is automatically enabled after it is configured. More...
 
int32_t SDL_RAT_verifyConfigRegionTranslation (const SDL_ratRegs *pRatRegs, uint32_t regionIndex, SDL_ratTranslationCfgInfo *pTranslationCfg)
 This function is used to configure a region address translation for the specified region index. The translation is automatically enabled after it is configured. More...
 
int32_t SDL_RAT_getStaticRegs (SDL_ratRegs *pRatRegs, uint32_t regionIndex, SDL_ratStaticRegs *pStaticRegs)
 This function returns the enable status of the specified region address translation. More...
 

Function Documentation

◆ SDL_RAT_isRegionTranslationEnabled()

int32_t SDL_RAT_isRegionTranslationEnabled ( const SDL_ratRegs pRatRegs,
uint32_t  regionIndex 
)

This function returns the enable status of the specified region address translation.


SDL_RAT_isRegionTranslationEnabled

Description
This function returns the enable status of the specified region address translation

Arguments
pRatRegs - A pointer (of type SDL_ratRegs*) to the base address of the RAT module
regionIndex - The index of the region to configure. This value must be in the range 0..(SDL_RAT_getMaxRegions()-1) inclusive.

Return Value
true - The specified region address translation is enabled
false - The specified region address translation is not enabled

Pre Condition
None

Post Condition
None

Reads
SDL_RAT_CTRL

Example

   SDL_ratRegs *pRatRegs = (SDL_ratRegs *)RAT_BASE_ADDRESS;
   uint32_t    regionIndex = 0;
   bool        bIsEnabled;

   bIsEnabled = SDL_ratIsRegionTranslationEnabled(pRatRegs,regionIndex);
   printf("Address translation for region %u is %s\n", regionIndex, bIsEnabled ? "enabled" : "not enabled" );
Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
regionIndex- The index of the region to configure. This value must be in the range 0..(SDL_RAT_getMaxRegions()-1) inclusive.

◆ SDL_RAT_getMaxRegions()

uint32_t SDL_RAT_getMaxRegions ( const SDL_ratRegs pRatRegs)


SDL_RAT_getMaxRegions

Description
This function returns the maximum number of regions that can be configured.

Arguments
pRatRegs - A pointer (of type SDL_ratRegs*) to the base address of the RAT module

Return Value
The the maximum number of regions that can be configured in this RAT

Pre Condition
None

Post Condition
None

Reads
None

Example

   SDL_ratRegs *pRatRegs = (SDL_ratRegs *)RAT_BASE_ADDRESS;
   uint32_t    maxRegions;

   maxRegions = SDL_ratGetMaxRegions(pRatRegs);

◆ SDL_RAT_setErrMsgDestId()

int32_t SDL_RAT_setErrMsgDestId ( SDL_ratRegs pRatRegs,
uint32_t  destId 
)

This function is used to set the destination ID for error messages.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
destId- The destination ID for future error messages

◆ SDL_RAT_getErrMsgDestId()

int32_t SDL_RAT_getErrMsgDestId ( const SDL_ratRegs pRatRegs,
uint32_t *  pDestId 
)

This function is used to read the destination ID for error messages.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
pDestId- A pointer to hold the destination ID register value

◆ SDL_RAT_enableExceptionLog()

int32_t SDL_RAT_enableExceptionLog ( SDL_ratRegs pRatRegs)

This function enables the exception logging capability. It also enables exception interrupt generation. The module's exception interrupt signal is asserted if the exception logging capability is enabled and the exception interrupt source is enabled by calling the.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module

◆ SDL_RAT_disableExceptionLog()

int32_t SDL_RAT_disableExceptionLog ( SDL_ratRegs pRatRegs)

This function disables the exception logging capability. It also disables the module's exception interrupt signal generation, regardless of whether the exception interrupt source is enabled or disabled.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module

◆ SDL_RAT_isIntrPending()

int32_t SDL_RAT_isIntrPending ( const SDL_ratRegs pRatRegs,
SDL_RAT_intrSrcTypes  intrSrc 
)

This function returns the pending interrupt status of the specified interrupt source.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
intrSrc- The interrupt source of type SDL_RAT_intrSrcTypes

◆ SDL_RAT_setIntrPending()

int32_t SDL_RAT_setIntrPending ( SDL_ratRegs pRatRegs,
SDL_RAT_intrSrcTypes  intrSrc 
)

This function is used to forceably set the pending status of the specified interrupt source.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
intrSrc- The interrupt source of type SDL_RAT_intrSrcTypes

◆ SDL_RAT_clrIntrPending()

int32_t SDL_RAT_clrIntrPending ( SDL_ratRegs pRatRegs,
SDL_RAT_intrSrcTypes  intrSrc 
)

This function is used to clear the pending status of the specified interrupt source.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
intrSrc- The interrupt source of type SDL_RAT_intrSrcTypes

◆ SDL_RAT_ackIntr()

int32_t SDL_RAT_ackIntr ( SDL_ratRegs pRatRegs,
SDL_RAT_intrSrcTypes  intrSrc 
)

This function is used to acknowledge the specified interrupt source.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
intrSrc- The interrupt source of type SDL_RAT_intrSrcTypes

◆ SDL_RAT_enableIntr()

int32_t SDL_RAT_enableIntr ( SDL_ratRegs pRatRegs,
SDL_RAT_intrSrcTypes  intrSrc 
)

This function enables the specified interrupt source. It also calls SDL_RAT_enableExceptionLog to enable exception logging as there is no valid reason to enable the exception interrupt source and not log the exception information and assert the module's exception interrupt signal.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
intrSrc- The interrupt source of type SDL_RAT_intrSrcTypes

◆ SDL_RAT_disableIntr()

int32_t SDL_RAT_disableIntr ( SDL_ratRegs pRatRegs,
SDL_RAT_intrSrcTypes  intrSrc 
)

This function disables the specified interrupt source. This prevents the module's exception interrupt signal from being asserted. Note that software can still call SDL_RAT_isIntrPending to poll for an exception event and call SDL_RAT_getExceptionInfo to read exception event information if exception logging is enabled.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
intrSrc- The interrupt source of type SDL_RAT_intrSrcTypes

◆ SDL_RAT_getExceptionInfo()

int32_t SDL_RAT_getExceptionInfo ( SDL_ratRegs pRatRegs,
SDL_ratExceptionInfo pExceptionInfo 
)

This function is used to get information for the last boundary crossing transaction exception captured. The log is automatically cleared by this function so that a future exception can be captured.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
pExceptionInfo- A pointer to a SDL_ratExceptionInfo structure containing returned exception information

◆ SDL_RAT_enableRegionTranslation()

int32_t SDL_RAT_enableRegionTranslation ( SDL_ratRegs pRatRegs,
uint32_t  regionIndex 
)

This function enables address translation for the specified region.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
regionIndex- The index of the region to configure. This value must be in the range 0..(SDL_RAT_getMaxRegions()-1) inclusive.

◆ SDL_RAT_disableRegionTranslation()

int32_t SDL_RAT_disableRegionTranslation ( SDL_ratRegs pRatRegs,
uint32_t  regionIndex 
)

This function disables address translation for the specified region.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
regionIndex- The index of the region to configure. This value must be in the range 0..(SDL_RAT_getMaxRegions()-1) inclusive.

◆ SDL_RAT_configRegionTranslation()

int32_t SDL_RAT_configRegionTranslation ( SDL_ratRegs pRatRegs,
uint32_t  regionIndex,
SDL_ratTranslationCfgInfo pTranslationCfg 
)

This function is used to configure a region address translation for the specified region index. The translation is automatically enabled after it is configured.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
regionIndex- The index of the region to configure. This value must be in the range 0..(SDL_RAT_getMaxRegions()-1) inclusive.
pTranslationCfg- A pointer of type SDL_ratTranslationCfgInfo containing configuration information

◆ SDL_RAT_verifyConfigRegionTranslation()

int32_t SDL_RAT_verifyConfigRegionTranslation ( const SDL_ratRegs pRatRegs,
uint32_t  regionIndex,
SDL_ratTranslationCfgInfo pTranslationCfg 
)

This function is used to configure a region address translation for the specified region index. The translation is automatically enabled after it is configured.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
regionIndex- The index of the region to configure. This value must be in the range 0..(SDL_RAT_getMaxRegions()-1) inclusive.
pTranslationCfg- A pointer of type SDL_ratTranslationCfgInfo containing configuration information

◆ SDL_RAT_getStaticRegs()

int32_t SDL_RAT_getStaticRegs ( SDL_ratRegs pRatRegs,
uint32_t  regionIndex,
SDL_ratStaticRegs pStaticRegs 
)

This function returns the enable status of the specified region address translation.

Parameters
pRatRegs- A pointer (of type SDL_ratRegs*) to the base address of the RAT module
regionIndex- The index of the region to configure. This value must be in the range 0..(SDL_RAT_getMaxRegions()-1) inclusive.
pStaticRegs- A pointer to the static registers structure.