1 /* 2 * Copyright (c) 2024, Arm Limited and Contributors. All rights reserved. 3 * 4 * SPDX-License-Identifier: BSD-3-Clause 5 */ 6 7 #include <errno.h> 8 #include <stdint.h> 9 10 #include <cca_attestation.h> 11 #include <common/debug.h> 12 #include <psa/error.h> 13 plat_rmmd_get_cca_realm_attest_key(uintptr_t buf,size_t * len,unsigned int type)14int plat_rmmd_get_cca_realm_attest_key(uintptr_t buf, size_t *len, 15 unsigned int type) 16 { 17 psa_status_t ret; 18 19 ret = cca_attestation_get_realm_key(buf, len, type); 20 if (ret != PSA_SUCCESS) { 21 ERROR("Unable to fetch CCA attestation key\n"); 22 return -1; 23 } 24 25 return 0; 26 } 27