On Tue, Feb 11, 2025 at 01:54:44PM +0100, Gabriele Monaco wrote:

> > > +void do_trace_set_current_state(int state_value)
> > > +{
> > > + trace_sched_set_state_tp(current, current->__state, state_value);
> > 
> > Should this be:
> > 
> >  __do_trace_sched_set_state_tp() ?
> > 
> 
> Mmh, you mean avoiding the static_branch_unlikely in the helper
> function, since it's supposed to be used before calling it?

Yep, seems pointless to repeat that.

> > > +}
> > > +EXPORT_SYMBOL(do_trace_set_current_state);
> > 
> > _GPL
> > 
> 
> I'm absolutely not against this change but, out of curiosity, would
> that imply non-GPL modules are not going to be able to sleep going
> forward? At least not using this pattern.

Bah, you're right. Killing non-GPL modules seems like a worthy goal
though, but perhaps another day ;-)

Reply via email to