drm/i915: Use max(render, media) for Baytrail busyness calculation
authorChris Wilson <chris@chris-wilson.co.uk>
Thu, 9 Mar 2017 21:12:31 +0000 (21:12 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Fri, 10 Mar 2017 14:28:44 +0000 (14:28 +0000)
commit569884e3d47d54d943c13eb14d653a6100937f14
treeb46938c28a6314683e88dcaf7e6b67b40985eefd
parente0e8c7cb6eb68e9256de2d8cbeb481d3701c05ac
drm/i915: Use max(render, media) for Baytrail busyness calculation

Currently, we sum the render and media cycles (on different engines) to
compute a percentage - but we fail to factor in the duplication into the
threshold calculations. This makes us very eager to upclock!

If we just consider the maximum busy cycles of either counter, we should
have an accurate reflection on whether there are cycles to spare to
handle the workload at this frequency.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20170309211232.28878-2-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/i915_irq.c