From 8b4b48e74c174957a2dddc8abb3a20633cc48bc5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bora=20=C3=96zgen?= Date: Wed, 23 Jun 2021 14:38:35 +0200 Subject: [PATCH] RTOS: Add configuration to enable RTX events --- cmsis/device/rtos/include/mbed_rtx_conf.h | 4 ++++ cmsis/device/rtos/mbed_lib.json | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/cmsis/device/rtos/include/mbed_rtx_conf.h b/cmsis/device/rtos/include/mbed_rtx_conf.h index 1ea84140a0..5ccb3dcf87 100644 --- a/cmsis/device/rtos/include/mbed_rtx_conf.h +++ b/cmsis/device/rtos/include/mbed_rtx_conf.h @@ -159,6 +159,8 @@ //#define EVR_RTX_MEMORY_POOL_ERROR_DISABLE //#define EVR_RTX_MESSAGE_QUEUE_ERROR_DISABLE +#if !MBED_CONF_RTOS_ENABLE_ALL_RTX_EVENTS + //Following events are NOT used by Mbed-OS, you may enable them if needed for debug purposes #define EVR_RTX_MEMORY_INIT_DISABLE #define EVR_RTX_MEMORY_ALLOC_DISABLE @@ -320,4 +322,6 @@ #define EVR_RTX_MESSAGE_QUEUE_DELETE_DISABLE #define EVR_RTX_MESSAGE_QUEUE_DESTROYED_DISABLE +#endif /* !MBED_CONF_RTOS_ENABLE_ALL_RTX_EVENTS */ + #endif /* MBED_RTX_CONF_H */ diff --git a/cmsis/device/rtos/mbed_lib.json b/cmsis/device/rtos/mbed_lib.json index b1e1a7e0f6..231ee3c075 100644 --- a/cmsis/device/rtos/mbed_lib.json +++ b/cmsis/device/rtos/mbed_lib.json @@ -57,6 +57,10 @@ "msgqueue-data-size": { "help": "The total memory available for all CMSIS-RTOSv2 object-pool message queues combined", "value": 0 + }, + "enable-all-rtx-events": { + "help": "Enables all of the RTX events which are disabled by default for optimization", + "value": false } }, "macros": ["_RTE_"],