1 /* SPDX-License-Identifier: BSD-2-Clause */
2 /*
3  * Copyright (c) 2014, STMicroelectronics International N.V.
4  */
5 #ifndef TEE_COMMON_OTP_H
6 #define TEE_COMMON_OTP_H
7 
8 #include <stddef.h>
9 #include <stdint.h>
10 #include <string.h>
11 #include <tee_api_types.h>
12 #include <utee_defines.h>
13 
14 struct tee_hw_unique_key {
15 	uint8_t data[HW_UNIQUE_KEY_LENGTH];
16 };
17 
18 TEE_Result tee_otp_get_hw_unique_key(struct tee_hw_unique_key *hwkey);
19 int tee_otp_get_die_id(uint8_t *buffer, size_t len);
20 TEE_Result tee_otp_get_ta_enc_key(uint32_t key_type, uint8_t *buffer,
21 				  size_t len);
22 
23 #endif /* TEE_COMMON_OTP_H */
24