1 /* SPDX-License-Identifier: Apache-2.0 */ 2 /* 3 * Copyright 2018 Broadcom. 4 */ 5 6 #include <zephyr/device.h> 7 #include <zephyr/init.h> 8 #include <soc.h> 9 #include <zephyr/arch/cpu.h> 10 #include <zephyr/irq.h> 11 12 /** 13 * @brief Perform basic hardware initialization at boot. 14 * 15 * This needs to be run from the very beginning. 16 * So the init priority has to be 0 (zero). 17 * 18 * @return 0 19 */ valkyrie_init(void)20static int valkyrie_init(void) 21 { 22 uint32_t key; 23 24 25 key = irq_lock(); 26 27 NMI_INIT(); 28 29 irq_unlock(key); 30 31 return 0; 32 } 33 34 SYS_INIT(valkyrie_init, PRE_KERNEL_1, 0); 35