Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FreeRTOS/FreeRTOS-Kernel.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIsaacDynamo <61521674+IsaacDynamo@users.noreply.github.com>2024-01-18 22:02:41 +0300
committerGitHub <noreply@github.com>2024-01-18 22:02:41 +0300
commitaa07289c24dd631a7d3d55781a9c5fa9017d5db8 (patch)
tree38bfbd7d4f109b40ae52efd68834d2e838d96400
parentc083af972ab1172aa09938e910ed9451053a9fcf (diff)
Make configSUPPORT_STATIC_ALLOCATION==1 an error for MPU ports (#953)
* Error when configSUPPORT_STATIC_ALLOCATION is set for MPU ports * Uncrustify: triggered by comment. --------- Co-authored-by: GitHub Action <action@github.com> Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
-rw-r--r--tasks.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/tasks.c b/tasks.c
index 93e9c02c4..d00e96674 100644
--- a/tasks.c
+++ b/tasks.c
@@ -41,6 +41,13 @@
#include "timers.h"
#include "stack_macros.h"
+/* The default definitions are only available for non-MPU ports. The
+ * reason is that the stack alignment requirements vary for different
+ * architectures.*/
+#if ( ( configSUPPORT_STATIC_ALLOCATION == 1 ) && ( configKERNEL_PROVIDED_STATIC_MEMORY == 1 ) && ( portUSING_MPU_WRAPPERS != 0 ) )
+ #error configKERNEL_PROVIDED_STATIC_MEMORY cannot be set to 1 when using an MPU port. The vApplicationGet*TaskMemory() functions must be provided manually.
+#endif
+
/* The MPU ports require MPU_WRAPPERS_INCLUDED_FROM_API_FILE to be defined
* for the header files above, but not in this file, in order to generate the
* correct privileged Vs unprivileged linkage and placement. */