From ca4bb1ffb465e00cbf0212cb1250e4fcbdd599b5 Mon Sep 17 00:00:00 2001 From: Igor Kotrasinski Date: Tue, 17 Apr 2018 11:46:11 +0200 Subject: [PATCH] Restore tee_internal_api.h constness The specification uses a [ctx] specifier, which should, but is not required to use const. Revert to using const to match existing code use cases. Change-Id: Ied65fb18e0e5f7fd32cd5a5219fb5ccaf2895e21 Signed-off-by: Igor Kotrasinski --- helloworld/ta/hello_world.c | 4 ++-- include/include/tee_internal_api.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/helloworld/ta/hello_world.c b/helloworld/ta/hello_world.c index c2ebc3d..9f8c65b 100644 --- a/helloworld/ta/hello_world.c +++ b/helloworld/ta/hello_world.c @@ -61,7 +61,7 @@ TEE_Result TA_OpenSessionEntryPoint(uint32_t param_types, return TEE_SUCCESS; } -void TA_CloseSessionEntryPoint(void *sess_ctx) +void TA_CloseSessionEntryPoint(const void *sess_ctx) { (void)&sess_ctx; LOG_FUNC(); @@ -86,7 +86,7 @@ static TEE_Result inc_value(uint32_t param_types, return TEE_SUCCESS; } -TEE_Result TA_InvokeCommandEntryPoint(void *sess_ctx, +TEE_Result TA_InvokeCommandEntryPoint(const void *sess_ctx, uint32_t cmd_id, uint32_t param_types, TEE_Param params[4]) diff --git a/include/include/tee_internal_api.h b/include/include/tee_internal_api.h index f6c1b1c..b43b487 100644 --- a/include/include/tee_internal_api.h +++ b/include/include/tee_internal_api.h @@ -280,7 +280,7 @@ TEE_Result TA_EXPORT TA_OpenSessionEntryPoint(uint32_t paramTypes, * @return his function can return no success or error code. * */ -void TA_EXPORT TA_CloseSessionEntryPoint(void* sessionContext); +void TA_EXPORT TA_CloseSessionEntryPoint(const void* sessionContext); /** * Invokes a command within the given sessionContext @@ -308,7 +308,7 @@ void TA_EXPORT TA_CloseSessionEntryPoint(void* sessionContext); * itself. In any case, the Implementation reports the error code to the client * with the origin @ref TEEC_ORIGIN_TRUSTED_APP. */ -TEE_Result TA_EXPORT TA_InvokeCommandEntryPoint(void* sessionContext, +TEE_Result TA_EXPORT TA_InvokeCommandEntryPoint(const void* sessionContext, uint32_t commandID, uint32_t paramTypes, TEE_Param params[4]); -- 2.34.1