Formatting and documentation fixes

Signed-off-by: Andrzej Kurek <andrzej.kurek@arm.com>
This commit is contained in:
Andrzej Kurek 2022-02-03 09:42:47 -05:00
parent 96c8f9e89d
commit 981a0ceeee
2 changed files with 7 additions and 3 deletions

View File

@ -46,8 +46,10 @@ typedef struct {
psa_key_location_t source;
} mbedtls_test_driver_key_management_hooks_t;
/* 0x800000 is a vendor-specific location, unused by the PSA, overwritten
* in tests that expect a different value. */
/* The location is initialized to the invalid value 0x800000. Invalid in the
* sense that no PSA specification will assign a meaning to this location
* (stated first in version 1.0.1 of the specification) and that it is not
* used as a location of an opaque test drivers. */
#define MBEDTLS_TEST_DRIVER_KEY_MANAGEMENT_INIT { NULL, 0, PSA_SUCCESS, 0, 0x800000 }
static inline mbedtls_test_driver_key_management_hooks_t
mbedtls_test_driver_key_management_hooks_init( void )

View File

@ -321,7 +321,9 @@ void validate_key( int force_status_arg,
data_t *key_input,
int expected_status_arg )
{
psa_key_lifetime_t lifetime = PSA_KEY_LIFETIME_FROM_PERSISTENCE_AND_LOCATION(PSA_KEY_PERSISTENCE_DEFAULT, location);
psa_key_lifetime_t lifetime =
PSA_KEY_LIFETIME_FROM_PERSISTENCE_AND_LOCATION( \
PSA_KEY_PERSISTENCE_DEFAULT, location);
mbedtls_svc_key_id_t id = mbedtls_svc_key_id_make( owner_id_arg, id_arg );
psa_status_t force_status = force_status_arg;
psa_status_t expected_status = expected_status_arg;