| 
 | 1 | +/*  | 
 | 2 | + * Copyright (c) 2025 Nordic Semiconductor ASA  | 
 | 3 | + * SPDX-License-Identifier: Apache-2.0  | 
 | 4 | + */  | 
 | 5 | + | 
 | 6 | +#ifndef ZEPHYR_SOC_NORDIC_NRF54H_IRONSIDE_SE_BOOT_REPORT_INCLUDE_NRF_IRONSIDE_SE_BOOT_REPORT_H_  | 
 | 7 | +#define ZEPHYR_SOC_NORDIC_NRF54H_IRONSIDE_SE_BOOT_REPORT_INCLUDE_NRF_IRONSIDE_SE_BOOT_REPORT_H_  | 
 | 8 | + | 
 | 9 | +#include <stdint.h>  | 
 | 10 | +#include <stddef.h>  | 
 | 11 | + | 
 | 12 | +#define IRONSIDE_SE_BOOT_REPORT_LOCAL_DOMAIN_CONTEXT_SIZE                                          \  | 
 | 13 | +	CONFIG_SOC_NRF54H20_IRONSIDE_SE_BOOT_REPORT_LOCAL_DOMAIN_CONTEXT_SIZE  | 
 | 14 | +#define IRONSIDE_SE_BOOT_REPORT_RANDOM_DATA_SIZE                                                   \  | 
 | 15 | +	CONFIG_SOC_NRF54H20_IRONSIDE_SE_BOOT_REPORT_RANDOM_DATA_SIZE  | 
 | 16 | + | 
 | 17 | +/** @brief UICR error description contained in the boot report. */  | 
 | 18 | +struct ironside_se_boot_report_uicr_error {  | 
 | 19 | +	/** The type of error. A value of 0 indicates no error */  | 
 | 20 | +	uint32_t error_type;  | 
 | 21 | +	/** Error descrpitions specific to each type of UICR error */  | 
 | 22 | +	union {  | 
 | 23 | +		/** RFU */  | 
 | 24 | +		struct {  | 
 | 25 | +			uint32_t rfu[4];  | 
 | 26 | +		} rfu;  | 
 | 27 | +	} description;  | 
 | 28 | +};  | 
 | 29 | + | 
 | 30 | +/** @brief IRONside boot report. */  | 
 | 31 | +struct ironside_se_boot_report {  | 
 | 32 | +	/** Magic value used to identify valid boot report */  | 
 | 33 | +	uint32_t magic;  | 
 | 34 | +	/** Firmware version of IRONside SE. 8bit MAJOR.MINOR.PATCH.TWEAK */  | 
 | 35 | +	uint32_t ironside_se_version_int;  | 
 | 36 | +	/** Human readable extraversion of IRONside SE */  | 
 | 37 | +	char ironside_se_extraversion[12];  | 
 | 38 | +	/** Firmware version of IRONside SE recovery firmware. 8bit MAJOR.MINOR.PATCH.TWEAK */  | 
 | 39 | +	uint32_t ironside_se_recovery_version_int;  | 
 | 40 | +	/** Human readable extraversion of IRONside SE */  | 
 | 41 | +	char ironside_se_recovery_extraversion[12];  | 
 | 42 | +	/** Copy of SICR.UROT.UPDATE.STATUS.*/  | 
 | 43 | +	uint32_t ironside_update_status;  | 
 | 44 | +	/** See @ref ironside_se_boot_report_uicr_error */  | 
 | 45 | +	struct ironside_se_boot_report_uicr_error uicr_error_description;  | 
 | 46 | +	/** Data passed from booting local domain to local domain being booted */  | 
 | 47 | +	uint8_t local_domain_context[IRONSIDE_SE_BOOT_REPORT_LOCAL_DOMAIN_CONTEXT_SIZE];  | 
 | 48 | +	/** CSPRNG data */  | 
 | 49 | +	uint8_t random_data[IRONSIDE_SE_BOOT_REPORT_RANDOM_DATA_SIZE];  | 
 | 50 | +	/** Reserved for Future Use */  | 
 | 51 | +	uint32_t rfu[64];  | 
 | 52 | +};  | 
 | 53 | + | 
 | 54 | +/**  | 
 | 55 | + * @brief Get a pointer to the IRONside boot report.  | 
 | 56 | + *  | 
 | 57 | + * @param[out] report Will be set to point to the IRONside boot report.  | 
 | 58 | + *  | 
 | 59 | + * @return non-negative value if success, negative value otherwise.  | 
 | 60 | + * @retval -EFAULT if the magic field in the report is incorrect.  | 
 | 61 | + * @retval -EINVAL if @ref report is NULL.  | 
 | 62 | + */  | 
 | 63 | +int ironside_se_boot_report_get(const struct ironside_se_boot_report **report);  | 
 | 64 | + | 
 | 65 | +#endif /* ZEPHYR_SOC_NORDIC_NRF54H_IRONSIDE_SE_BOOT_REPORT_INCLUDE_NRF_IRONSIDE_SE_BOOT_REPORT_H_ */  | 
0 commit comments