From 7632f628d7b336c51a6fd396fc088630f1babea0 Mon Sep 17 00:00:00 2001 From: Jaeden Amero Date: Fri, 26 Oct 2018 11:26:45 +0100 Subject: [PATCH] psa: driver: Prefix "encrypt or decrypt" type The driver model's "encrypt or decrypt" type, encrypt_or_decrypt_t, is publicly exposed and needs to have a `psa_` prefix in order to properly communicate that it is part of the PSA driver model. --- include/psa/crypto_driver.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/psa/crypto_driver.h b/include/psa/crypto_driver.h index 9acd33066c..25cbf3ed45 100644 --- a/include/psa/crypto_driver.h +++ b/include/psa/crypto_driver.h @@ -37,7 +37,7 @@ */ typedef uint32_t psa_status_t; typedef uint32_t psa_algorithm_t; -typedef uint8_t encrypt_or_decrypt_t; +typedef uint8_t psa_encrypt_or_decrypt_t; typedef uint32_t psa_key_slot_t; typedef uint32_t psa_key_type_t; typedef uint32_t psa_key_usage_t; @@ -477,7 +477,7 @@ typedef psa_status_t (*psa_drv_mac_transparent_verify_t)(const uint8_t *p_input, typedef psa_status_t (*psa_drv_cipher_opaque_setup_t)(void *p_context, psa_key_slot_t key_slot, psa_algorithm_t algorithm, - encrypt_or_decrypt_t direction); + psa_encrypt_or_decrypt_t direction); /** \brief A function pointer that sets the initialization vector (if * necessary) for an opaque cipher operation @@ -574,7 +574,7 @@ typedef psa_status_t (*psa_drv_cipher_opaque_abort_t)(void *p_context); */ typedef psa_status_t (*psa_drv_cipher_opaque_ecb_t)(psa_key_slot_t key_slot, psa_algorithm_t algorithm, - encrypt_or_decrypt_t direction, + psa_encrypt_or_decrypt_t direction, const uint8_t *p_input, size_t input_size, uint8_t *p_output, @@ -664,7 +664,7 @@ typedef struct psa_drv_cipher_transparent_context_s psa_drv_cipher_transparent_c * \retval PSA_SUCCESS */ typedef psa_status_t (*psa_drv_cipher_transparent_setup_t)(psa_drv_cipher_transparent_context_t *p_context, - encrypt_or_decrypt_t direction, + psa_encrypt_or_decrypt_t direction, const uint8_t *p_key_data, size_t key_data_size);