diff options
| author | zhkag <[email protected]> | 2023-09-20 13:15:32 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2023-09-20 13:15:32 +0800 |
| commit | d75090dd16927f03e8dc0fd8241961aeb126d01c (patch) | |
| tree | 00713e4c6e81d8d7597453e3eb6608072149aee5 | |
| parent | 35e4baa786270988f3a9a7570ef40e7512d146fa (diff) | |
[utest] 更改 thread_tc 线程栈的大小,避免 64 位机器导致的栈异常 (#8057)
| -rw-r--r-- | examples/utest/testcases/kernel/thread_tc.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/examples/utest/testcases/kernel/thread_tc.c b/examples/utest/testcases/kernel/thread_tc.c index 74634adcc6..8cc0a9176f 100644 --- a/examples/utest/testcases/kernel/thread_tc.c +++ b/examples/utest/testcases/kernel/thread_tc.c @@ -13,7 +13,7 @@ #include <stdlib.h> #include "utest.h" -#define THREAD_STACK_SIZE 512 +#define THREAD_STACK_SIZE UTEST_THR_STACK_SIZE #define THREAD_TIMESLICE 10 rt_align(RT_ALIGN_SIZE) @@ -35,12 +35,12 @@ static volatile rt_uint32_t tid6_finish_flag = 0; static volatile rt_uint32_t thread5_source = 0; #ifndef RT_USING_SMP - static rt_uint32_t thread_yield_flag = 0; + static volatile rt_uint32_t thread_yield_flag = 0; #endif -static rt_uint32_t entry_idle_hook_times = 0; +static volatile rt_uint32_t entry_idle_hook_times = 0; static rt_thread_t __current_thread; static rt_uint8_t change_priority; -static rt_uint32_t count = 0; +static volatile rt_uint32_t count = 0; void thread1_entry(void *param) { |
