aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Elliott <gelliott@cs.unc.edu>2012-06-02 20:05:09 -0400
committerGlenn Elliott <gelliott@cs.unc.edu>2012-06-02 20:05:09 -0400
commitca2d5062be676495d35d33b55b978460fabfe39a (patch)
treee7909ffc46749670334eb317baae9eb70d2f401a
parent6a760787264bdbe8d206d0073a51e5d4bdd1c382 (diff)
PGM data structure refinement.
-rw-r--r--include/litmus/rt_param.h35
1 files changed, 21 insertions, 14 deletions
diff --git a/include/litmus/rt_param.h b/include/litmus/rt_param.h
index bc84bfc358a3..a5d68250eef3 100644
--- a/include/litmus/rt_param.h
+++ b/include/litmus/rt_param.h
@@ -33,6 +33,16 @@ typedef enum {
33 PRECISE_ENFORCEMENT /* budgets are enforced with hrtimers */ 33 PRECISE_ENFORCEMENT /* budgets are enforced with hrtimers */
34} budget_policy_t; 34} budget_policy_t;
35 35
36struct rt_task {
37 lt_t exec_cost;
38 lt_t period;
39 lt_t phase;
40 unsigned int cpu;
41 task_class_t cls;
42 budget_policy_t budget_policy; /* ignored by pfair */
43};
44
45
36#ifdef CONFIG_PGM 46#ifdef CONFIG_PGM
37 47
38#define MAX_FAN CONFIG_MAX_PGM_FAN 48#define MAX_FAN CONFIG_MAX_PGM_FAN
@@ -60,24 +70,16 @@ struct pgm_consume
60{ 70{
61 int nr_consumptions; /* num of consumption constraints */ 71 int nr_consumptions; /* num of consumption constraints */
62 char satisfied[FAN_BYTES]; /* bit-array of satisfied constraints; 72 char satisfied[FAN_BYTES]; /* bit-array of satisfied constraints;
63 bit == 0 means satisfied! */ 73 bit == 0 means satisfied! */
64 struct pgm_consumption consume[0]; /* array of consumption constraints */ 74 struct pgm_consumption consume[0]; /* array of consumption constraints */
65}; 75};
66#endif
67 76
68struct rt_task { 77struct rt_pgm {
69 lt_t exec_cost; 78 struct pgm_produce *produce; /* output and current state */
70 lt_t period; 79 struct pgm_consume *consume; /* input constraints and current state */
71 lt_t phase; 80 struct task_struct *src; /* only not NULL if task is sink */
72 unsigned int cpu;
73 task_class_t cls;
74 budget_policy_t budget_policy; /* ignored by pfair */
75
76#ifdef CONFIG_PGM
77 struct pgm_produce *produce;
78 struct pgm_consume *consume;
79#endif
80}; 81};
82#endif
81 83
82union np_flag { 84union np_flag {
83 uint32_t raw; 85 uint32_t raw;
@@ -164,6 +166,11 @@ struct rt_param {
164 /* timing parameters */ 166 /* timing parameters */
165 struct rt_job job_params; 167 struct rt_job job_params;
166 168
169#ifdef CONFIG_PGM
170 struct rt_pgm pgm_params;
171 unsigned int is_pgm_node:1;
172#endif
173
167 /* task representing the current "inherited" task 174 /* task representing the current "inherited" task
168 * priority, assigned by inherit_priority and 175 * priority, assigned by inherit_priority and
169 * return priority in the scheduler plugins. 176 * return priority in the scheduler plugins.