diff options
Diffstat (limited to 'utility/rtos_compatibility_layers/FreeRTOS/FreeRTOS.h')
| -rw-r--r-- | utility/rtos_compatibility_layers/FreeRTOS/FreeRTOS.h | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/utility/rtos_compatibility_layers/FreeRTOS/FreeRTOS.h b/utility/rtos_compatibility_layers/FreeRTOS/FreeRTOS.h index b5bda820..ccf0a84d 100644 --- a/utility/rtos_compatibility_layers/FreeRTOS/FreeRTOS.h +++ b/utility/rtos_compatibility_layers/FreeRTOS/FreeRTOS.h @@ -23,7 +23,9 @@ /* DATE NAME DESCRIPTION */ /* */ /* 09-30-2020 William E. Lamie Initial Version 6.1 */ -/* */ +/* 03-02-2021 Andres Mlinar Modified comment(s), fixed */ +/* interrupt macros, */ +/* resulting in version 6.1.5 */ /**************************************************************************/ #ifndef FREERTOS_H @@ -290,11 +292,29 @@ void vPortExitCritical(void); #endif #ifndef portDISABLE_INTERRUPTS +#if defined(__IAR_SYSTEMS_ICC__) #define portDISABLE_INTERRUPTS() __disable_interrupt() +#elif defined(__GNUC__ ) +#define portDISABLE_INTERRUPTS() __disable_interrupts() +#elif defined(__ARMCC_VERSION) +#define portDISABLE_INTERRUPTS() __disable_irq() +#else +UINT _tx_thread_interrupt_disable(VOID); +#define portDISABLE_INTERRUPTS() _tx_thread_interrupt_disable() +#endif #endif #ifndef portENABLE_INTERRUPTS +#if defined(__IAR_SYSTEMS_ICC__) #define portENABLE_INTERRUPTS() __enable_interrupt() +#elif defined(__GNUC__ ) +#define portENABLE_INTERRUPTS() __enable_interrupts() +#elif defined(__ARMCC_VERSION) +#define portENABLE_INTERRUPTS() __enable_irq() +#else +VOID _tx_thread_interrupt_restore(UINT previous_posture); +#define portENABLE_INTERRUPTS() _tx_thread_interrupt_restore(TX_INT_ENABLE) +#endif #endif #define taskENTER_CRITICAL() portENTER_CRITICAL() |
