linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] sched/deadline: Fix dl_server_stopped()
@ 2025-08-09 13:04 Huacai Chen
  2025-08-12  9:19 ` Juri Lelli
  2025-08-27  6:45 ` [tip: sched/urgent] " tip-bot2 for Huacai Chen
  0 siblings, 2 replies; 4+ messages in thread
From: Huacai Chen @ 2025-08-09 13:04 UTC (permalink / raw)
  To: Ingo Molnar, Peter Zijlstra, Juri Lelli, Vincent Guittot,
	Dietmar Eggemann, Steven Rostedt, Ben Segall, Mel Gorman,
	Huacai Chen
  Cc: linux-kernel, Huacai Chen

Commit cccb45d7c429 ("sched/deadline: Less agressive dl_server handling")
introduces dl_server_stopped(). But it is obvious that dl_server_stopped()
should return true if dl_se->dl_server_active is 0.

Fixes: cccb45d7c429 ("sched/deadline: Less agressive dl_server handling")
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
---
I found that after commit cccb45d7c429 ("sched/deadline: Less agressive
dl_server handling") there is always a message "sched: DL replenish lagged
too much" after boot. Then I found this bug, but unfortunately this patch
cannot wipe the message.
---
 kernel/sched/deadline.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/sched/deadline.c b/kernel/sched/deadline.c
index e2d51f4306b3..bb813afe5b08 100644
--- a/kernel/sched/deadline.c
+++ b/kernel/sched/deadline.c
@@ -1611,7 +1611,7 @@ void dl_server_stop(struct sched_dl_entity *dl_se)
 static bool dl_server_stopped(struct sched_dl_entity *dl_se)
 {
 	if (!dl_se->dl_server_active)
-		return false;
+		return true;
 
 	if (dl_se->dl_server_idle) {
 		dl_server_stop(dl_se);
-- 
2.47.3


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] sched/deadline: Fix dl_server_stopped()
  2025-08-09 13:04 [PATCH] sched/deadline: Fix dl_server_stopped() Huacai Chen
@ 2025-08-12  9:19 ` Juri Lelli
  2025-08-12 10:21   ` Huacai Chen
  2025-08-27  6:45 ` [tip: sched/urgent] " tip-bot2 for Huacai Chen
  1 sibling, 1 reply; 4+ messages in thread
From: Juri Lelli @ 2025-08-12  9:19 UTC (permalink / raw)
  To: Huacai Chen
  Cc: Ingo Molnar, Peter Zijlstra, Vincent Guittot, Dietmar Eggemann,
	Steven Rostedt, Ben Segall, Mel Gorman, Huacai Chen, linux-kernel

Hi,

On 09/08/25 21:04, Huacai Chen wrote:
> Commit cccb45d7c429 ("sched/deadline: Less agressive dl_server handling")
> introduces dl_server_stopped(). But it is obvious that dl_server_stopped()
> should return true if dl_se->dl_server_active is 0.
> 
> Fixes: cccb45d7c429 ("sched/deadline: Less agressive dl_server handling")
> Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>

This looks correct.

Acked-by: Juri Lelli <juri.lelli@redhat.com>

> ---
> I found that after commit cccb45d7c429 ("sched/deadline: Less agressive
> dl_server handling") there is always a message "sched: DL replenish lagged
> too much" after boot. Then I found this bug, but unfortunately this patch
> cannot wipe the message.

Does

https://lore.kernel.org/lkml/20250615131129.954975-1-kuyo.chang@mediatek.com/

help with the issue?

Thanks,
Juri


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] sched/deadline: Fix dl_server_stopped()
  2025-08-12  9:19 ` Juri Lelli
@ 2025-08-12 10:21   ` Huacai Chen
  0 siblings, 0 replies; 4+ messages in thread
From: Huacai Chen @ 2025-08-12 10:21 UTC (permalink / raw)
  To: Juri Lelli
  Cc: Huacai Chen, Ingo Molnar, Peter Zijlstra, Vincent Guittot,
	Dietmar Eggemann, Steven Rostedt, Ben Segall, Mel Gorman,
	linux-kernel

On Tue, Aug 12, 2025 at 5:19 PM Juri Lelli <juri.lelli@redhat.com> wrote:
>
> Hi,
>
> On 09/08/25 21:04, Huacai Chen wrote:
> > Commit cccb45d7c429 ("sched/deadline: Less agressive dl_server handling")
> > introduces dl_server_stopped(). But it is obvious that dl_server_stopped()
> > should return true if dl_se->dl_server_active is 0.
> >
> > Fixes: cccb45d7c429 ("sched/deadline: Less agressive dl_server handling")
> > Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
>
> This looks correct.
>
> Acked-by: Juri Lelli <juri.lelli@redhat.com>
>
> > ---
> > I found that after commit cccb45d7c429 ("sched/deadline: Less agressive
> > dl_server handling") there is always a message "sched: DL replenish lagged
> > too much" after boot. Then I found this bug, but unfortunately this patch
> > cannot wipe the message.
>
> Does
>
> https://lore.kernel.org/lkml/20250615131129.954975-1-kuyo.chang@mediatek.com/
>
> help with the issue?
Yes, this patch can solve my problem.

Huacai

>
> Thanks,
> Juri
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [tip: sched/urgent] sched/deadline: Fix dl_server_stopped()
  2025-08-09 13:04 [PATCH] sched/deadline: Fix dl_server_stopped() Huacai Chen
  2025-08-12  9:19 ` Juri Lelli
@ 2025-08-27  6:45 ` tip-bot2 for Huacai Chen
  1 sibling, 0 replies; 4+ messages in thread
From: tip-bot2 for Huacai Chen @ 2025-08-27  6:45 UTC (permalink / raw)
  To: linux-tip-commits; +Cc: Huacai Chen, Peter Zijlstra (Intel), x86, linux-kernel

The following commit has been merged into the sched/urgent branch of tip:

Commit-ID:     4717432dfd99bbd015b6782adca216c6f9340038
Gitweb:        https://git.kernel.org/tip/4717432dfd99bbd015b6782adca216c6f9340038
Author:        Huacai Chen <chenhuacai@loongson.cn>
AuthorDate:    Sat, 09 Aug 2025 21:04:19 +08:00
Committer:     Peter Zijlstra <peterz@infradead.org>
CommitterDate: Tue, 26 Aug 2025 10:46:00 +02:00

sched/deadline: Fix dl_server_stopped()

Commit cccb45d7c429 ("sched/deadline: Less agressive dl_server handling")
introduces dl_server_stopped(). But it is obvious that dl_server_stopped()
should return true if dl_se->dl_server_active is 0.

Fixes: cccb45d7c429 ("sched/deadline: Less agressive dl_server handling")
Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lkml.kernel.org/r/20250809130419.1980742-1-chenhuacai@loongson.cn
---
 kernel/sched/deadline.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/sched/deadline.c b/kernel/sched/deadline.c
index e2d51f4..bb813af 100644
--- a/kernel/sched/deadline.c
+++ b/kernel/sched/deadline.c
@@ -1611,7 +1611,7 @@ void dl_server_stop(struct sched_dl_entity *dl_se)
 static bool dl_server_stopped(struct sched_dl_entity *dl_se)
 {
 	if (!dl_se->dl_server_active)
-		return false;
+		return true;
 
 	if (dl_se->dl_server_idle) {
 		dl_server_stop(dl_se);

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2025-08-27  6:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-09 13:04 [PATCH] sched/deadline: Fix dl_server_stopped() Huacai Chen
2025-08-12  9:19 ` Juri Lelli
2025-08-12 10:21   ` Huacai Chen
2025-08-27  6:45 ` [tip: sched/urgent] " tip-bot2 for Huacai Chen

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).