1 /* 2 * Copyright (c) 2021 Andes Technology Corporation 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 */ 6 7 /* 8 * Extra definitions required for CONFIG_RISCV_SOC_CONTEXT_SAVE. 9 */ 10 11 #ifndef SOC_RISCV_ANDES_V5_SOC_CONTEXT_H_ 12 #define SOC_RISCV_ANDES_V5_SOC_CONTEXT_H_ 13 14 #ifdef CONFIG_RISCV_SOC_CONTEXT_SAVE 15 16 /* Andes V5 specific registers. */ 17 #if defined(CONFIG_SOC_ANDES_V5_PFT) && defined(CONFIG_SOC_ANDES_V5_HWDSP) 18 #define SOC_ESF_MEMBERS \ 19 uint32_t mxstatus; \ 20 uint32_t ucode \ 21 22 #define SOC_ESF_INIT \ 23 0, \ 24 0 25 26 #elif defined(CONFIG_SOC_ANDES_V5_PFT) 27 #define SOC_ESF_MEMBERS \ 28 uint32_t mxstatus 29 30 #define SOC_ESF_INIT \ 31 0 32 33 #elif defined(CONFIG_SOC_ANDES_V5_HWDSP) 34 #define SOC_ESF_MEMBERS \ 35 uint32_t ucode 36 37 #define SOC_ESF_INIT \ 38 0 39 40 #endif 41 42 #endif /* CONFIG_RISCV_SOC_CONTEXT_SAVE */ 43 44 #endif /* SOC_RISCV_ANDES_V5_SOC_CONTEXT_H_ */ 45