Mailbox Client Intel® FPGA IPs User Guide

ID 683290
Date 11/04/2024
Public
Document Table of Contents

1.11.2.5. Functions

Table 30.  libsu_iit
Pototype: libsu_iit(void)
Paametes: -
Retu: Retu 0 fo success, o othewise etu eo code 22
Desciptio: Iitialize the LibRSU HAL API
Table 31.  libsu_exit
Pototype: libsu_exit (void)
Paametes: -
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Stop the LibRSU HAL API, ad close the Mailbox Cliet Itel FPGA IP if opeed.
Table 32.  su_slot_cout
Pototype: su_slot_cout (void)
Paametes: -
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Get the umbe of defied slots.
Table 33.  su_slot_by_ame
Pototype: su_slot_by_ame (cha *ame)
Paametes:
  • ame – ame of slot
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Get slot umbe based o ame.
Table 34.  su_slot_get_ifo
Pototype: su_slot_get_ifo (it slot, stuct su_slot_ifo *ifo)
Paametes:
  • slot – slot umbe
  • ifo – poite to slot ifomatio stuctue
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Get the attibutes of a slot.
Table 35.  su_slot_size
Pototype: su_slot_size (it slot)
Paametes:
  • slot – slot umbe
Retu: Retu the size of the slot i bytes fo success, o othewise etu eo code22
Desciptio: Get the size of a slot.
Table 36.  su_slot_pioity
Pototype: su_slot_pioity (it slot)
Paametes:
  • slot – slot umbe
