Data integrity handling core functionality, based on secure counter. More...
Macros | |
| #define | MCUX_CSSL_DI_CHECK_PASSED_IMPL |
| Positive comparison result value. | |
| #define | MCUX_CSSL_DI_CHECK_FAILED_IMPL |
| Negative comparison result value. | |
| #define | MCUX_CSSL_DI_BACKUP_SC(backupValue) |
| Backs up the current secure counter value. | |
| #define | MCUX_CSSL_DI_RESTORE_SC_REF(reference) |
| Restores the data integrity reference value to the corresponding HW SFR. | |
| #define | MCUX_CSSL_DI_INIT_IMPL(backupValue) |
| Backup of the current data integrity value, that will be checked later on with MCUX_CSSL_SC_CHECK. | |
| #define | MCUX_CSSL_DI_CHECK_IMPL(reference) |
| Comparison operation implementation for the data integrity. | |
| #define | MCUX_CSSL_DI_CHECK_EXIT_IMPL(id, reference, fail) |
| Comparison operation implementation for the data integrity. | |
Data integrity handling core functionality, based on secure counter.
| #define MCUX_CSSL_DI_CHECK_PASSED_IMPL |
Positive comparison result value.
| #define MCUX_CSSL_DI_CHECK_FAILED_IMPL |
Negative comparison result value.
| #define MCUX_CSSL_DI_BACKUP_SC | ( | backupValue | ) |
Backs up the current secure counter value.
| backupValue | Fresh variable name to store the current SC value. |
| #define MCUX_CSSL_DI_RESTORE_SC_REF | ( | reference | ) |
Restores the data integrity reference value to the corresponding HW SFR.
| reference | Data integrity reference value that will be written to the HW SFR (ignored). |
| #define MCUX_CSSL_DI_INIT_IMPL | ( | backupValue | ) |
Backup of the current data integrity value, that will be checked later on with MCUX_CSSL_SC_CHECK.
Note that in case the secure counter back-end requires allocation, it is expected that this will be handled by the Flow Protection mechanism before the initialization of the Data Integrity.
| backupValue | Fresh variable name to store the current DI value. |
| #define MCUX_CSSL_DI_CHECK_IMPL | ( | reference | ) |
Comparison operation implementation for the data integrity.
| reference | Reference initial value to compare the data integrity value against. |
| #define MCUX_CSSL_DI_CHECK_EXIT_IMPL | ( | id, | |
| reference, | |||
| fail ) |
Comparison operation implementation for the data integrity.
It compares the data integrity value to the reference initial value, and exits with the given fault status code if the comparison fails. The reference value shall be the initial value that was backed up with MCUX_CSSL_DI_INIT. If the comparison succeeds, the reference value is restored to the HW SFR, and normal execution will continue.
| id | Identifier of the function from which we will exit. |
| reference | Reference initial data integrity value that will be restored to the HW SFR. |
| fail | Result that should be returned if the data integrity check failed. |