diff options
Diffstat (limited to 'litmus/edf_common.c')
-rwxr-xr-x[-rw-r--r--] | litmus/edf_common.c | 21 |
1 files changed, 7 insertions, 14 deletions
diff --git a/litmus/edf_common.c b/litmus/edf_common.c index a9bf0c08e125..5a3f5b417f73 100644..100755 --- a/litmus/edf_common.c +++ b/litmus/edf_common.c | |||
@@ -43,7 +43,7 @@ static inline long edf_hash(struct task_struct *t) | |||
43 | } | 43 | } |
44 | #endif | 44 | #endif |
45 | 45 | ||
46 | #ifdef CONFIG_REALTIME_AUX_TASKS | 46 | #ifdef CONFIG_REALTIME_AUX_TASK_PRIORITY_INHERITANCE |
47 | int aux_tie_break(struct task_struct *first, struct task_struct *second) | 47 | int aux_tie_break(struct task_struct *first, struct task_struct *second) |
48 | { | 48 | { |
49 | long fhash = edf_hash(first); | 49 | long fhash = edf_hash(first); |
@@ -90,9 +90,8 @@ int edf_higher_prio(struct task_struct* first, struct task_struct* second) | |||
90 | return first && !second; | 90 | return first && !second; |
91 | } | 91 | } |
92 | 92 | ||
93 | #ifdef CONFIG_REALTIME_AUX_TASKS | ||
94 | { | ||
95 | 93 | ||
94 | #if defined(CONFIG_REALTIME_AUX_TASK_PRIORITY_BOOSTED) | ||
96 | /* run aux tasks at max priority */ | 95 | /* run aux tasks at max priority */ |
97 | if (first->rt_param.is_aux_task != second->rt_param.is_aux_task) | 96 | if (first->rt_param.is_aux_task != second->rt_param.is_aux_task) |
98 | { | 97 | { |
@@ -103,9 +102,8 @@ int edf_higher_prio(struct task_struct* first, struct task_struct* second) | |||
103 | first = first->group_leader; | 102 | first = first->group_leader; |
104 | second = second->group_leader; | 103 | second = second->group_leader; |
105 | } | 104 | } |
106 | 105 | #elif defined(CONFIG_REALTIME_AUX_TASK_PRIORITY_INHERITANCE) | |
107 | 106 | { | |
108 | #if 0 | ||
109 | int first_lo_aux, second_lo_aux; | 107 | int first_lo_aux, second_lo_aux; |
110 | int first_hi_aux, second_hi_aux; | 108 | int first_hi_aux, second_hi_aux; |
111 | first_lo_aux = first->rt_param.is_aux_task && !first->rt_param.inh_task; | 109 | first_lo_aux = first->rt_param.is_aux_task && !first->rt_param.inh_task; |
@@ -133,11 +131,10 @@ int edf_higher_prio(struct task_struct* first, struct task_struct* second) | |||
133 | TRACE_CUR("hi aux tie break: %s/%d >> %s/%d --- %d\n", first->comm, first->pid, second->comm, second->pid, aux_hi_tie_break); | 131 | TRACE_CUR("hi aux tie break: %s/%d >> %s/%d --- %d\n", first->comm, first->pid, second->comm, second->pid, aux_hi_tie_break); |
134 | return aux_hi_tie_break; | 132 | return aux_hi_tie_break; |
135 | } | 133 | } |
136 | #endif | ||
137 | |||
138 | } | 134 | } |
139 | #endif | 135 | #endif |
140 | 136 | ||
137 | |||
141 | #ifdef CONFIG_LITMUS_LOCKING | 138 | #ifdef CONFIG_LITMUS_LOCKING |
142 | /* Check for EFFECTIVE priorities. Change task | 139 | /* Check for EFFECTIVE priorities. Change task |
143 | * used for comparison in such a case. | 140 | * used for comparison in such a case. |
@@ -252,15 +249,13 @@ int edf_higher_prio(struct task_struct* first, struct task_struct* second) | |||
252 | else if (first_task->rt_param.is_proxy_thread == second_task->rt_param.is_proxy_thread) { | 249 | else if (first_task->rt_param.is_proxy_thread == second_task->rt_param.is_proxy_thread) { |
253 | #endif | 250 | #endif |
254 | 251 | ||
255 | #if 0 | 252 | #if defined(CONFIG_REALTIME_AUX_TASK_PRIORITY_INHERITANCE) |
256 | #ifdef CONFIG_REALTIME_AUX_TASKS | ||
257 | /* is this dead code? */ | 253 | /* is this dead code? */ |
258 | if (tsk_rt(first)->is_aux_task < tsk_rt(second)->is_aux_task) { | 254 | if (tsk_rt(first)->is_aux_task < tsk_rt(second)->is_aux_task) { |
259 | return 1; | 255 | return 1; |
260 | } | 256 | } |
261 | else if (tsk_rt(first)->is_aux_task == tsk_rt(second)->is_aux_task) { | 257 | else if (tsk_rt(first)->is_aux_task == tsk_rt(second)->is_aux_task) { |
262 | #endif | 258 | #endif |
263 | #endif | ||
264 | 259 | ||
265 | /* Something could be wrong if you get this far. */ | 260 | /* Something could be wrong if you get this far. */ |
266 | if (unlikely(first->rt_param.inh_task == | 261 | if (unlikely(first->rt_param.inh_task == |
@@ -297,11 +292,9 @@ int edf_higher_prio(struct task_struct* first, struct task_struct* second) | |||
297 | return 1; | 292 | return 1; |
298 | } | 293 | } |
299 | } | 294 | } |
300 | #if 0 | 295 | #if defined(CONFIG_REALTIME_AUX_TASK_PRIORITY_INHERITANCE) |
301 | #ifdef CONFIG_REALTIME_AUX_TASKS | ||
302 | } | 296 | } |
303 | #endif | 297 | #endif |
304 | #endif | ||
305 | 298 | ||
306 | #ifdef CONFIG_LITMUS_SOFTIRQD | 299 | #ifdef CONFIG_LITMUS_SOFTIRQD |
307 | } | 300 | } |