Skip to content

Commit a3d06c6

Browse files
qiujiandong裘剑东
authored andcommitted
NMSIS/Core: remove volatile restriction on a local variable
The `volatle` restriction is unnecessary for the `vec_base` local variable. Signed-off-by: qiujiandong <qiujiandong@nucleisys.com>
1 parent fcf2a1b commit a3d06c6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

NMSIS/Core/Include/core_feature_eclic.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -771,7 +771,7 @@ __STATIC_INLINE uint8_t __ECLIC_GetPriorityIRQ(IRQn_Type IRQn)
771771
*/
772772
__STATIC_INLINE void __ECLIC_SetVector(IRQn_Type IRQn, rv_csr_t vector)
773773
{
774-
volatile unsigned long vec_base;
774+
unsigned long vec_base;
775775
vec_base = ((unsigned long)__RV_CSR_READ(CSR_MTVT));
776776
vec_base += ((unsigned long)IRQn) * sizeof(unsigned long);
777777
(* (unsigned long *) vec_base) = vector;

0 commit comments

Comments
 (0)