* [PATCH 1/1] sched: Add update_rq_clock() in sched_rt_rq_enqueue()
@ 2021-12-24 1:22 YT Chang
2022-02-07 10:48 ` Peter Zijlstra
0 siblings, 1 reply; 2+ messages in thread
From: YT Chang @ 2021-12-24 1:22 UTC (permalink / raw)
To: YT Chang, Ingo Molnar, Peter Zijlstra, Juri Lelli,
Vincent Guittot, Dietmar Eggemann, Steven Rostedt, Ben Segall,
Mel Gorman, Daniel Bristot de Oliveira, Matthias Brugger
Cc: linux-kernel, linux-arm-kernel, linux-mediatek, wsd_upstream
Add update_rq_clock() in sched_rt_rq_enqueue() to
prevent the warning "rq->clock_update_flags < RQCF_ACT_SKIP"
when call rq_clock() in cpufreq_update_util().
sched_rt_rq_enqueue ->
enqueue_top_rt_rq ->
cpufreq_update_util ->
rq_clock ->
assert_clock_updated
Signed-off-by: YT Chang <yt.chang@mediatek.com>
Change-Id: I4fba5a561b7064aafa991d7f1a34431607779cb4
---
kernel/sched/rt.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/kernel/sched/rt.c b/kernel/sched/rt.c
index b48baaba2fc2..faf1a68c0723 100644
--- a/kernel/sched/rt.c
+++ b/kernel/sched/rt.c
@@ -539,6 +539,7 @@ static void sched_rt_rq_enqueue(struct rt_rq *rt_rq)
int cpu = cpu_of(rq);
+ update_rq_clock(rq);
rt_se = rt_rq->tg->rt_se[cpu];
if (rt_rq->rt_nr_running) {
--
2.18.0
_______________________________________________
Linux-mediatek mailing list
Linux-mediatek@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-mediatek
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 1/1] sched: Add update_rq_clock() in sched_rt_rq_enqueue()
2021-12-24 1:22 [PATCH 1/1] sched: Add update_rq_clock() in sched_rt_rq_enqueue() YT Chang
@ 2022-02-07 10:48 ` Peter Zijlstra
0 siblings, 0 replies; 2+ messages in thread
From: Peter Zijlstra @ 2022-02-07 10:48 UTC (permalink / raw)
To: YT Chang
Cc: Ingo Molnar, Juri Lelli, Vincent Guittot, Dietmar Eggemann,
Steven Rostedt, Ben Segall, Mel Gorman,
Daniel Bristot de Oliveira, Matthias Brugger, linux-kernel,
linux-arm-kernel, linux-mediatek, wsd_upstream
On Fri, Dec 24, 2021 at 09:22:39AM +0800, YT Chang wrote:
> Add update_rq_clock() in sched_rt_rq_enqueue() to
> prevent the warning "rq->clock_update_flags < RQCF_ACT_SKIP"
> when call rq_clock() in cpufreq_update_util().
>
> sched_rt_rq_enqueue ->
> enqueue_top_rt_rq ->
> cpufreq_update_util ->
> rq_clock ->
> assert_clock_updated
>
> Signed-off-by: YT Chang <yt.chang@mediatek.com>
> Change-Id: I4fba5a561b7064aafa991d7f1a34431607779cb4
Change-Id does not belong in kernel patches..
> ---
> kernel/sched/rt.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/kernel/sched/rt.c b/kernel/sched/rt.c
> index b48baaba2fc2..faf1a68c0723 100644
> --- a/kernel/sched/rt.c
> +++ b/kernel/sched/rt.c
> @@ -539,6 +539,7 @@ static void sched_rt_rq_enqueue(struct rt_rq *rt_rq)
>
> int cpu = cpu_of(rq);
>
> + update_rq_clock(rq);
This isn't right I think; there's at least one caller of this function
that already did that. A double clock update is also wrong. Each path
should have just one.
> rt_se = rt_rq->tg->rt_se[cpu];
>
> if (rt_rq->rt_nr_running) {
> --
> 2.18.0
>
_______________________________________________
Linux-mediatek mailing list
Linux-mediatek@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-mediatek
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-02-07 10:49 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-24 1:22 [PATCH 1/1] sched: Add update_rq_clock() in sched_rt_rq_enqueue() YT Chang
2022-02-07 10:48 ` Peter Zijlstra
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).