Zephyr Project API 4.1.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
update.h File Reference
#include <stdint.h>
#include <stddef.h>

Go to the source code of this file.

Data Structures

struct  ironside_update_blob
 IRONside update blob. More...
 

Macros

#define IRONSIDE_UPDATE_MANIFEST_LENGTH   (256)
 Length of the update manifest in bytes.
 
#define IRONSIDE_UPDATE_PUBKEY_LENGTH   (32)
 Length of the update public key in bytes.
 
#define IRONSIDE_UPDATE_SIGNATURE_LENGTH   (64)
 Length of the update signature in bytes.
 
#define IRONSIDE_CALL_ID_UPDATE_SERVICE_V0   1
 
#define IRONSIDE_UPDATE_SERVICE_UPDATE_PTR_IDX   (0)
 
#define IRONSIDE_UPDATE_SERVICE_RETCODE_IDX   (0)
 
Update service error codes.
#define IRONSIDE_UPDATE_ERROR_NOT_PERMITTED   (1)
 Caller does not have access to the provided update candidate buffer.
 
#define IRONSIDE_UPDATE_ERROR_SICR_WRITE_FAILED   (2)
 Failed to write the update metadata to SICR.
 

Functions

int ironside_update (const struct ironside_update_blob *update)
 Request a firmware upgrade of the IRONside SE.
 

Macro Definition Documentation

◆ IRONSIDE_CALL_ID_UPDATE_SERVICE_V0

#define IRONSIDE_CALL_ID_UPDATE_SERVICE_V0   1

◆ IRONSIDE_UPDATE_ERROR_NOT_PERMITTED

#define IRONSIDE_UPDATE_ERROR_NOT_PERMITTED   (1)

Caller does not have access to the provided update candidate buffer.

◆ IRONSIDE_UPDATE_ERROR_SICR_WRITE_FAILED

#define IRONSIDE_UPDATE_ERROR_SICR_WRITE_FAILED   (2)

Failed to write the update metadata to SICR.

◆ IRONSIDE_UPDATE_MANIFEST_LENGTH

#define IRONSIDE_UPDATE_MANIFEST_LENGTH   (256)

Length of the update manifest in bytes.

◆ IRONSIDE_UPDATE_PUBKEY_LENGTH

#define IRONSIDE_UPDATE_PUBKEY_LENGTH   (32)

Length of the update public key in bytes.

◆ IRONSIDE_UPDATE_SERVICE_RETCODE_IDX

#define IRONSIDE_UPDATE_SERVICE_RETCODE_IDX   (0)

◆ IRONSIDE_UPDATE_SERVICE_UPDATE_PTR_IDX

#define IRONSIDE_UPDATE_SERVICE_UPDATE_PTR_IDX   (0)

◆ IRONSIDE_UPDATE_SIGNATURE_LENGTH

#define IRONSIDE_UPDATE_SIGNATURE_LENGTH   (64)

Length of the update signature in bytes.

Function Documentation

◆ ironside_update()

int ironside_update ( const struct ironside_update_blob update)

Request a firmware upgrade of the IRONside SE.

This invokes the IRONside SE update service. The device must be restarted for the update to be installed. Check the update status in the application boot report to see if the update was successfully installed.

Parameters
updatePointer to update blob
Return values
-IRONSIDE_UPDATE_ERROR_NOT_PERMITTEDif missing access to the update candidate.
-IRONSIDE_UPDATE_ERROR_SICR_WRITE_FAILEDif writing update parameters to SICR failed.
Returns
Positive non-0 error status if reported by IRONside call.
0 on a successful request (although the update itself may still fail).