RTOS: Allow per target definition of OS_IDLE_THREAD_STACK_SIZE.

The stack required for the idle thread is highly dependent on the
target because it will call the sleep function which is target
specific.

While 256 bytes of stack is enough for most targets, others like the
NRF52840 might require more.

With this change, target maintainers can specify the idle thread stack
size in their mbed_rtx.h file.
pull/4563/head
Vincent Coubard 2017-06-16 10:11:12 +01:00
parent fc18250b1f
commit fd7eff202c
1 changed files with 3 additions and 1 deletions

View File

@ -32,7 +32,9 @@
#define OS_STACK_SIZE MBED_CONF_APP_THREAD_STACK_SIZE
#define OS_TIMER_THREAD_STACK_SIZE 768
#define OS_IDLE_THREAD_STACK_SIZE 512
#ifndef OS_IDLE_THREAD_STACK_SIZE
#define OS_IDLE_THREAD_STACK_SIZE 256
#endif
#define OS_DYNAMIC_MEM_SIZE 0