[RFC 08/60] sched: Move init_entity_runnable_average() into init_tg_cfs_entry()
From: Jan H. SchÃnherr
Date: Fri Sep 07 2018 - 17:45:24 EST
Move init_entity_runnable_average() into init_tg_cfs_entry(), where all
the other SE initialization is carried out.
Signed-off-by: Jan H. SchÃnherr <jschoenh@xxxxxxxxx>
---
kernel/sched/fair.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index c0dd5825556c..2b3fd7cd9fde 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -9846,7 +9846,6 @@ int alloc_fair_sched_group(struct task_group *tg, struct task_group *parent)
tg->cfs_rq[i] = cfs_rq;
init_cfs_rq(cfs_rq);
init_tg_cfs_entry(tg, cfs_rq, se, cpu_rq(i), parent->cfs_rq[i]);
- init_entity_runnable_average(se);
}
return 1;
@@ -9918,6 +9917,7 @@ void init_tg_cfs_entry(struct task_group *tg, struct cfs_rq *cfs_rq,
/* guarantee group entities always have weight */
update_load_set(&se->load, NICE_0_LOAD);
+ init_entity_runnable_average(se);
}
static DEFINE_MUTEX(shares_mutex);
--
2.9.3.1.gcba166c.dirty