From 86a276b5f3d9185db3430b91e646b334b7e20948 Mon Sep 17 00:00:00 2001 From: Martin Galvan Date: Fri, 19 Feb 2016 11:32:47 -0300 Subject: [PATCH] _ARMV7M_Is_vector_an_irq: Use ARMV7M_VECTOR_SYSTICK instead of hardcoded 16 Also add a comment explaining why we use that value. --- cpukit/score/cpu/arm/rtems/score/armv7m.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cpukit/score/cpu/arm/rtems/score/armv7m.h b/cpukit/score/cpu/arm/rtems/score/armv7m.h index 251ecdce39..0a69363c7f 100644 --- a/cpukit/score/cpu/arm/rtems/score/armv7m.h +++ b/cpukit/score/cpu/arm/rtems/score/armv7m.h @@ -386,7 +386,8 @@ typedef struct { static inline bool _ARMV7M_Is_vector_an_irq( int vector ) { - return vector >= 16; + /* External (i.e. non-system) IRQs start after the SysTick vector. */ + return vector > ARMV7M_VECTOR_SYSTICK; } static inline uint32_t _ARMV7M_Get_basepri(void)