mirror of https://github.com/ARMmbed/mbed-os.git
NUVOTON: Fix for target.boot-stack-size config in linker script (#351)
"target.boot-stack-size" can expand to MBED_CONF_TARGET_BOOT_STACK_SIZE or legacy MBED_BOOT_STACK_SIZE. Though MBED_BOOT_STACK_SIZE is unsupported in Mbed CE, make its preprocess consistent in linker scripts by prioritizing MBED_CONF_TARGET_BOOT_STACK_SIZE, then MBED_BOOT_STACK_SIZE for being compatible.pull/15530/head
parent
cfee81c7ce
commit
037fe9b619
|
@ -20,8 +20,12 @@
|
|||
|
||||
#include "../partition_M2354_mem.h"
|
||||
|
||||
#if !defined(MBED_BOOT_STACK_SIZE)
|
||||
#define MBED_BOOT_STACK_SIZE 0x400
|
||||
#if !defined(MBED_CONF_TARGET_BOOT_STACK_SIZE)
|
||||
# if defined(MBED_BOOT_STACK_SIZE)
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE MBED_BOOT_STACK_SIZE
|
||||
# else
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# endif
|
||||
#endif
|
||||
|
||||
LR_IROM1 MBED_APP_START
|
||||
|
@ -34,7 +38,7 @@ LR_IROM1 MBED_APP_START
|
|||
.ANY (+RO)
|
||||
}
|
||||
|
||||
ARM_LIB_STACK MBED_RAM_APP_START EMPTY MBED_BOOT_STACK_SIZE
|
||||
ARM_LIB_STACK MBED_RAM_APP_START EMPTY MBED_CONF_TARGET_BOOT_STACK_SIZE
|
||||
{
|
||||
}
|
||||
|
||||
|
|
|
@ -22,11 +22,15 @@
|
|||
|
||||
#include "../partition_M2354_mem.h"
|
||||
|
||||
#if !defined(MBED_BOOT_STACK_SIZE)
|
||||
#define MBED_BOOT_STACK_SIZE 0x400
|
||||
#if !defined(MBED_CONF_TARGET_BOOT_STACK_SIZE)
|
||||
# if defined(MBED_BOOT_STACK_SIZE)
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE MBED_BOOT_STACK_SIZE
|
||||
# else
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# endif
|
||||
#endif
|
||||
|
||||
StackSize = MBED_BOOT_STACK_SIZE;
|
||||
StackSize = MBED_CONF_TARGET_BOOT_STACK_SIZE;
|
||||
|
||||
MEMORY
|
||||
{
|
||||
|
|
|
@ -21,7 +21,11 @@
|
|||
#include "../M251_mem.h"
|
||||
|
||||
#if !defined(MBED_CONF_TARGET_BOOT_STACK_SIZE)
|
||||
#define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# if defined(MBED_BOOT_STACK_SIZE)
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE MBED_BOOT_STACK_SIZE
|
||||
# else
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# endif
|
||||
#endif
|
||||
|
||||
StackSize = MBED_CONF_TARGET_BOOT_STACK_SIZE;
|
||||
|
|
|
@ -23,7 +23,11 @@
|
|||
#include "../M261_mem.h"
|
||||
|
||||
#if !defined(MBED_CONF_TARGET_BOOT_STACK_SIZE)
|
||||
#define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# if defined(MBED_BOOT_STACK_SIZE)
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE MBED_BOOT_STACK_SIZE
|
||||
# else
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# endif
|
||||
#endif
|
||||
|
||||
M_CRASH_DATA_RAM_SIZE = 0x100;
|
||||
|
|
|
@ -23,7 +23,11 @@
|
|||
#include "../M451_mem.h"
|
||||
|
||||
#if !defined(MBED_CONF_TARGET_BOOT_STACK_SIZE)
|
||||
#define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# if defined(MBED_BOOT_STACK_SIZE)
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE MBED_BOOT_STACK_SIZE
|
||||
# else
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# endif
|
||||
#endif
|
||||
|
||||
StackSize = MBED_CONF_TARGET_BOOT_STACK_SIZE;
|
||||
|
|
|
@ -22,8 +22,12 @@
|
|||
|
||||
#include "../M460_mem.h"
|
||||
|
||||
#if !defined(MBED_BOOT_STACK_SIZE)
|
||||
#define MBED_BOOT_STACK_SIZE 0x400
|
||||
#if !defined(MBED_CONF_TARGET_BOOT_STACK_SIZE)
|
||||
# if defined(MBED_BOOT_STACK_SIZE)
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE MBED_BOOT_STACK_SIZE
|
||||
# else
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#if !defined(NU_HYPERRAM_START)
|
||||
|
@ -35,7 +39,7 @@
|
|||
#endif
|
||||
|
||||
M_CRASH_DATA_RAM_SIZE = 0x100;
|
||||
StackSize = MBED_BOOT_STACK_SIZE;
|
||||
StackSize = MBED_CONF_TARGET_BOOT_STACK_SIZE;
|
||||
|
||||
MEMORY
|
||||
{
|
||||
|
|
|
@ -23,7 +23,11 @@
|
|||
#include "../M480_mem.h"
|
||||
|
||||
#if !defined(MBED_CONF_TARGET_BOOT_STACK_SIZE)
|
||||
#define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# if defined(MBED_BOOT_STACK_SIZE)
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE MBED_BOOT_STACK_SIZE
|
||||
# else
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# endif
|
||||
#endif
|
||||
|
||||
M_CRASH_DATA_RAM_SIZE = 0x100;
|
||||
|
|
|
@ -23,7 +23,11 @@
|
|||
#include "../NANO100_mem.h"
|
||||
|
||||
#if !defined(MBED_CONF_TARGET_BOOT_STACK_SIZE)
|
||||
#define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# if defined(MBED_BOOT_STACK_SIZE)
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE MBED_BOOT_STACK_SIZE
|
||||
# else
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# endif
|
||||
#endif
|
||||
|
||||
StackSize = MBED_CONF_TARGET_BOOT_STACK_SIZE;
|
||||
|
|
|
@ -11,7 +11,11 @@
|
|||
#endif
|
||||
|
||||
#if !defined(MBED_CONF_TARGET_BOOT_STACK_SIZE)
|
||||
#define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# if defined(MBED_BOOT_STACK_SIZE)
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE MBED_BOOT_STACK_SIZE
|
||||
# else
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# endif
|
||||
#endif
|
||||
|
||||
M_CRASH_DATA_RAM_SIZE = 0x100;
|
||||
|
|
|
@ -11,7 +11,11 @@
|
|||
#endif
|
||||
|
||||
#if !defined(MBED_CONF_TARGET_BOOT_STACK_SIZE)
|
||||
#define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# if defined(MBED_BOOT_STACK_SIZE)
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE MBED_BOOT_STACK_SIZE
|
||||
# else
|
||||
# define MBED_CONF_TARGET_BOOT_STACK_SIZE 0x400
|
||||
# endif
|
||||
#endif
|
||||
|
||||
M_CRASH_DATA_RAM_SIZE = 0x100;
|
||||
|
|
Loading…
Reference in New Issue