diff options
Diffstat (limited to 'os/rt')
-rw-r--r-- | os/rt/ports/ARMCMx/chcore_v7m.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/os/rt/ports/ARMCMx/chcore_v7m.h b/os/rt/ports/ARMCMx/chcore_v7m.h index ab6cf28b9..ed78d1bce 100644 --- a/os/rt/ports/ARMCMx/chcore_v7m.h +++ b/os/rt/ports/ARMCMx/chcore_v7m.h @@ -456,7 +456,17 @@ static inline bool port_is_isr_context(void) { static inline void port_lock(void) {
#if CORTEX_SIMPLIFIED_PRIORITY == FALSE
+#if defined(__CM7_REV)
+#if __CM7_REV == 0
+ __disable_irq();
+#endif
+#endif
__set_BASEPRI(CORTEX_BASEPRI_KERNEL);
+#if defined(__CM7_REV)
+#if __CM7_REV == 0
+ __enable_irq();
+#endif
+#endif
#else /* CORTEX_SIMPLIFIED_PRIORITY */
__disable_irq();
#endif /* CORTEX_SIMPLIFIED_PRIORITY */
|