From 3ad55cce8b8d59bcfd98a63d025ccca744d65acd Mon Sep 17 00:00:00 2001 From: Oleg Hahm Date: Wed, 14 Aug 2013 18:04:25 +0200 Subject: [PATCH] changed default stacksize * the default stacksize no longer set for a thread using printf * the stacksize for the main thread therefore adds the necessary space --- core/include/kernel.h | 2 +- cpu/lpc2387/include/cpu-conf.h | 2 +- cpu/mc1322x/include/cpu-conf.h | 4 +++- cpu/native/include/cpu-conf.h | 2 +- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/core/include/kernel.h b/core/include/kernel.h index ce94e20f6d..ae3ea892b0 100644 --- a/core/include/kernel.h +++ b/core/include/kernel.h @@ -60,7 +60,7 @@ * @brief Size of the main task's stack in bytes */ #ifndef KERNEL_CONF_STACKSIZE_MAIN -#define KERNEL_CONF_STACKSIZE_MAIN KERNEL_CONF_STACKSIZE_DEFAULT +#define KERNEL_CONF_STACKSIZE_MAIN (KERNEL_CONF_STACKSIZE_DEFAULT + KERNEL_CONF_STACKSIZE_PRINTF) #endif /** @} */ diff --git a/cpu/lpc2387/include/cpu-conf.h b/cpu/lpc2387/include/cpu-conf.h index 5d4defbce9..6071fcf658 100644 --- a/cpu/lpc2387/include/cpu-conf.h +++ b/cpu/lpc2387/include/cpu-conf.h @@ -56,7 +56,7 @@ License. See the file LICENSE in the top level directory for more details. #define KERNEL_CONF_STACKSIZE_PRINTF (4096) #ifndef KERNEL_CONF_STACKSIZE_DEFAULT -#define KERNEL_CONF_STACKSIZE_DEFAULT (KERNEL_CONF_STACKSIZE_PRINTF + 512) +#define KERNEL_CONF_STACKSIZE_DEFAULT (512) #endif #define KERNEL_CONF_STACKSIZE_IDLE (512) diff --git a/cpu/mc1322x/include/cpu-conf.h b/cpu/mc1322x/include/cpu-conf.h index 3c0540d304..423de61697 100644 --- a/cpu/mc1322x/include/cpu-conf.h +++ b/cpu/mc1322x/include/cpu-conf.h @@ -37,8 +37,10 @@ * @name Kernel configuration * @{ */ +#define KERNEL_CONF_STACKSIZE_PRINTF (4096) + #ifndef KERNEL_CONF_STACKSIZE_DEFAULT -#define KERNEL_CONF_STACKSIZE_DEFAULT 4500 +#define KERNEL_CONF_STACKSIZE_DEFAULT (512) #endif #define KERNEL_CONF_STACKSIZE_IDLE 500 diff --git a/cpu/native/include/cpu-conf.h b/cpu/native/include/cpu-conf.h index 56c695c210..337b38c0ca 100644 --- a/cpu/native/include/cpu-conf.h +++ b/cpu/native/include/cpu-conf.h @@ -27,7 +27,7 @@ #define TRANSCEIVER_STACK_SIZE (163840) #define MINIMUM_STACK_SIZE (163840) #else -#define KERNEL_CONF_STACKSIZE_DEFAULT (KERNEL_CONF_STACKSIZE_PRINTF + 8192) +#define KERNEL_CONF_STACKSIZE_DEFAULT (8192) #define KERNEL_CONF_STACKSIZE_IDLE (16384) #define NATIVE_ISR_STACKSIZE (16384) /* undefine the TRANSCEIVER_STACK_SIZE (2048 or 512) defined in transceiver.h */