summaryrefslogtreecommitdiffstats
path: root/cpukit/score/include/rtems/score/scheduler.h
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2016-06-10 08:48:54 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2016-06-22 14:36:40 +0200
commit77ff5599e0d8e6d91190a379be21a332f83252b0 (patch)
tree339e28b236beb9e606322cb801d7340e2e44f8bf /cpukit/score/include/rtems/score/scheduler.h
parentscore: Delete unused _Scheduler_Priority_compare() (diff)
downloadrtems-77ff5599e0d8e6d91190a379be21a332f83252b0.tar.bz2
score: Introduce map priority scheduler operation
Introduce map/unmap priority scheduler operations to map thread priority values from/to the user domain to/from the scheduler domain. Use the map priority operation to validate the thread priority. The EDF schedulers use this new operation to distinguish between normal priorities and priorities obtain through a job release. Update #2173. Update #2556.
Diffstat (limited to 'cpukit/score/include/rtems/score/scheduler.h')
-rw-r--r--cpukit/score/include/rtems/score/scheduler.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/cpukit/score/include/rtems/score/scheduler.h b/cpukit/score/include/rtems/score/scheduler.h
index 2e9aba5072..ba9c2b50bb 100644
--- a/cpukit/score/include/rtems/score/scheduler.h
+++ b/cpukit/score/include/rtems/score/scheduler.h
@@ -91,6 +91,18 @@ typedef struct {
bool
);
+ /** @see _Scheduler_Map_priority() */
+ Priority_Control ( *map_priority )(
+ const Scheduler_Control *,
+ Priority_Control
+ );
+
+ /** @see _Scheduler_Unmap_priority() */
+ Priority_Control ( *unmap_priority )(
+ const Scheduler_Control *,
+ Priority_Control
+ );
+
#if defined(RTEMS_SMP)
/**
* Ask for help operation.
@@ -403,6 +415,21 @@ extern const Scheduler_Control _Scheduler_Table[];
extern const Scheduler_Assignment _Scheduler_Assignments[];
#endif
+/**
+ * @brief Returns the thread priority.
+ *
+ * @param[in] scheduler Unused.
+ * @param[in] priority The thread priority.
+ *
+ * @return priority The thread priority.
+ */
+Priority_Control _Scheduler_default_Map_priority(
+ const Scheduler_Control *scheduler,
+ Priority_Control priority
+);
+
+#define _Scheduler_default_Unmap_priority _Scheduler_default_Map_priority
+
#if defined(RTEMS_SMP)
/**
* @brief Does nothing.