Re: [RFC PATCH v3 04/10] sched/fair: Introduce sched_throttle_work

Peter Zijlstra
2024-07-12T15:22:09Z

On Thu, Jul 11, 2024 at 02:59:58PM +0200, Valentin Schneider wrote:

> +void init_cfs_throttle_work(struct task_struct *p)
> +{
> + /* Protect against double add, see throttle_cfs_rq() and throttle_cfs_rq_work() */
> + p->sched_throttle_work.next = &p->sched_throttle_work;
> + init_task_work(&p->sched_throttle_work, throttle_cfs_rq_work);

Yes, init_task_work() does not write .next, but can we please flip these
two statements and avoid me having to double check that every time I
seem them? :-)

> +}