sched/fair: Fix cfs_rq_clock_pelt() for throttled cfs_rq
authorChengming Zhou <zhouchengming@bytedance.com>
Fri, 8 Apr 2022 11:53:08 +0000 (19:53 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 9 Jun 2022 08:22:48 +0000 (10:22 +0200)
commit36f416fdda1e0055be4bf2c77657b43ef43761a3
tree9a4c79431325a5878f094cb1206f8004fefea1fd
parent60768ffcede23197efbceb391437c9e22d9c7718
sched/fair: Fix cfs_rq_clock_pelt() for throttled cfs_rq

[ Upstream commit 64eaf50731ac0a8c76ce2fedd50ef6652aabc5ff ]

Since commit 23127296889f ("sched/fair: Update scale invariance of PELT")
change to use rq_clock_pelt() instead of rq_clock_task(), we should also
use rq_clock_pelt() for throttled_clock_task_time and throttled_clock_task
accounting to get correct cfs_rq_clock_pelt() of throttled cfs_rq. And
rename throttled_clock_task(_time) to be clock_pelt rather than clock_task.

Fixes: 23127296889f ("sched/fair: Update scale invariance of PELT")
Signed-off-by: Chengming Zhou <zhouchengming@bytedance.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Ben Segall <bsegall@google.com>
Reviewed-by: Vincent Guittot <vincent.guittot@linaro.org>
Link: https://lore.kernel.org/r/20220408115309.81603-1-zhouchengming@bytedance.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
kernel/sched/fair.c
kernel/sched/pelt.h
kernel/sched/sched.h