Etienne Carriere | 7514117 | 2020-05-16 11:58:23 +0200 | [diff] [blame] | 1 | // SPDX-License-Identifier: BSD-2-Clause |
Pascal Brand | c639ac8 | 2015-07-02 08:53:34 +0200 | [diff] [blame] | 2 | /* |
| 3 | * Copyright (c) 2014, STMicroelectronics International N.V. |
| 4 | * All rights reserved. |
Pascal Brand | c639ac8 | 2015-07-02 08:53:34 +0200 | [diff] [blame] | 5 | */ |
| 6 | |
| 7 | #include <tee_ta_api.h> |
| 8 | #include <user_ta_header_defines.h> |
| 9 | |
| 10 | /* |
| 11 | * Trusted Application Entry Points |
| 12 | */ |
| 13 | |
| 14 | /* Called each time a new instance is created */ |
| 15 | TEE_Result TA_CreateEntryPoint(void) |
| 16 | { |
| 17 | return TEE_ERROR_GENERIC; |
| 18 | } |
| 19 | |
| 20 | /* Called each time an instance is destroyed */ |
| 21 | void TA_DestroyEntryPoint(void) |
| 22 | { |
| 23 | } |
| 24 | |
| 25 | /* Called each time a session is opened */ |
| 26 | TEE_Result TA_OpenSessionEntryPoint(uint32_t nParamTypes, |
| 27 | TEE_Param pParams[4], |
| 28 | void **ppSessionContext) |
| 29 | { |
| 30 | (void)nParamTypes; |
| 31 | (void)pParams; |
| 32 | (void)ppSessionContext; |
| 33 | return TEE_SUCCESS; |
| 34 | } |
| 35 | |
| 36 | /* Called each time a session is closed */ |
| 37 | void TA_CloseSessionEntryPoint(void *pSessionContext) |
| 38 | { |
| 39 | (void)pSessionContext; |
| 40 | } |
| 41 | |
| 42 | /* Called when a command is invoked */ |
| 43 | TEE_Result TA_InvokeCommandEntryPoint(void *pSessionContext, |
| 44 | uint32_t nCommandID, |
| 45 | uint32_t nParamTypes, |
| 46 | TEE_Param pParams[4]) |
| 47 | { |
| 48 | (void)pSessionContext; |
| 49 | (void)nCommandID; |
| 50 | (void)nParamTypes; |
| 51 | (void)pParams; |
| 52 | return TEE_ERROR_NOT_SUPPORTED; |
| 53 | } |