# Re: \[PATCH v2 1/5\] arch\_topology: Introduce thermal pressure update function

- From: Dietmar Eggemann \<dietmar.eggemann@arm.com\>
- Date: 2021-10-27 13:35:25 
- List: linux-arm-kernel
- Page: https://ratatoskr.run/linux-arm-kernel/2021/10/1555690
- Thread: https://ratatoskr.run/linux-pm/2021/10/1543491/t.md

```text
On 27/10/2021 10:56, Lukasz Luba wrote:
> Hi Dietmar,
> 
> Thank you for having a look at this.
> 
> On 10/26/21 5:51 PM, Dietmar Eggemann wrote:
>> On 15/10/2021 16:45, Lukasz Luba wrote:

[...]

>>> +void topology_thermal_pressure_update(const struct cpumask *cpus,
>>> +                      unsigned long capped_freq)
>>> +{
>>
>> ... why not just s/unsigned long th_pressure/unsigned long capped_freq
>> in existing topology_set_thermal_pressure() and move code the
>> frequency/capacity conversion in there? The patch set will become
>> considerably smaller.
> 
> I've been trying to avoid confusion when changing actually behavior
> of the API function. Thus, introducing new would IMO opinion
> make sure the old 'set' function was expecting proper pressure
> value, while the new 'update' expects frequency.
> 
> I agree that the patch set would be smaller in that case, but I'm
> not sure if that would not hide some issues. This one would
> definitely break compilation of some vendor modules (or drivers
> queuing or under review), not silently passing them through (with wrong
> argument).

I see, since the parameter type list would stay the same, this could
potentially happen.

[...]

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
```
