1 /* 2 * Copyright (c) 2023 Nordic Semiconductor ASA 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6 7 #include <stddef.h> 8 #include "NHW_config.h" 9 10 /* 11 * Get the name of a core/domain 12 * 13 * Only for debugging/logging/tracing purposes. 14 */ nhw_get_core_name(unsigned int core_n)15const char *nhw_get_core_name(unsigned int core_n) 16 { 17 static const char *corenames[NHW_INTCTRL_TOTAL_INST] = NHW_CORE_NAMES; 18 19 if (core_n < sizeof(corenames)/sizeof(corenames[0])) { 20 return corenames[core_n]; 21 } else { 22 return NULL; 23 } 24 } 25