Bryan O'Donoghue | 59ca2f6 | 2018-10-26 14:19:43 +0100 | [diff] [blame] | 1 | /* |
Ambroise Vincent | d207f56 | 2019-04-10 12:50:27 +0100 | [diff] [blame] | 2 | * Copyright (c) 2018-2019, ARM Limited and Contributors. All rights reserved. |
Bryan O'Donoghue | 59ca2f6 | 2018-10-26 14:19:43 +0100 | [diff] [blame] | 3 | * |
| 4 | * SPDX-License-Identifier: BSD-3-Clause |
| 5 | */ |
| 6 | |
| 7 | #include <plat/common/platform.h> |
| 8 | |
Jun Nie | 8cfd4b5 | 2019-06-13 11:38:24 +0800 | [diff] [blame] | 9 | extern char imx7_rotpk_hash[], imx7_rotpk_hash_end[]; |
Bryan O'Donoghue | 59ca2f6 | 2018-10-26 14:19:43 +0100 | [diff] [blame] | 10 | |
| 11 | int plat_get_rotpk_info(void *cookie, void **key_ptr, unsigned int *key_len, |
| 12 | unsigned int *flags) |
| 13 | { |
Jun Nie | 8cfd4b5 | 2019-06-13 11:38:24 +0800 | [diff] [blame] | 14 | *key_ptr = imx7_rotpk_hash; |
| 15 | *key_len = imx7_rotpk_hash_end - imx7_rotpk_hash; |
Bryan O'Donoghue | 59ca2f6 | 2018-10-26 14:19:43 +0100 | [diff] [blame] | 16 | *flags = ROTPK_IS_HASH; |
| 17 | |
| 18 | return 0; |
| 19 | } |
| 20 | |
| 21 | int plat_get_nv_ctr(void *cookie, unsigned int *nv_ctr) |
| 22 | { |
| 23 | *nv_ctr = 0; |
| 24 | |
| 25 | return 0; |
| 26 | } |
| 27 | |
| 28 | int plat_set_nv_ctr(void *cookie, unsigned int nv_ctr) |
| 29 | { |
| 30 | return 1; |
| 31 | } |
Ambroise Vincent | d207f56 | 2019-04-10 12:50:27 +0100 | [diff] [blame] | 32 | |
| 33 | int plat_get_mbedtls_heap(void **heap_addr, size_t *heap_size) |
| 34 | { |
| 35 | return get_mbedtls_heap_helper(heap_addr, heap_size); |
| 36 | } |