aboutsummaryrefslogtreecommitdiffstats
path: root/include/litmus/rt_param.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/litmus/rt_param.h')
-rw-r--r--include/litmus/rt_param.h51
1 files changed, 50 insertions, 1 deletions
diff --git a/include/litmus/rt_param.h b/include/litmus/rt_param.h
index 7b9a90965c25..998762051a6b 100644
--- a/include/litmus/rt_param.h
+++ b/include/litmus/rt_param.h
@@ -62,6 +62,7 @@ typedef enum {
62#define LITMUS_MAX_PRIORITY 512 62#define LITMUS_MAX_PRIORITY 512
63#define LITMUS_HIGHEST_PRIORITY 1 63#define LITMUS_HIGHEST_PRIORITY 1
64#define LITMUS_LOWEST_PRIORITY (LITMUS_MAX_PRIORITY - 1) 64#define LITMUS_LOWEST_PRIORITY (LITMUS_MAX_PRIORITY - 1)
65#define LITMUS_NO_PRIORITY UINT_MAX
65 66
66/* Provide generic comparison macros for userspace, 67/* Provide generic comparison macros for userspace,
67 * in case that we change this later. */ 68 * in case that we change this later. */
@@ -71,6 +72,46 @@ typedef enum {
71 ((p) >= LITMUS_HIGHEST_PRIORITY && \ 72 ((p) >= LITMUS_HIGHEST_PRIORITY && \
72 (p) <= LITMUS_LOWEST_PRIORITY) 73 (p) <= LITMUS_LOWEST_PRIORITY)
73 74
75/* reservation support */
76
77typedef enum {
78 PERIODIC_POLLING,
79 SPORADIC_POLLING,
80 TABLE_DRIVEN,
81} reservation_type_t;
82
83struct lt_interval {
84 lt_t start;
85 lt_t end;
86};
87
88#ifndef __KERNEL__
89#define __user
90#endif
91
92struct reservation_config {
93 unsigned int id;
94 lt_t priority;
95 int cpu;
96
97 union {
98 struct {
99 lt_t period;
100 lt_t budget;
101 lt_t relative_deadline;
102 lt_t offset;
103 } polling_params;
104
105 struct {
106 lt_t major_cycle_length;
107 unsigned int num_intervals;
108 struct lt_interval __user *intervals;
109 } table_driven_params;
110 };
111};
112
113/* regular sporadic task support */
114
74struct rt_task { 115struct rt_task {
75 lt_t exec_cost; 116 lt_t exec_cost;
76 lt_t period; 117 lt_t period;
@@ -165,6 +206,7 @@ struct rt_job {
165}; 206};
166 207
167struct pfair_param; 208struct pfair_param;
209struct mc2_task;
168 210
169/* RT task parameters for scheduling extensions 211/* RT task parameters for scheduling extensions
170 * These parameters are inherited during clone and therefore must 212 * These parameters are inherited during clone and therefore must
@@ -246,7 +288,10 @@ struct rt_param {
246 volatile int linked_on; 288 volatile int linked_on;
247 289
248 /* PFAIR/PD^2 state. Allocated on demand. */ 290 /* PFAIR/PD^2 state. Allocated on demand. */
249 struct pfair_param* pfair; 291 union {
292 void *plugin_state;
293 struct pfair_param *pfair;
294 };
250 295
251 /* Fields saved before BE->RT transition. 296 /* Fields saved before BE->RT transition.
252 */ 297 */
@@ -275,6 +320,10 @@ struct rt_param {
275 320
276 /* Pointer to the page shared between userspace and kernel. */ 321 /* Pointer to the page shared between userspace and kernel. */
277 struct control_page * ctrl_page; 322 struct control_page * ctrl_page;
323
324 /* Mixed-criticality specific data */
325 struct mc2_task* mc2_data;
326 unsigned long addr_ctrl_page;
278}; 327};
279 328
280#endif 329#endif