XSem_CmdNpiGetStatus - 2023.1 English

Standalone Library Documentation: BSP and Libraries Document Collection (UG643)

Document ID
UG643
Release Date
2023-05-16
Version
2023.1 English

This function is used to read all NPI Status registers from PMC RAM and send to user application.

Prototype

XStatus XSem_CmdNpiGetStatus(XSemNpiStatus *NpiStatusInfo);

Parameters

The following table lists the XSem_CmdNpiGetStatus function arguments.

Table 1. XSem_CmdNpiGetStatus Arguments
Type Member Description
XSemNpiStatus * NpiStatusInfo Structure Pointer with NPI Status details
  • NpiStatusInfo->Status: Provides details about NPI scan
    • Bit [31]: 0 - No error, SHA-3 engine is present 1 - Cryptographic acceleration blocks are disabled for export compliance. No support for NPI scan, an event will be sent to R5
    • Bit [30]: 0 - NPI scan is running for scheduled interval 1 - Indicates NPI scan failed to run on scheduled interval. If NPI scan is not executed as per the configured periodicity, the error will notified to R5 user. The scan will continue to run
    • Bit [29]: 0- No descriptor missed during scanning 1- Indicates NPI scan failed to scan all descriptors completely (excluding arbitration failures). This will be notified to R5 user and the scan will continue to run.
    • Bit [28]: 0 - NPI scan executing within budget time 1 - Indicates NPI scan has exceeded maximum budget execution time of 20ms. This will be notified to R5 user and the scan will continue to run.
    • Bit [27]: 0 - No error in SLR to SLR communication 1 - Indicates failure in SSIT internal communication channel This bit is applicable for SSIT devices.
    • Bit [26]: Reserved
    • Bit [25]: 0 - No error in PMC_PL_GPO 1 - Indicates GPO Initialization or write failed. This is HW failure. In this condition, the scan will be stopped, and notification will be sent to R5
    • Bit [24]: 0 - No error SHA-3 engine 1 - Indicates SHA engine failed to function during initialization or start or DMA transfer. This is HW failure. In this condition, the scan will be stopped, and notification will be sent to R5
    • Bit [23]: 0 - No error in register writes 1 - Indicates the register write and read back failure occurred during the scan. This is HW failure. In this condition, the scan will be stopped, and notification will be sent to R5
    • Bit [22]: Reserved
    • Bit [21]: 0 - No error in DDR calibration 1 - Indicates NPI DDRMC Main Slave Arbitration Timeout occurred during the scan. If the DDRMC calibration is not done, the descriptor will be skipped and scan will continue to run for next descriptor
    • Bit [20]: 0 - No error in descriptor format 1 - Indicates NPI Descriptor has invalid format. This failure indicates that there is some corruption in the XilSEM NPI descriptor data. The scan will be stopped, and notification will be sent to R5
    • Bit [19]: 0 - No error in NPI Descriptor SHA header 1 - Indicates NPI Descriptor SHA Header mismatch occurred during the scan. This failure indicates that there is some corruption in the XilSEM NPI descriptor data. The scan will be stopped, and notification will be sent to R5
    • Bit [18]: 0 - NPI descriptors are present in the memory 1 - Indicates the absence of NPI Descriptor (Zero descriptors) This failure indicates that there is some corruption in the XilSEM NPI descriptor data. The scan will be stopped, and notification will be sent to R5
    • Bit [17]: 0 - No error in SHA comparison during run time 1- Indicates SHA comparison failure occurred during run time. This failure indicates that there is some bit flip in the NPI registers. The scan will be stopped and an event will be sent to R5
    • Bit [16]: 0 - No error in SHA comparison during first scan 1- Indicates SHA comparison failure occurred during initialization. This failure indicates that there is some bit flip in the NPI registers. The scan will be stopped and an event will be sent to R5
    • Bit [15-12]: Reserved
    • Bit [11]: 0 - NPI scan task is not added to PLM Scheduler to run periodically 1 - NPI scan task is added to PLM Scheduler to run periodically This bit is for NPI scan state information.
    • Bit [10]: NPI scan is suspended 0 - NPI scan is not suspended 1 - NPI scan is suspended due to errors This bit is for NPI scan state information.
    • Bit [09]: 0 - NPI scan initialization is not done 1 - NPI scan initialization is done This bit is for NPI scan state information.
    • Bit [08]: 0 - NPI scan is present in the design 1 - NPI scan disabled in the design This bit is for NPI scan state information.
    • Bit [07-06]: Reserved
    • Bit [05]: 0 - No internal error 1 - NPI scan is in error state (due to timeouts, invalid descriptors) This bit is for NPI scan state information.
    • Bit [04]: 0 - No error in NPI Scan 1 - NPI scan in SHA comparison mismatch error state. This bit is for NPI scan state information.
    • Bit [03]: 0 - NPI scan is not in SHA error inject state 1 - NPI scan is in SHA error inject state. This bit is for NPI scan state information.
    • Bit [02]: 0 - NPI scan is not in scan state 1 - NPI scan is in scan state. This bit is for NPI scan state information.
    • Bit [01]: 0 - NPI scan is not in initialization state 1 - NPI scan is in initialization state This bit is for NPI scan state information.
    • Bit [00]: 0 - NPI scan is not in idle state 1 - NPI scan is in idle state This bit is for NPI scan state information.
  • NpiStatusInfo->SlvSkipCnt: Provides NPI descriptor slave skip counter value if arbitration failure. This is 8 words result to accommodate 32 1-Byte skip counters for individual slaves arbitration failures. Slaves can be DDRMC Main, GT for which arbitration is required before performing scanning.
  • NpiStatusInfo->ScanCnt: NPI scan counter value. This counter represents number of periodic scan cycle completion.
  • NpiStatusInfo->HbCnt: NPI heartbeat counter value. This counter represents number of scanned descriptor slaves.
  • NpiStatusInfo->ErrInfo: NPI scan error information if SHA mismatch is detected. This is 2 word information.
    • Word 0: Node ID of descriptor for which SHA mismatch is detected
    • Word 1 Bit [15-8]: NPI descriptor index number
    • Word 1 Bit [7-0]: NPI Slave Skip count Index

Returns

This API returns the success or failure.
  • XST_FAILURE: If NULL pointer reference of NpiStatusInfo
  • XST_SUCCESS: On successful read from PMC RAM