[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aOVd7q9bNwENTchb@gpd4>
Date: Tue, 7 Oct 2025 20:37:34 +0200
From: Andrea Righi <arighi@...dia.com>
To: Tejun Heo <tj@...nel.org>
Cc: David Vernet <void@...ifault.com>, Changwoo Min <changwoo@...lia.com>,
linux-kernel@...r.kernel.org, sched-ext@...ts.linux.dev
Subject: Re: [PATCH 3/4] sched_ext: Wrap kfunc args in struct to prepare for
aux__prog
On Tue, Oct 07, 2025 at 08:24:02AM -1000, Tejun Heo wrote:
> Hello,
>
> On Tue, Oct 07, 2025 at 11:48:44AM +0200, Andrea Righi wrote:
> > > +struct scx_bpf_dsq_insert_vtime_args {
> > > + /* @p can't be packed together as KF_RCU is not transitive */
> > > + u64 dsq_id;
> > > + u64 slice;
> > > + u64 vtime;
> > > + u64 enq_flags;
> > > +};
> >
> > With PATCH 2/4 introducing scx_bpf_task_set_slice() and
> > scx_bpf_task_set_dsq_vtime(), would it be reasonable to use those to set
> > these task properties and then completely get rid of these args in
> > scx_bpf_dsq_insert[_vtime]()?
>
> Maybe. However, the most common usage pattern is setting vtime and slice on
> insertion, so I think it makes sense to have a shortcut interface for that.
> Even if the overhead difference is negligible, it's nice to have a dedicated
> interface for the most common use case.
Yes, after talking about this during office hours, I agree that it's useful
to be able to set both vtime and slice when inserting a task. While the
overhead is likely negligible, it could still impact hot paths, so:
Acked-by: Andrea Righi <arighi@...dia.com>
Thanks,
-Andrea
Powered by blists - more mailing lists