[rtems commit] config: CONFIGURE_INIT_TASK_INITIAL_MODES

Sebastian Huber sebh at rtems.org
Tue Feb 25 11:32:19 UTC 2020


Module:    rtems
Branch:    master
Commit:    5b8d80d726091ece15eebf93827563979891c0ca
Changeset: http://git.rtems.org/rtems/commit/?id=5b8d80d726091ece15eebf93827563979891c0ca

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Sat Feb 15 11:23:08 2020 +0100

config: CONFIGURE_INIT_TASK_INITIAL_MODES

Determine the default for CONFIGURE_INIT_TASK_INITIAL_MODES depeding on
whether RTEMS_SMP is defined or not.

In the tests, use CONFIGURE_INIT_TASK_INITIAL_MODES to explicitly
request RTEMS_NO_PREEMPT mode if necessary.

Update #3876.

---

 cpukit/include/rtems/confdefs.h           | 2 +-
 testsuites/sptests/sp66/init.c            | 1 +
 testsuites/sptests/spsimplesched02/init.c | 2 ++
 3 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/cpukit/include/rtems/confdefs.h b/cpukit/include/rtems/confdefs.h
index 0191392..0fc2d0e 100644
--- a/cpukit/include/rtems/confdefs.h
+++ b/cpukit/include/rtems/confdefs.h
@@ -1343,7 +1343,7 @@ const Thread_Idle_body _Thread_Idle_body = CONFIGURE_IDLE_TASK_BODY;
  * used to specify the initial execution mode of the single Classic API task.
  */
 #ifndef CONFIGURE_INIT_TASK_INITIAL_MODES
-  #ifdef _CONFIGURE_SMP_APPLICATION
+  #ifdef RTEMS_SMP
     #define CONFIGURE_INIT_TASK_INITIAL_MODES RTEMS_DEFAULT_MODES
   #else
     #define CONFIGURE_INIT_TASK_INITIAL_MODES RTEMS_NO_PREEMPT
diff --git a/testsuites/sptests/sp66/init.c b/testsuites/sptests/sp66/init.c
index f2bf46d..3dd8e75 100644
--- a/testsuites/sptests/sp66/init.c
+++ b/testsuites/sptests/sp66/init.c
@@ -1,2 +1,3 @@
 #define INHERIT_CEILING
+#define CONFIGURE_INIT_TASK_INITIAL_MODES RTEMS_NO_PREEMPT
 #include "../sp65/sp65impl.h"
diff --git a/testsuites/sptests/spsimplesched02/init.c b/testsuites/sptests/spsimplesched02/init.c
index b7b1a21..4a08a6c 100644
--- a/testsuites/sptests/spsimplesched02/init.c
+++ b/testsuites/sptests/spsimplesched02/init.c
@@ -154,6 +154,8 @@ rtems_task Init(
 #define CONFIGURE_RTEMS_INIT_TASKS_TABLE
 
 #define CONFIGURE_EXTRA_TASK_STACKS         (3 * RTEMS_MINIMUM_STACK_SIZE)
+
+#define CONFIGURE_INIT_TASK_INITIAL_MODES   RTEMS_NO_PREEMPT
 #define CONFIGURE_INIT_TASK_PRIORITY        4
 
 #define CONFIGURE_DISABLE_SMP_CONFIGURATION



More information about the vc mailing list