Re: [PATCH v2] sched_ext: Trigger ops.update_idle() from pick_task_idle()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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




[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux