mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: albin_yang@163.com
To: peterz@infradead.org
Cc: mingo@redhat.com, juri.lelli@redhat.com,
	vincent.guittot@linaro.org, dietmar.eggemann@arm.com,
	rostedt@goodmis.org, bsegall@google.com, mgorman@suse.de,
	vschneid@redhat.com, kprateek.nayak@amd.com, chen.yu@linux.dev,
	kayracizmeci@gmail.com, mintaohuang@tencent.com,
	linux-kernel@vger.kernel.org, albin_yang@163.com,
	albinwyang@tencent.com
Subject: Re: [PATCH v3] sched/stats: Fix run_delay over-count for migrated sched_delayed tasks
Date: Mon, 12 Oct 2026 12:26:22 +0800	[thread overview]
Message-ID: <20261012042622.1488555-1-albin_yang@163.com> (raw)
In-Reply-To: <20260922082432.2987855-1-albin_yang@163.com>

Hi Peter,

Just a gentle ping in case this got buried -- it's been a few weeks since v3.
Happy to change whatever you think is needed.

To recap: proxy exec does seem to have the same re-arm problem, but I don't
think t->is_blocked can gate it -- in ttwu_runnable() the real wakeup enqueue
sits inside the if (p->is_blocked) branch, while is_blocked is cleared
afterwards in ttwu_do_wakeup(), so !is_blocked would suppress the very re-arm
this patch relies on. And I don't think task_is_blocked() can replace
se.sched_delayed either, since a delayed sleeper has no blocked_on.

One more point: the bug predates proxy exec -- DELAY_DEQUEUE landed in v6.12,
proxy exec only in v6.17. Coupling the fix with task_is_blocked() would tie it
to infrastructure absent before v6.17, so it could no longer be backported
as-is to the v6.12.y..v6.16.y trees where the over-count happens.

So I'd suggest taking this patch as-is (delayed dequeue only) and handling the
proxy exec side separately; if you'd rather cover both here, I'm happy to send
a v4 with !sched_delayed && !task_is_blocked(), though I'd want to reproduce
the proxy case first and re-check Prateek's Tested-by -- just let me know.

Thanks,
Wei Yang


      parent reply	other threads:[~2026-10-12  4:27 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-22  8:24 albin_yang
2026-09-22 10:55 ` Peter Zijlstra
2026-09-22 21:08   ` Kayra Cizmeci
2026-09-23  2:03   ` albin_yang
2026-10-12  4:26 ` albin_yang [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261012042622.1488555-1-albin_yang@163.com \
    --to=albin_yang@163.com \
    --cc=albinwyang@tencent.com \
    --cc=bsegall@google.com \
    --cc=chen.yu@linux.dev \
    --cc=dietmar.eggemann@arm.com \
    --cc=juri.lelli@redhat.com \
    --cc=kayracizmeci@gmail.com \
    --cc=kprateek.nayak@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=mintaohuang@tencent.com \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=vincent.guittot@linaro.org \
    --cc=vschneid@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®