mirror of
https://github.com/tiagovignatti/intel-gpu-tools.git
synced 2025-06-10 01:16:18 +00:00
overlay: Sample power every second
Found the bug, but still only read the msr once every second - mainly as an exercise in handling different sample rates. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
parent
c888507b68
commit
c6482b7814
@ -75,7 +75,7 @@ int power_update(struct power *power)
|
||||
return EAGAIN;
|
||||
|
||||
d_time = s->timestamp - d->timestamp;
|
||||
if (d_time < 1200) { /* HW sample rate seems to be stable ~1Hz */
|
||||
if (d_time < 900) { /* HW sample rate seems to be stable ~1Hz */
|
||||
power->count--;
|
||||
return power->count <= 1 ? EAGAIN : 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user