From 5e23617c9107eb4d1a2c3dcc34e73e8a9d6c1f8e Mon Sep 17 00:00:00 2001 From: succi <45762837+muaxiaohei@users.noreply.github.com> Date: Mon, 3 Jul 2023 16:30:48 +0800 Subject: [PATCH] Update perf_os_patch_threadx.c Add the macro TX_EXECUTION_PROFILE_ENABLE to perf_os_patch_threadx.c --- os/perf_os_patch_threadx.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/os/perf_os_patch_threadx.c b/os/perf_os_patch_threadx.c index eb417bd..dcb694e 100644 --- a/os/perf_os_patch_threadx.c +++ b/os/perf_os_patch_threadx.c @@ -44,9 +44,10 @@ #define ORIG_FUNC(__NAME) __ORIG_FUNC(__NAME) -#ifndef TX_ENABLE_EXECUTION_CHANGE_NOTIFY -#error In order to use perf_counter:ThreadX-Patch, please define\ - TX_ENABLE_EXECUTION_CHANGE_NOTIFY in the project configuration.\ +#if defined(TX_ENABLE_EXECUTION_CHANGE_NOTIFY) && defined(TX_EXECUTION_PROFILE_ENABLE) +#error In order to use perf_counter:ThreadX-Patch, please define \ + TX_ENABLE_EXECUTION_CHANGE_NOTIFY or TX_EXECUTION_PROFILE_ENABLE \ + in the project configuration, according to the version of thread.\ If you don't want to use this patch, please un-select it in RTE\ or remove this patch from the compilation. #endif