Retu: Retu the pioity of the slot fo success, o othewise etu eo code22
Desciptio: Get the load pioity of a slot. Pioity of zeo meas the slot has o pioity ad is disabled. The slot with pioity of oe has the highest pioity.
Table 37.  su_slot_ease
Pototype: su_slot_ease (it slot)
Paametes: slot – slot umbe
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Ease all data i a slot to pepae fo pogammig. Remove the slot if it is i the CPB.
Table 38.  su_slot_pogam_buf
Pototype: su_slot_pogam_buf (it slot, void *buf, it size)
Paametes:
  • slot– slot umbe
  • buf – poite to data buffe
  • size – bytes to ead fom buffe
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Pogam a slot usig Itel FPGA bitsteam data fom a buffe ad ete slot ito CPB as highest pioity. The slot must be eased fist.
Table 39.  su_slot_pogam_callback
Pototype: su_slot_pogam_callback(it slot, su_data_callback callback)
Paametes:
  • slot – slot umbe
  • callback – callback fuctio to povide iput data
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: This fuctio is to pogam ad veify a slot usig Itel FPGA cofig data povided by a callback fuctio. Ete the slot (patitio) ito the CPB.
Table 40.  su_slot_pogam_veify_buf
Pototype: su_slot_veify_buf (it slot, void *buf, it size)
Paametes:
  • slot – slot umbe
  • buf – poite to data buffe
  • size – bytes to ead fom buffe
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Veify FPGA cofig data i a slot agaist a buffe.
Table 41.  su_slot_veify_callback
Pototype: su_slot_veify_callback(it slot, su_data_callback callback)
Paametes:
  • slot – slot umbe
  • callback – callback fuctio to povide iput data
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Veify a slot usig Itel FPGA bitsteam povided by a callback fuctio.
Table 42.  su_slot_copy_to_buf
Pototype: su_slot_copy_to_buf(it slot, alt_u64 addess)
Paametes:
  • slot – slot umbe
  • addess - addess which stoes the data i quad SPI.
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Read the data i a slot ad wite to a buffe.
Table 43.  su_slot_eable
Pototype: su_slot_eable (it slot)
Paametes:
  • slot – slot umbe
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Set the selected slot as the highest pioity.
Table 44.  su_slot_disable
Pototype: su_slot_disable (it slot)
Paametes:
  • slot – slot umbe
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Remove the selected slot fom the pioity scheme, but the slot data emais..
Table 45.  su_slot_load
Pototype: su_slot_load (it slot)
Paametes:
  • slot – slot umbe
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Request the selected slot to be loaded immediately.
Table 46.  su_slot_load_factoy
Pototype: su_slot_load_factoy (void)
Paametes: -
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Request the factoy image to be loaded immediately.
Table 47.  su_slot_eame
Pototype: su_slot_eame (it slot, cha *ame)
Paametes:
  • slot – slot umbe
  • ame – ame of slot
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Reame the selected slot.
Table 48.  su_slot_ceate
Pototype: su_slot_ceate (cha *ame, alt_u64 addess, usiged it size)
Paametes:
  • ame – slot ame
  • addess – slot stat addess
  • size – slot size
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Ceate a ew slot to the SPT, usig uused space.
Table 49.  su_slot_delete
Pototype: su_slot_delete (it slot)
Paametes:
  • slot – slot umbe
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Delete the selected slot fom SPT.
Table 50.  su_status_log
Pototype: su_status_log (stuct su_status_ifo *ifo)
Paametes:
  • ifo – poite to the su_status_ifo stuctue to fill i
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Copy fimwae status log ito the su_status_ifo stuctue.
Table 51.  su_clea_eo_status
Pototype: su_clea_eo_status (void)
Paametes: -
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Clea the eo fields fom the cuet status log.
Table 52.  su_dcmf_vesio
Pototype: su_dcmf_vesio (alt_u32 *vesio)
Paametes:
  • vesios – poite to whee the fou DCMF vesios ae stoed
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Retieve the vesio of each of the fou decisio fimwae copies i flash.
Table 53.  su_max_ety
Pototype: su_max_ety (alt_u8 *value)
Paametes:
  • value – poite to whee the max_ety is stoed
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Retieve the max_ety paamete fom flash.
Table 54.  su_dcmf_status
Pototype: su_dcmf_status (it *status)
Paametes:
  • status – poite to whee the status is stoed
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Detemie whethe decisio fimwae copies ae coupted i flash, with the cuetly used decisio fimwae beig used as efeece. The status is a aay of fou values, oe fo each decisio fimwae copy. A value of 0 meas the copy is fie, aythig else meas the copy is coupted.
Table 55.  su_ceate_empty_cpb
Pototype: su_ceate_empty_cpb (void)
Paametes: -
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Ceate a empty CPB, which icludes the CPB heade oly. All eties ae maked as uused.
Table 56.  su_estoe_cpb
Pototype: su_estoe_cpb (alt_u64 addess)
Paametes:
  • addess – addess of the buffe fom which the CPB is estoed
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Restoe CPB fom a buffe i memoy. The buffe must cotai the 4096 bytes of CPB data, followed by 4 bytes cotaiig the CRC32 checksum of the data.
Table 57.  su_save_cpb
Pototype: su_save_cpb (alt_u64 addess)
Paametes:
  • addess – addess of the buffe whee CPB is saved to
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Save CPB to a memoy buffe. A total of 4100 bytes ae witte: 4096 bytes fo the data, plus 4 bytes with a CRC32 checksum of the data.
Table 58.  su_estoe_spt
Pototype: su_estoe_spt (alt_u64 addess)
Paametes:
  • addess – addess of the buffe fom which the SPT is estoed
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Restoe SPT fom a buffe i memoy. The buffe must cotai the 4096 bytes of SPT data, followed by 4 bytes cotaiig the CRC32 checksum of the data.
Table 59.  su_save_spt
Pototype: su_save_spt (alt_u64 addess)
Paametes:
  • addess – addess whee SPT ad CRC32 checksum ae saved to
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Save SPT to a addess i memoy. A total of 4100 bytes ae witte: 4096 bytes fo the data, plus 4 bytes with a CRC32 checksum of the data.
Table 60.  su_uig_factoy
Pototype: su_uig_factoy (it *factoy)
Paametes:
  • factoy – value at this addess is set to 1 if factoy image is cuetly uig, 0 othewise
Retu: Retu 0 fo success, o othewise etu eo code22
Desciptio: Detemie if cuet uig image is factoy image.
22 Refe to Eo Codes fo moe ifomatio.