Re: [PATCH 2/2] cpufreq: simplify cpufreq_set_policy() interface

From: Viresh Kumar
Date: Wed Aug 20 2025 - 01:48:15 EST


On 20-08-25, 13:42, Zihuan Zhang wrote:
> You’re right, we didn’t really consider that case before.
>
> The interface of cpufreq_set_policy() does look a bit odd:
>
> - drivers using governors don’t really need the new_pol parameter
>
> - while drivers using the setpolicy method don’t need the new_gov one.

Right, one argument is _always_ unused. If we could have handled that via a
single argument, it would have been nice.

> I guess this might be due to some historical reasons.
>
> The question is whether it’s worth modifying this function, or if we should
> just keep it as it is.

Unless there is a better way :)

--
viresh