Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1431965

[PATCH v2] sched/fair: avoid !CONFIG_SMP cpufreq update callbacks for !root cfs_rq

From Jisheng Zhang <jszhang@marvell.com>
Newsgroups linux.kernel
Subject [PATCH v2] sched/fair: avoid !CONFIG_SMP cpufreq update callbacks for !root cfs_rq
Date 2016-06-27 13:40 +0200
Message-ID <rOD3s-83w-29@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


This is to avoid cpufreq update callbacks for for !root cgroups when
!CONFIG_SMP

Signed-off-by: Jisheng Zhang <jszhang@marvell.com>
---

Since v1:

 -fix commit msg, now I really know what the check is for, thank Peter

 kernel/sched/fair.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index bdcbeea..236ec5b 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -3121,7 +3121,8 @@ static inline void update_load_avg(struct sched_entity *se, int not_used)
 	struct cfs_rq *cfs_rq = cfs_rq_of(se);
 	struct rq *rq = rq_of(cfs_rq);
 
-	cpufreq_trigger_update(rq_clock(rq));
+	if (&rq->cfs == cfs_rq)
+		cpufreq_trigger_update(rq_clock(rq));
 }
 
 static inline void
-- 
2.8.1

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

[PATCH v2] sched/fair: avoid !CONFIG_SMP cpufreq update callbacks for !root cfs_rq Jisheng Zhang <jszhang@marvell.com> - 2016-06-27 13:40 +0200

csiph-web