public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Andrea Righi <andrea.righi@linux.dev>
To: Tejun Heo <tj@kernel.org>
Cc: David Vernet <void@manifault.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Ingo Molnar <mingo@redhat.com>,
	Juri Lelli <juri.lelli@redhat.com>,
	Vincent Guittot <vincent.guittot@linaro.org>,
	Dietmar Eggemann <dietmar.eggemann@arm.com>,
	Steven Rostedt <rostedt@goodmis.org>,
	Ben Segall <bsegall@google.com>, Mel Gorman <mgorman@suse.de>,
	Valentin Schneider <vschneid@redhat.com>,
	linux-kernel@vger.kernel.org, bpf@vger.kernel.org
Subject: Re: [PATCH v2] sched_ext: Trigger ops.update_idle() from pick_task_idle()
Date: Tue, 15 Oct 2024 07:21:49 +0200	[thread overview]
Message-ID: <Zw377f2g1JnIYNSu@gpd3> (raw)
In-Reply-To: <Zw3BcEWQQVLxcrOp@slm.duckdns.org>

On Mon, Oct 14, 2024 at 03:12:16PM -1000, Tejun Heo wrote:
> Hello,
> 
> On Tue, Oct 15, 2024 at 12:06:03AM +0200, Andrea Righi wrote:
> > @@ -459,13 +459,13 @@ static void put_prev_task_idle(struct rq *rq, struct task_struct *prev, struct t
> >  static void set_next_task_idle(struct rq *rq, struct task_struct *next, bool first)
> >  {
> >  	update_idle_core(rq);
> > -	scx_update_idle(rq, true);
> >  	schedstat_inc(rq->sched_goidle);
> >  	next->se.exec_start = rq_clock_task(rq);
> >  }
> >  
> >  struct task_struct *pick_task_idle(struct rq *rq)
> >  {
> > +	scx_update_idle(rq, true);
> 
> Thanks a lot for debugging this. Both the analysis and solution make sense
> to me. However, as this puts scx_update_idle() in a different place from
> other idle handling functions, can you please add a comment explaining why
> it needs to be in pick_task_idle() instead of set_next_task_idle()?
> 
> Thanks.

Sure, I'll send a v3 with a proper comment.

Thanks,
-Andrea

> 
> -- 
> tejun

  reply	other threads:[~2024-10-15  5:21 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-14 22:06 [PATCH v2] sched_ext: Trigger ops.update_idle() from pick_task_idle() Andrea Righi
2024-10-15  1:12 ` Tejun Heo
2024-10-15  5:21   ` Andrea Righi [this message]
2024-10-15  7:45 ` Peter Zijlstra
2024-10-15  8:46   ` Andrea Righi

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=Zw377f2g1JnIYNSu@gpd3 \
    --to=andrea.righi@linux.dev \
    --cc=bpf@vger.kernel.org \
    --cc=bsegall@google.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=juri.lelli@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=tj@kernel.org \
    --cc=vincent.guittot@linaro.org \
    --cc=void@manifault.com \
    --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