xref: /rk3399_ARM-atf/plat/arm/board/automotive_rd/platform/rd1ae/rd1ae_tbb.c (revision 26467bf3ec8c4f72c7a1f7b2f420caa6426f3658)
1 /*
2  * Copyright (c) 2024, ARM Limited. All rights reserved.
3  *
4  * SPDX-License-Identifier: BSD-3-Clause
5  */
6 
7 #include <plat/arm/common/plat_arm.h>
8 
plat_get_mbedtls_heap(void ** heap_addr,size_t * heap_size)9 int plat_get_mbedtls_heap(void **heap_addr, size_t *heap_size)
10 {
11 	assert(heap_addr != NULL);
12 	assert(heap_size != NULL);
13 
14 	return arm_get_mbedtls_heap(heap_addr, heap_size);
15 }
16 
17 /*
18  * Return the ROTPK hash in the following ASN.1 structure in DER format:
19  *
20  * AlgorithmIdentifier  ::=  SEQUENCE  {
21  *     algorithm       OBJECT IDENTIFIER,
22  *     parameters      ANY DEFINED BY algorithm OPTIONAL
23  * }
24  *
25  * DigestInfo ::= SEQUENCE {
26  *     digestAlgorithm AlgorithmIdentifier,
27  *     digest          OCTET STRING
28  * }
29  */
plat_get_rotpk_info(void * cookie,void ** key_ptr,unsigned int * key_len,unsigned int * flags)30 int plat_get_rotpk_info(void *cookie, void **key_ptr, unsigned int *key_len,
31 			unsigned int *flags)
32 {
33 	return arm_get_rotpk_info(cookie, key_ptr, key_len, flags);
34 }
35