Go to the documentation of this file.
14 #ifndef __ARCH_SPR_DEF_H__
15 #define __ARCH_SPR_DEF_H__
28 #if CONFIG_KERNEL_PL != 1 && CONFIG_KERNEL_PL != 2
29 #error CONFIG_KERNEL_PL must be 1 or 2
33 #define __concat4(a, b, c, d) a ## b ## c ## d
34 #define _concat4(a, b, c, d) __concat4(a, b, c, d)
40 #define SPR_INTERRUPT_MASK_K \
41 _concat4(SPR_INTERRUPT_MASK_, CONFIG_KERNEL_PL,,)
42 #define SPR_INTERRUPT_MASK_SET_K \
43 _concat4(SPR_INTERRUPT_MASK_SET_, CONFIG_KERNEL_PL,,)
44 #define SPR_INTERRUPT_MASK_RESET_K \
45 _concat4(SPR_INTERRUPT_MASK_RESET_, CONFIG_KERNEL_PL,,)
46 #define SPR_INTERRUPT_VECTOR_BASE_K \
47 _concat4(SPR_INTERRUPT_VECTOR_BASE_, CONFIG_KERNEL_PL,,)
49 #define SPR_IPI_MASK_K \
50 _concat4(SPR_IPI_MASK_, CONFIG_KERNEL_PL,,)
51 #define SPR_IPI_MASK_RESET_K \
52 _concat4(SPR_IPI_MASK_RESET_, CONFIG_KERNEL_PL,,)
53 #define SPR_IPI_MASK_SET_K \
54 _concat4(SPR_IPI_MASK_SET_, CONFIG_KERNEL_PL,,)
55 #define SPR_IPI_EVENT_K \
56 _concat4(SPR_IPI_EVENT_, CONFIG_KERNEL_PL,,)
57 #define SPR_IPI_EVENT_RESET_K \
58 _concat4(SPR_IPI_EVENT_RESET_, CONFIG_KERNEL_PL,,)
59 #define SPR_IPI_EVENT_SET_K \
60 _concat4(SPR_IPI_EVENT_SET_, CONFIG_KERNEL_PL,,)
62 _concat4(INT_IPI_, CONFIG_KERNEL_PL,,)
64 #define SPR_SINGLE_STEP_CONTROL_K \
65 _concat4(SPR_SINGLE_STEP_CONTROL_, CONFIG_KERNEL_PL,,)
66 #define SPR_SINGLE_STEP_EN_K_K \
67 _concat4(SPR_SINGLE_STEP_EN_, CONFIG_KERNEL_PL, _, CONFIG_KERNEL_PL)
68 #define INT_SINGLE_STEP_K \
69 _concat4(INT_SINGLE_STEP_, CONFIG_KERNEL_PL,,)
75 #define SPR_INTERRUPT_MASK_K_0 \
76 _concat4(SPR_INTERRUPT_MASK_, CONFIG_KERNEL_PL, _0,)
77 #define SPR_INTERRUPT_MASK_K_1 \
78 _concat4(SPR_INTERRUPT_MASK_, CONFIG_KERNEL_PL, _1,)
79 #define SPR_INTERRUPT_MASK_SET_K_0 \
80 _concat4(SPR_INTERRUPT_MASK_SET_, CONFIG_KERNEL_PL, _0,)
81 #define SPR_INTERRUPT_MASK_SET_K_1 \
82 _concat4(SPR_INTERRUPT_MASK_SET_, CONFIG_KERNEL_PL, _1,)
83 #define SPR_INTERRUPT_MASK_RESET_K_0 \
84 _concat4(SPR_INTERRUPT_MASK_RESET_, CONFIG_KERNEL_PL, _0,)
85 #define SPR_INTERRUPT_MASK_RESET_K_1 \
86 _concat4(SPR_INTERRUPT_MASK_RESET_, CONFIG_KERNEL_PL, _1,)
92 #define SPR_SYSTEM_SAVE_K_0 \
93 _concat4(SPR_SYSTEM_SAVE_, CONFIG_KERNEL_PL, _0,)
94 #define SPR_SYSTEM_SAVE_K_1 \
95 _concat4(SPR_SYSTEM_SAVE_, CONFIG_KERNEL_PL, _1,)
96 #define SPR_SYSTEM_SAVE_K_2 \
97 _concat4(SPR_SYSTEM_SAVE_, CONFIG_KERNEL_PL, _2,)
98 #define SPR_SYSTEM_SAVE_K_3 \
99 _concat4(SPR_SYSTEM_SAVE_, CONFIG_KERNEL_PL, _3,)
100 #define SPR_EX_CONTEXT_K_0 \
101 _concat4(SPR_EX_CONTEXT_, CONFIG_KERNEL_PL, _0,)
102 #define SPR_EX_CONTEXT_K_1 \
103 _concat4(SPR_EX_CONTEXT_, CONFIG_KERNEL_PL, _1,)
104 #define SPR_INTCTRL_K_STATUS \
105 _concat4(SPR_INTCTRL_, CONFIG_KERNEL_PL, _STATUS,)
106 #define INT_INTCTRL_K \
107 _concat4(INT_INTCTRL_, CONFIG_KERNEL_PL,,)