diff options
author | Mika Kuoppala <[email protected]> | 2015-11-13 19:29:41 +0200 |
---|---|---|
committer | Jani Nikula <[email protected]> | 2015-11-16 15:25:34 +0200 |
commit | 500a3d2eb3883b71350036e15aad286cc6e5df21 (patch) | |
tree | e8b6187be07b5175ef4980caab7c506fe84606b2 /tools/perf/scripts/python/call-graph-from-postgresql.py | |
parent | 1b9448b071caa7d10bb2569fabe3020a2c25ae59 (diff) |
drm/i915: Fix GT frequency rounding
When we set and later readback a frequency value through
sysfs interface, igt/pm_rpm assumes that we get same value back
if it matches hw granularity.
On bxt we have found out that this is not always the case.
Currently frequency - hw ratio - frequency conversions round down,
with few exceptions on platforms that have more specific conversions.
On bxt the supported range can be for example from 100Mhz to 650Mhz.
Midpoint is then calculated by test to be 375 which pm_rps uses to find a
closest hw supported frequency. That is 366 (ratio 22),
which it then writes back. But as the rounding down kicks in,
driver actually sets 350 instead of 366, as 366 is 2/3 below 22 * 50/3.
Fix this by rounding to closest instead of rounding down in
freq-ratio-freq conversions.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=92768
Testcase: igt/pm_rps/basic-api
Tested-by: Bob Paauwe <[email protected]>
Cc: Bob Paauwe <[email protected]>
Signed-off-by: Imre Deak <[email protected]>
Signed-off-by: Mika Kuoppala <[email protected]>
Reviewed-by: Ville Syrjälä <[email protected]>
Reviewed-by: Bob Paauwe <[email protected]>
Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
Signed-off-by: Jani Nikula <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/call-graph-from-postgresql.py')
0 files changed, 0 insertions, 0 deletions