[<prev] [next>] [day] [month] [year] [list]
Message-ID: <1432641001.6866.58.camel@odin.com>
Date: Tue, 26 May 2015 14:50:01 +0300
From: Kirill Tkhai <ktkhai@...n.com>
To: <linux-kernel@...r.kernel.org>
CC: Peter Zijlstra <peterz@...radead.org>,
Konstantin Khlebnikov <khlebnikov@...dex-team.ru>,
Mohammed Naser <mnaser@...xhost.com>,
"Ingo Molnar" <mingo@...nel.org>, Kirill Tkhai <tkhai@...dex.ru>
Subject: [PATCH 1/2] sched/fair: make update_curr_fair() update whole
hierarhy
This patch makes update_curr_fair() similar to update_curr_rt(),
which updates runtime on whole hierarhy. We need that in next
patch.
Signed-off-by: Kirill Tkhai <ktkhai@...n.com>
---
kernel/sched/fair.c | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index d597aea..ece94af 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -729,7 +729,18 @@ static void update_curr(struct cfs_rq *cfs_rq)
static void update_curr_fair(struct rq *rq)
{
- update_curr(cfs_rq_of(&rq->curr->se));
+ struct task_struct *curr = rq->curr;
+ struct sched_entity *se;
+ struct cfs_rq *cfs_rq;
+
+ if (curr->sched_class != &fair_sched_class)
+ return;
+ se = &curr->se;
+ for_each_sched_entity(se) {
+ cfs_rq = cfs_rq_of(se);
+ update_curr(cfs_rq);
+ }
+
}
static inline void
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists