[LITMUS^RT] [PATCH 4/5] litmus: use is_present() instead of using rt_param->present
Manohar Vanga
mvanga at mpi-sws.org
Thu Oct 4 12:31:07 CEST 2012
Signed-off-by: Manohar Vanga <mvanga at mpi-sws.org>
---
litmus/sched_pfair.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/litmus/sched_pfair.c b/litmus/sched_pfair.c
index 58f7fc9..6a89b00 100644
--- a/litmus/sched_pfair.c
+++ b/litmus/sched_pfair.c
@@ -254,7 +254,7 @@ static void check_preempt(struct task_struct* t)
{
int cpu = NO_CPU;
if (tsk_rt(t)->linked_on != tsk_rt(t)->scheduled_on &&
- tsk_rt(t)->present) {
+ is_present(t)) {
/* the task can be scheduled and
* is not scheduled where it ought to be scheduled
*/
@@ -310,7 +310,7 @@ static int advance_subtask(quanta_t time, struct task_struct* t, int cpu)
int to_relq;
p->cur = (p->cur + 1) % p->quanta;
if (!p->cur) {
- if (tsk_rt(t)->present) {
+ if (is_present(t)) {
/* The job overran; we start a new budget allocation. */
pfair_prepare_next_period(t);
} else {
@@ -598,7 +598,7 @@ static int safe_to_schedule(struct task_struct* t, int cpu)
"scheduled already on %d.\n", cpu, where);
return 0;
} else
- return tsk_rt(t)->present && !is_completed(t);
+ return is_present(t) && !is_completed(t);
}
static struct task_struct* pfair_schedule(struct task_struct * prev)
--
1.7.2.5
More information about the litmus-dev
mailing list