Re: [PATCH] cpufreq/schedutil: When updating limitations, frequency modulation interval not become invalid.

From: Viresh Kumar
Date: Mon Feb 05 2024 - 03:54:57 EST


On 05-02-24, 16:33, lizhe wrote:
> HI:
> I think not.
> It will cause the following changes:
> limits_changed in sugov_limit() is set to true.
> This will cause the modulation interval to be invalid.
> The system modulation will ignore the modulation interval.
> A modulation request will be initiated immediately.
>
>
> As shown below :
> sugov_should_update_freq(...)
> {
> if (unlikely(sg_policy->limits_changed)) {
> ....
> return true;
> }
> }
>
> Repeatedly setting the schedutil modulation policy causes the modulation interval to be invalid.
> Why is this necessary ?

This is the penalty being paid to keep the interface simple and consistent.
Playing with sysfs can do such minor things.

--
viresh