summaryrefslogtreecommitdiff
path: root/nuttx
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2015-04-12 06:30:24 -0600
committerGregory Nutt <gnutt@nuttx.org>2015-04-12 06:30:24 -0600
commit96e03d7f6c687e68710d856ecf9039ff1c4945b6 (patch)
tree09a8f3c0bae4270964ee050c80529a8a81328594 /nuttx
parenteda27996f4f72cea47cb4ac3a5e545a31743c26e (diff)
downloadpx4-nuttx-96e03d7f6c687e68710d856ecf9039ff1c4945b6.tar.gz
px4-nuttx-96e03d7f6c687e68710d856ecf9039ff1c4945b6.tar.bz2
px4-nuttx-96e03d7f6c687e68710d856ecf9039ff1c4945b6.zip
Add option to enable stackcheck per architecture
Diffstat (limited to 'nuttx')
-rw-r--r--nuttx/arch/arm/Kconfig3
-rw-r--r--nuttx/arch/arm/src/armv7-m/Kconfig6
2 files changed, 8 insertions, 1 deletions
diff --git a/nuttx/arch/arm/Kconfig b/nuttx/arch/arm/Kconfig
index b6ccafafd..dc32729a8 100644
--- a/nuttx/arch/arm/Kconfig
+++ b/nuttx/arch/arm/Kconfig
@@ -164,6 +164,7 @@ config ARCH_CHIP_SAM34
select ARCH_HAVE_CMNVECTOR
select ARCH_HAVE_MPU
select ARCH_HAVE_RAMFUNCS
+ select ARMV7M_HAVE_STACKCHECK
---help---
Atmel SAM3 (ARM Cortex-M3) and SAM4 (ARM Cortex-M4) architectures
@@ -174,6 +175,7 @@ config ARCH_CHIP_SAMV7
select ARCH_CORTEXM7
select ARCH_HAVE_MPU
select ARCH_HAVE_RAMFUNCS
+ select ARMV7M_HAVE_STACKCHECK
---help---
Atmel SAMV7 (ARM Cortex-M7) architectures
@@ -183,6 +185,7 @@ config ARCH_CHIP_STM32
select ARCH_HAVE_MPU
select ARCH_HAVE_I2CRESET
select ARCH_HAVE_HEAPCHECK
+ select ARMV7M_HAVE_STACKCHECK
---help---
STMicro STM32 architectures (ARM Cortex-M3/4).
diff --git a/nuttx/arch/arm/src/armv7-m/Kconfig b/nuttx/arch/arm/src/armv7-m/Kconfig
index a9274b28d..750229be1 100644
--- a/nuttx/arch/arm/src/armv7-m/Kconfig
+++ b/nuttx/arch/arm/src/armv7-m/Kconfig
@@ -106,10 +106,14 @@ config ARMV7M_OABI_TOOLCHAIN
Most of the older buildroot toolchains are OABI and are named
arm-nuttx-elf- vs. arm-nuttx-eabi-
+config ARMV7M_HAVE_STACKCHECK
+ bool
+ default n
+
config ARMV7M_STACKCHECK
bool "Check for stack overflow on each function call"
default n
- depends on ARCH_CHIP_STM32
+ depends on ARMV7M_HAVE_STACKCHECK
---help---
This check uses R10 to check for a stack overflow within each function
call. This has performances and code size impacts, but it will be able to