Re: [PATCH 5/5] powercap/drivers/dtpm: Scale the power with the load

2021-03-09 Thread Lukasz Luba
On 3/9/21 7:03 PM, Daniel Lezcano wrote: Hi Lukasz, thanks for your comments, one question below. On 09/03/2021 11:01, Lukasz Luba wrote: [ ... ]   +static u64 scale_pd_power_uw(struct cpumask *cpus, u64 power) renamed 'cpus' into 'pd_mask', see below +{ +    unsigned long max, util

Re: [PATCH 5/5] powercap/drivers/dtpm: Scale the power with the load

2021-03-09 Thread Daniel Lezcano
On 09/03/2021 11:01, Lukasz Luba wrote: > Hi Daniel, > > I've started reviewing the series, please find some comments below. > > On 3/1/21 9:21 PM, Daniel Lezcano wrote: >> Currently the power consumption is based on the current OPP power >> assuming the entire performance domain is fully loaded.

Re: [PATCH 5/5] powercap/drivers/dtpm: Scale the power with the load

2021-03-09 Thread Daniel Lezcano
Hi Lukasz, thanks for your comments, one question below. On 09/03/2021 11:01, Lukasz Luba wrote: [ ... ] >>   +static u64 scale_pd_power_uw(struct cpumask *cpus, u64 power) > > renamed 'cpus' into 'pd_mask', see below > >> +{ >> +    unsigned long max, util; >> +    int cpu, load = 0; > >

Re: [PATCH 5/5] powercap/drivers/dtpm: Scale the power with the load

2021-03-09 Thread Lukasz Luba
Hi Daniel, I've started reviewing the series, please find some comments below. On 3/1/21 9:21 PM, Daniel Lezcano wrote: Currently the power consumption is based on the current OPP power assuming the entire performance domain is fully loaded. That gives very gross power estimation and we can do

[PATCH 5/5] powercap/drivers/dtpm: Scale the power with the load

2021-03-01 Thread Daniel Lezcano
Currently the power consumption is based on the current OPP power assuming the entire performance domain is fully loaded. That gives very gross power estimation and we can do much better by using the load to scale the power consumption. Use the utilization to normalize and scale the power usage o