1 /* SPDX-License-Identifier: BSD-2-Clause */ 2 /* 3 * Copyright (C) Foundries Ltd. 2020 - All Rights Reserved 4 * Author: Jorge Ramirez <jorge@foundries.io> 5 */ 6 7 #ifndef SE050_H_ 8 #define SE050_H_ 9 10 #include <fsl_sss_util_asn1_der.h> 11 #include <fsl_sss_se05x_apis.h> 12 #include <se05x_APDU.h> 13 #include <se050_sss_apis.h> 14 #include <se050_apdu_apis.h> 15 #include <se050_user_apis.h> 16 #include <se050_utils.h> 17 #include <tee_api_types.h> 18 #include <trace.h> 19 #include <util.h> 20 21 /* Supported Devices*/ 22 #define SE050A1_ID 0xA204 23 #define SE050A2_ID 0xA205 24 #define SE050B1_ID 0xA202 25 #define SE050B2_ID 0xA203 26 #define SE050C1_ID 0xA200 27 #define SE050C2_ID 0xA201 28 #define SE050DV_ID 0xA1F4 29 #define SE051A2_ID 0xA565 30 #define SE051C2_ID 0xA564 31 #define SE050F2_ID 0xA77E 32 #define SE050E_ID 0xA921 33 #define SE051A_ID 0xA920 34 #define SE051C_ID 0xA8FA 35 #define SE051W_ID 0xA739 36 #define SE050F_ID 0xA92A 37 38 TEE_Result se050_core_early_init(struct se050_scp_key *keys); 39 40 extern sss_se05x_key_store_t *se050_kstore; 41 extern sss_se05x_session_t *se050_session; 42 extern struct sss_se05x_ctx se050_ctx; 43 se050_get_oefid(void)44static inline uint32_t se050_get_oefid(void) 45 { 46 return SHIFT_U32(se050_ctx.se_info.oefid[0], 8) | 47 SHIFT_U32(se050_ctx.se_info.oefid[1], 0); 48 } 49 50 #endif /* SE050_H_ */ 51