Thread (18 messages) 18 messages, 5 authors, 2020-09-24

Re: is 'dynamic-power-coefficient' expected to be based on 'real' power measurements?

From: Doug Anderson <dianders@chromium.org>
Date: 2020-09-15 19:53:36
Also in: linux-pm

Hi,

On Mon, Sep 14, 2020 at 10:44 PM Rajendra Nayak [off-list ref] wrote:
Hi Rob,

There has been some discussions on another thread [1] around the DPC (dynamic-power-coefficient) values
for CPU's being relative vs absolute (based on real power) and should they be used to derive 'real' power
at various OPPs in order to calculate things like 'sustainable-power' for thermal zones.
I believe relative values work perfectly fine for scheduling decisions, but with others using this for
calculating power values in mW, is there a need to document the property as something that *has* to be
based on real power measurements?

Looking at the bindings,

   dynamic-power-coefficient:
     $ref: '/schemas/types.yaml#/definitions/uint32'
     description:
       A u32 value that represents the running time dynamic
       power coefficient in units of uW/MHz/V^2. The
       coefficient can either be calculated from power
       measurements or derived by analysis.

       The dynamic power consumption of the CPU  is
       proportional to the square of the Voltage (V) and
       the clock frequency (f). The coefficient is used to
       calculate the dynamic power as below -

       Pdyn = dynamic-power-coefficient * V^2 * f

       where voltage is in V, frequency is in MHz.

.. the 'can either be calculated from power measurements or derived by analysis'
tells me we don't mandate that this be based on real power measurements.
If we do, then perhaps that needs to be mentioned explicitly?
To me, the phrase "derived by analysis" doesn't mean that the number
is allowed to be in completely made up units.  It means it's still
supposed to be in the same units but it's OK if you didn't integrate a
Coulomb counter into your system.

It's kinda like saying that the police can give you a speeding ticket
by either measuring your speed with a radar gun or by checking a clock
when your car passed two known places and calculating your speed based
on that.  The radar gun is a direct measurement whereas the other is
derived by analysis.  In both cases you're still talking about a speed
in terms of Miles per Hour (or kilometers per hour in more sane
countries).

-Doug
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help