mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-23 03:25:38 +01:00
Rename hash test driver functions to match auto-naming scheme
Signed-off-by: Steven Cooreman <steven.cooreman@silabs.com>
This commit is contained in:
parent
d029b60770
commit
25555227e5
@ -1084,7 +1084,7 @@ psa_status_t psa_driver_wrapper_hash_compute(
|
||||
|
||||
/* Try accelerators first */
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
status = test_transparent_hash_compute( alg, input, input_length,
|
||||
status = mbedtls_transparent_test_driver_hash_compute( alg, input, input_length,
|
||||
hash, hash_size, hash_length );
|
||||
if( status != PSA_ERROR_NOT_SUPPORTED )
|
||||
return( status );
|
||||
@ -1116,7 +1116,7 @@ psa_status_t psa_driver_wrapper_hash_setup(
|
||||
|
||||
/* Try setup on accelerators first */
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
status = test_transparent_hash_setup( &operation->ctx.test_ctx, alg );
|
||||
status = mbedtls_transparent_test_driver_hash_setup( &operation->ctx.test_ctx, alg );
|
||||
if( status == PSA_SUCCESS )
|
||||
operation->id = PSA_CRYPTO_TRANSPARENT_TEST_DRIVER_ID;
|
||||
|
||||
@ -1149,7 +1149,7 @@ psa_status_t psa_driver_wrapper_hash_clone(
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
case PSA_CRYPTO_TRANSPARENT_TEST_DRIVER_ID:
|
||||
target_operation->id = PSA_CRYPTO_TRANSPARENT_TEST_DRIVER_ID;
|
||||
return( test_transparent_hash_clone( &source_operation->ctx.test_ctx,
|
||||
return( mbedtls_transparent_test_driver_hash_clone( &source_operation->ctx.test_ctx,
|
||||
&target_operation->ctx.test_ctx ) );
|
||||
#endif
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_HASH)
|
||||
@ -1174,7 +1174,7 @@ psa_status_t psa_driver_wrapper_hash_update(
|
||||
{
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
case PSA_CRYPTO_TRANSPARENT_TEST_DRIVER_ID:
|
||||
return( test_transparent_hash_update( &operation->ctx.test_ctx,
|
||||
return( mbedtls_transparent_test_driver_hash_update( &operation->ctx.test_ctx,
|
||||
input, input_length ) );
|
||||
#endif
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_HASH)
|
||||
@ -1200,7 +1200,7 @@ psa_status_t psa_driver_wrapper_hash_finish(
|
||||
{
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
case PSA_CRYPTO_TRANSPARENT_TEST_DRIVER_ID:
|
||||
return( test_transparent_hash_finish( &operation->ctx.test_ctx,
|
||||
return( mbedtls_transparent_test_driver_hash_finish( &operation->ctx.test_ctx,
|
||||
hash, hash_size, hash_length ) );
|
||||
#endif
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_HASH)
|
||||
@ -1225,7 +1225,7 @@ psa_status_t psa_driver_wrapper_hash_abort(
|
||||
{
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
case PSA_CRYPTO_TRANSPARENT_TEST_DRIVER_ID:
|
||||
return( test_transparent_hash_abort( &operation->ctx.test_ctx ) );
|
||||
return( mbedtls_transparent_test_driver_hash_abort( &operation->ctx.test_ctx ) );
|
||||
#endif
|
||||
#if defined(MBEDTLS_PSA_BUILTIN_HASH)
|
||||
case PSA_CRYPTO_MBED_TLS_DRIVER_ID:
|
||||
|
@ -46,7 +46,7 @@ typedef union {
|
||||
unsigned dummy; /* Make sure this structure is always non-empty */
|
||||
mbedtls_psa_hash_operation_t mbedtls_ctx;
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
test_transparent_hash_operation_t test_ctx;
|
||||
mbedtls_transparent_test_driver_hash_operation_t test_ctx;
|
||||
#endif
|
||||
} psa_driver_hash_context_t;
|
||||
|
||||
|
@ -541,7 +541,7 @@ psa_status_t is_hash_accelerated( psa_algorithm_t alg )
|
||||
}
|
||||
#endif /* INCLUDE_HASH_TEST_DRIVER */
|
||||
|
||||
psa_status_t test_transparent_hash_compute(
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_compute(
|
||||
psa_algorithm_t alg,
|
||||
const uint8_t *input,
|
||||
size_t input_length,
|
||||
@ -566,8 +566,8 @@ psa_status_t test_transparent_hash_compute(
|
||||
#endif
|
||||
}
|
||||
|
||||
psa_status_t test_transparent_hash_setup(
|
||||
test_transparent_hash_operation_t *operation,
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_setup(
|
||||
mbedtls_transparent_test_driver_hash_operation_t *operation,
|
||||
psa_algorithm_t alg )
|
||||
{
|
||||
#if defined(INCLUDE_HASH_TEST_DRIVER)
|
||||
@ -582,9 +582,9 @@ psa_status_t test_transparent_hash_setup(
|
||||
#endif
|
||||
}
|
||||
|
||||
psa_status_t test_transparent_hash_clone(
|
||||
const test_transparent_hash_operation_t *source_operation,
|
||||
test_transparent_hash_operation_t *target_operation )
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_clone(
|
||||
const mbedtls_transparent_test_driver_hash_operation_t *source_operation,
|
||||
mbedtls_transparent_test_driver_hash_operation_t *target_operation )
|
||||
{
|
||||
#if defined(INCLUDE_HASH_TEST_DRIVER)
|
||||
if( is_hash_accelerated( source_operation->operation.alg ) == PSA_SUCCESS )
|
||||
@ -599,8 +599,8 @@ psa_status_t test_transparent_hash_clone(
|
||||
#endif
|
||||
}
|
||||
|
||||
psa_status_t test_transparent_hash_update(
|
||||
test_transparent_hash_operation_t *operation,
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_update(
|
||||
mbedtls_transparent_test_driver_hash_operation_t *operation,
|
||||
const uint8_t *input,
|
||||
size_t input_length )
|
||||
{
|
||||
@ -618,8 +618,8 @@ psa_status_t test_transparent_hash_update(
|
||||
#endif
|
||||
}
|
||||
|
||||
psa_status_t test_transparent_hash_finish(
|
||||
test_transparent_hash_operation_t *operation,
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_finish(
|
||||
mbedtls_transparent_test_driver_hash_operation_t *operation,
|
||||
uint8_t *hash,
|
||||
size_t hash_size,
|
||||
size_t *hash_length )
|
||||
@ -639,8 +639,8 @@ psa_status_t test_transparent_hash_finish(
|
||||
#endif
|
||||
}
|
||||
|
||||
psa_status_t test_transparent_hash_abort(
|
||||
test_transparent_hash_operation_t *operation )
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_abort(
|
||||
mbedtls_transparent_test_driver_hash_operation_t *operation )
|
||||
{
|
||||
#if defined(INCLUDE_HASH_TEST_DRIVER)
|
||||
return( mbedtls_psa_hash_abort( &operation->operation ) );
|
||||
|
@ -278,9 +278,9 @@ psa_status_t mbedtls_psa_hash_abort(
|
||||
#if defined(PSA_CRYPTO_DRIVER_TEST)
|
||||
typedef struct {
|
||||
mbedtls_psa_hash_operation_t operation;
|
||||
} test_transparent_hash_operation_t;
|
||||
} mbedtls_transparent_test_driver_hash_operation_t;
|
||||
|
||||
psa_status_t test_transparent_hash_compute(
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_compute(
|
||||
psa_algorithm_t alg,
|
||||
const uint8_t *input,
|
||||
size_t input_length,
|
||||
@ -288,27 +288,27 @@ psa_status_t test_transparent_hash_compute(
|
||||
size_t hash_size,
|
||||
size_t *hash_length);
|
||||
|
||||
psa_status_t test_transparent_hash_setup(
|
||||
test_transparent_hash_operation_t *operation,
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_setup(
|
||||
mbedtls_transparent_test_driver_hash_operation_t *operation,
|
||||
psa_algorithm_t alg );
|
||||
|
||||
psa_status_t test_transparent_hash_clone(
|
||||
const test_transparent_hash_operation_t *source_operation,
|
||||
test_transparent_hash_operation_t *target_operation );
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_clone(
|
||||
const mbedtls_transparent_test_driver_hash_operation_t *source_operation,
|
||||
mbedtls_transparent_test_driver_hash_operation_t *target_operation );
|
||||
|
||||
psa_status_t test_transparent_hash_update(
|
||||
test_transparent_hash_operation_t *operation,
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_update(
|
||||
mbedtls_transparent_test_driver_hash_operation_t *operation,
|
||||
const uint8_t *input,
|
||||
size_t input_length );
|
||||
|
||||
psa_status_t test_transparent_hash_finish(
|
||||
test_transparent_hash_operation_t *operation,
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_finish(
|
||||
mbedtls_transparent_test_driver_hash_operation_t *operation,
|
||||
uint8_t *hash,
|
||||
size_t hash_size,
|
||||
size_t *hash_length );
|
||||
|
||||
psa_status_t test_transparent_hash_abort(
|
||||
test_transparent_hash_operation_t *operation );
|
||||
psa_status_t mbedtls_transparent_test_driver_hash_abort(
|
||||
mbedtls_transparent_test_driver_hash_operation_t *operation );
|
||||
|
||||
#endif /* PSA_CRYPTO_DRIVER_TEST */
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user