The following flow is used by modules to trigger a event:
- Add the event index to the SsitEventIndex table in the xplmi_ssit.h file.
- Register the event with valid input arguments during boot using the
XPlmi_SsitRegisterEvent()
API. - Trigger an event:
- To trigger a message event, form the request buffer with the
command information and call the
XPlmi_SsitWriteEventBufferAndTriggerMsgEvent()
API. - To trigger a notification event which does not have any data
to be sent, call the
XPlmi_SsitTriggerEvent()
API with valid input arguments.
- To trigger a message event, form the request buffer with the
command information and call the
- Once the event is triggered, wait for an acknowledgment from the triggered
secondary SLR using the
XPlmi_SsitWaitForEvent()
API. - Once the event is acknowledged by the corresponding SLR, read the
response using the
XPlmi_SsitReadResponse()
API. This step is applicable only for Message Events.
Note: If a message event is being triggered, then
steps 3 to 5 are combined in a single API called
XPlmi_SsitSendMsgEventAndGetResp()
.The flow for when the event is triggered and the interrupt is generated to the corresponding SLR is as follows:
- The SSI technology interrupt handler checks for the pending event and calls the registered handler for the event.
- The handler must take care of acknowledging the event using the
XPlmi_SsitAcknowledgeEvent()
API. For message events, theXPlmi_SsitMsgEventHandler()
handler takes care of writing the response and acknowledging the event once the command is handled.