Re: [PATCH v2 3/6] cpufreq: schedutil: ensure max frequency while running RT/DL tasks
From: Joel Fernandes
Date: Fri Jul 07 2017 - 01:26:43 EST
On Wed, Jul 5, 2017 at 6:41 AM, Patrick Bellasi <patrick.bellasi@xxxxxxx> wrote:
>> But what about clearing the sched-class's flag from .pick_next_task() callback
>> when they return NULL ?
>> What about something like this instead (completely untested), with which we
>> don't need the 2/3 patch as well:
> Just had a fast check but I think something like that can work.
> We had an internal discussion with Brendan (in CC now) which had a
> similar proposal.
> Main counter arguments for me was:
> 1. we wanna to reduce the pollution of scheduling classes code with
> schedutil specific code, unless strictly necessary
> 2. we never had a "clear bit" semantics for flags updates
> Thus this proposal seemed to me less of a discontinuity wrt the
> current interface. However, something similar to what you propose
> below should also work. Let's collect some more feedback...
I was going to say something similar. I feel its much cleaner if the
scheduler clears the flags that it set, thus taking "ownership" of the
flag. I feel that will avoid complication like this where the governor
has to peek into what's currently running and such (and also help with
the suggestion I made for patch 2/3.
Maybe the interface needs an extension for "clear flag" semantics?