Inter-revision diff: patch 3

Comparing v9 (message) to v10 (message)

--- v9
+++ v10
@@ -30,6 +30,7 @@
 Signed-off-by: Zecheng Li <zecheng@google.com>
 Signed-off-by: Zecheng Li <zli94@ncsu.edu>
 Reviewed-by: K Prateek Nayak <kprateek.nayak@amd.com>
+Reviewed-by: Josh Don <joshdon@google.com>
 ---
  kernel/sched/core.c  | 35 +++++++++++-----------------
  kernel/sched/fair.c  | 54 ++++++++++++++++++--------------------------
@@ -37,10 +38,10 @@
  3 files changed, 45 insertions(+), 58 deletions(-)
 
 diff --git a/kernel/sched/core.c b/kernel/sched/core.c
-index 2df42786f780..0e03b257ca9a 100644
+index 86fbb38901aa..163930370cd0 100644
 --- a/kernel/sched/core.c
 +++ b/kernel/sched/core.c
-@@ -8593,7 +8593,7 @@ static struct kmem_cache *task_group_cache __ro_after_init;
+@@ -8884,7 +8884,7 @@ static struct kmem_cache *task_group_cache __ro_after_init;
  
  void __init sched_init(void)
  {
@@ -49,7 +50,7 @@
  	int i;
  
  	/* Make sure the linker didn't screw up */
-@@ -8609,33 +8609,24 @@ void __init sched_init(void)
+@@ -8900,33 +8900,24 @@ void __init sched_init(void)
  	wait_bit_init();
  
  #ifdef CONFIG_FAIR_GROUP_SCHED
@@ -93,7 +94,7 @@
  
  	init_defrootdomain();
  
-@@ -9545,7 +9536,7 @@ static int tg_set_cfs_bandwidth(struct task_group *tg,
+@@ -9841,7 +9832,7 @@ static int tg_set_cfs_bandwidth(struct task_group *tg,
  	}
  
  	for_each_online_cpu(i) {
@@ -102,7 +103,7 @@
  		struct rq *rq = cfs_rq->rq;
  
  		guard(rq_lock_irq)(rq);
-@@ -9713,7 +9704,7 @@ static u64 throttled_time_self(struct task_group *tg)
+@@ -10009,7 +10000,7 @@ static u64 throttled_time_self(struct task_group *tg)
  	u64 total = 0;
  
  	for_each_possible_cpu(i) {
@@ -112,7 +113,7 @@
  
  	return total;
 diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
-index c116e7c2b916..5a6491edcf31 100644
+index db23951d6ba0..9f5b3b3e738c 100644
 --- a/kernel/sched/fair.c
 +++ b/kernel/sched/fair.c
 @@ -334,7 +334,7 @@ static inline bool list_add_leaf_cfs_rq(struct cfs_rq *cfs_rq)
@@ -133,7 +134,7 @@
  		/*
  		 * The branch is now connected to its tree so we can
  		 * reset tmp_alone_branch to the beginning of the
-@@ -4387,7 +4387,7 @@ static void __maybe_unused clear_tg_offline_cfs_rqs(struct rq *rq)
+@@ -5008,7 +5008,7 @@ static void __maybe_unused clear_tg_offline_cfs_rqs(struct rq *rq)
  
  	rcu_read_lock();
  	list_for_each_entry_rcu(tg, &task_groups, list) {
@@ -142,7 +143,7 @@
  
  		clear_tg_load_avg(cfs_rq);
  	}
-@@ -5930,7 +5930,7 @@ static inline int throttled_hierarchy(struct cfs_rq *cfs_rq)
+@@ -6565,7 +6565,7 @@ static inline int throttled_hierarchy(struct cfs_rq *cfs_rq)
  
  static inline int lb_throttled_hierarchy(struct task_struct *p, int dst_cpu)
  {
@@ -151,7 +152,7 @@
  }
  
  static inline bool task_is_throttled(struct task_struct *p)
-@@ -6076,7 +6076,7 @@ static void enqueue_task_fair(struct rq *rq, struct task_struct *p, int flags);
+@@ -6711,7 +6711,7 @@ static void enqueue_task_fair(struct rq *rq, struct task_struct *p, int flags);
  static int tg_unthrottle_up(struct task_group *tg, void *data)
  {
  	struct rq *rq = data;
@@ -160,7 +161,7 @@
  	struct task_struct *p, *tmp;
  
  	if (--cfs_rq->throttle_count)
-@@ -6147,7 +6147,7 @@ static void record_throttle_clock(struct cfs_rq *cfs_rq)
+@@ -6782,7 +6782,7 @@ static void record_throttle_clock(struct cfs_rq *cfs_rq)
  static int tg_throttle_down(struct task_group *tg, void *data)
  {
  	struct rq *rq = data;
@@ -169,7 +170,7 @@
  
  	if (cfs_rq->throttle_count++)
  		return 0;
-@@ -6621,8 +6621,8 @@ static void sync_throttle(struct task_group *tg, int cpu)
+@@ -7256,8 +7256,8 @@ static void sync_throttle(struct task_group *tg, int cpu)
  	if (!tg->parent)
  		return;
  
@@ -180,7 +181,7 @@
  
  	cfs_rq->throttle_count = pcfs_rq->throttle_count;
  	cfs_rq->throttled_clock_pelt = rq_clock_pelt(cpu_rq(cpu));
-@@ -6814,7 +6814,7 @@ static void __maybe_unused update_runtime_enabled(struct rq *rq)
+@@ -7449,7 +7449,7 @@ static void __maybe_unused update_runtime_enabled(struct rq *rq)
  	rcu_read_lock();
  	list_for_each_entry_rcu(tg, &task_groups, list) {
  		struct cfs_bandwidth *cfs_b = &tg->cfs_bandwidth;
@@ -189,7 +190,7 @@
  
  		raw_spin_lock(&cfs_b->lock);
  		cfs_rq->runtime_enabled = cfs_b->quota != RUNTIME_INF;
-@@ -6843,7 +6843,7 @@ static void __maybe_unused unthrottle_offline_cfs_rqs(struct rq *rq)
+@@ -7478,7 +7478,7 @@ static void __maybe_unused unthrottle_offline_cfs_rqs(struct rq *rq)
  
  	rcu_read_lock();
  	list_for_each_entry_rcu(tg, &task_groups, list) {
@@ -198,7 +199,7 @@
  
  		if (!cfs_rq->runtime_enabled)
  			continue;
-@@ -9636,7 +9636,7 @@ static inline int task_is_ineligible_on_dst_cpu(struct task_struct *p, int dest_
+@@ -10403,7 +10403,7 @@ static inline int task_is_ineligible_on_dst_cpu(struct task_struct *p, int dest_
  	struct cfs_rq *dst_cfs_rq;
  
  #ifdef CONFIG_FAIR_GROUP_SCHED
@@ -207,7 +208,7 @@
  #else
  	dst_cfs_rq = &cpu_rq(dest_cpu)->cfs;
  #endif
-@@ -13604,7 +13604,7 @@ static int task_is_throttled_fair(struct task_struct *p, int cpu)
+@@ -14833,7 +14833,7 @@ static int task_is_throttled_fair(struct task_struct *p, int cpu)
  	struct cfs_rq *cfs_rq;
  
  #ifdef CONFIG_FAIR_GROUP_SCHED
@@ -216,7 +217,7 @@
  #else
  	cfs_rq = &cpu_rq(cpu)->cfs;
  #endif
-@@ -13870,39 +13870,31 @@ static void task_change_group_fair(struct task_struct *p)
+@@ -15098,39 +15098,31 @@ static void task_change_group_fair(struct task_struct *p)
  
  void free_fair_sched_group(struct task_group *tg)
  {
@@ -264,7 +265,7 @@
  		init_cfs_rq(cfs_rq);
  		init_tg_cfs_entry(tg, cfs_rq, se, i, tg_se(parent, i));
  		init_entity_runnable_average(se);
-@@ -13939,7 +13931,7 @@ void unregister_fair_sched_group(struct task_group *tg)
+@@ -15167,7 +15159,7 @@ void unregister_fair_sched_group(struct task_group *tg)
  	destroy_cfs_bandwidth(tg_cfs_bandwidth(tg));
  
  	for_each_possible_cpu(cpu) {
@@ -273,7 +274,7 @@
  		struct sched_entity *se = tg_se(tg, cpu);
  		struct rq *rq = cpu_rq(cpu);
  
-@@ -13976,8 +13968,6 @@ void init_tg_cfs_entry(struct task_group *tg, struct cfs_rq *cfs_rq,
+@@ -15204,8 +15196,6 @@ void init_tg_cfs_entry(struct task_group *tg, struct cfs_rq *cfs_rq,
  	cfs_rq->rq = rq;
  	init_cfs_rq_runtime(cfs_rq);
  
@@ -282,7 +283,7 @@
  	/* se could be NULL for root_task_group */
  	if (!se)
  		return;
-@@ -14070,7 +14060,7 @@ int sched_group_set_idle(struct task_group *tg, long idle)
+@@ -15298,7 +15288,7 @@ int sched_group_set_idle(struct task_group *tg, long idle)
  	for_each_possible_cpu(i) {
  		struct rq *rq = cpu_rq(i);
  		struct sched_entity *se = tg_se(tg, i);
@@ -292,7 +293,7 @@
  		long idle_task_delta;
  		struct rq_flags rf;
 diff --git a/kernel/sched/sched.h b/kernel/sched/sched.h
-index 258dc689a535..0d0f87e873fe 100644
+index 63574f9d57f1..95a22baa172b 100644
 --- a/kernel/sched/sched.h
 +++ b/kernel/sched/sched.h
 @@ -481,7 +481,7 @@ struct task_group {
@@ -304,7 +305,7 @@
  	unsigned long		shares;
  	/*
  	 * load_avg can be heavily contended at clock tick time, so put
-@@ -2259,6 +2259,12 @@ struct cfs_tg_state {
+@@ -2299,6 +2299,12 @@ struct cfs_tg_state {
  	struct sched_statistics	stats;
  } __no_randomize_layout;
  
@@ -317,7 +318,7 @@
  static inline struct sched_entity *tg_se(struct task_group *tg, int cpu)
  {
  	struct cfs_tg_state *state;
-@@ -2266,7 +2272,7 @@ static inline struct sched_entity *tg_se(struct task_group *tg, int cpu)
+@@ -2306,7 +2312,7 @@ static inline struct sched_entity *tg_se(struct task_group *tg, int cpu)
  	if (is_root_task_group(tg))
  		return NULL;
  
@@ -326,7 +327,7 @@
  	return &state->se;
  }
  
-@@ -2290,8 +2296,8 @@ static inline void set_task_rq(struct task_struct *p, unsigned int cpu)
+@@ -2330,8 +2336,8 @@ static inline void set_task_rq(struct task_struct *p, unsigned int cpu)
  #endif
  
  #ifdef CONFIG_FAIR_GROUP_SCHED
@@ -338,5 +339,5 @@
  	p->se.depth = p->se.parent ? p->se.parent->depth + 1 : 0;
  #endif
 -- 
-2.53.0
-
+2.54.0
+
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help