summaryrefslogtreecommitdiffstats
path: root/cpukit/include/rtems/scheduler.h
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2020-02-15 11:52:00 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2020-02-25 07:18:35 +0100
commite50e42b820c4163a1c5e07c6697c3102fc2d4740 (patch)
tree845deffec09923b3a284512397298132c3a8f26a /cpukit/include/rtems/scheduler.h
parentconfig: CONFIGURE_INIT_TASK_INITIAL_MODES (diff)
downloadrtems-e50e42b820c4163a1c5e07c6697c3102fc2d4740.tar.bz2
score: _Scheduler_Is_non_preempt_mode_supported()
If the non-preempt mode for threads is supported depends on the scheduler implementation. Add _Scheduler_Is_non_preempt_mode_supported() to indicate this. Update #3876.
Diffstat (limited to 'cpukit/include/rtems/scheduler.h')
-rw-r--r--cpukit/include/rtems/scheduler.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/cpukit/include/rtems/scheduler.h b/cpukit/include/rtems/scheduler.h
index dbc161a69d..955a83cfb4 100644
--- a/cpukit/include/rtems/scheduler.h
+++ b/cpukit/include/rtems/scheduler.h
@@ -27,6 +27,13 @@
_Configuration_Scheduler_ ## name
#if defined(RTEMS_SMP)
+ #define SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( value ) \
+ , value
+#else
+ #define SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( value )
+#endif
+
+#if defined(RTEMS_SMP)
/* This object doesn't exist and indicates a configuration error */
extern const Scheduler_Control RTEMS_SCHEDULER_INVALID_INDEX;
@@ -72,6 +79,7 @@
SCHEDULER_CBS_ENTRY_POINTS, \
SCHEDULER_CBS_MAXIMUM_PRIORITY, \
( obj_name ) \
+ SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( true ) \
}
/* Provided for backward compatibility */
@@ -98,6 +106,7 @@
SCHEDULER_EDF_ENTRY_POINTS, \
SCHEDULER_EDF_MAXIMUM_PRIORITY, \
( obj_name ) \
+ SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( true ) \
}
/* Provided for backward compatibility */
@@ -131,6 +140,7 @@
SCHEDULER_EDF_SMP_ENTRY_POINTS, \
SCHEDULER_EDF_MAXIMUM_PRIORITY, \
( obj_name ) \
+ SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( false ) \
}
/* Provided for backward compatibility */
@@ -162,6 +172,7 @@
SCHEDULER_PRIORITY_CONTEXT_NAME( name ).Ready \
) - 1, \
( obj_name ) \
+ SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( true ) \
}
/* Provided for backward compatibility */
@@ -193,6 +204,7 @@
SCHEDULER_PRIORITY_AFFINITY_SMP_CONTEXT_NAME( name ).Ready \
) - 1, \
( obj_name ) \
+ SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( false ) \
}
/* Provided for backward compatibility */
@@ -224,6 +236,7 @@
SCHEDULER_PRIORITY_SMP_CONTEXT_NAME( name ).Ready \
) - 1, \
( obj_name ) \
+ SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( false ) \
}
/* Provided for backward compatibility */
@@ -255,6 +268,7 @@
SCHEDULER_STRONG_APA_CONTEXT_NAME( name ).Ready \
) - 1, \
( obj_name ) \
+ SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( false ) \
}
/* Provided for backward compatibility */
@@ -282,6 +296,7 @@
SCHEDULER_SIMPLE_ENTRY_POINTS, \
SCHEDULER_SIMPLE_MAXIMUM_PRIORITY, \
( obj_name ) \
+ SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( true ) \
}
/* Provided for backward compatibility */
@@ -309,6 +324,7 @@
SCHEDULER_SIMPLE_SMP_ENTRY_POINTS, \
SCHEDULER_SIMPLE_SMP_MAXIMUM_PRIORITY, \
( obj_name ) \
+ SCHEDULER_CONTROL_IS_NON_PREEMPT_MODE_SUPPORTED( false ) \
}
/* Provided for backward compatibility */