diff options
author | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2020-03-02 17:39:39 +0300 |
---|---|---|
committer | Ville Syrjälä <ville.syrjala@linux.intel.com> | 2020-05-14 19:59:53 +0300 |
commit | 56f1b31f1dd60db4b02024a13eea45b5bbccc44e (patch) | |
tree | 4a4425bfa32f95cb3ba2230d141b9279cf8b4fc0 /drivers/gpu/drm/i915/selftests | |
parent | 2e2701582a8039b2f8a2fa811237ac8ec98355fa (diff) | |
download | linux-56f1b31f1dd60db4b02024a13eea45b5bbccc44e.tar.xz |
drm/i915: Store CS timestamp frequency in Hz
kHz isn't accurate enough for storing the CS timestamp
frequency on some of the platforms. Store the value
in Hz instead.
Cc: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200302143943.32676-2-ville.syrjala@linux.intel.com
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/selftests')
-rw-r--r-- | drivers/gpu/drm/i915/selftests/i915_perf.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/selftests/i915_perf.c b/drivers/gpu/drm/i915/selftests/i915_perf.c index ca0c9dbab713..5edfcfd42a31 100644 --- a/drivers/gpu/drm/i915/selftests/i915_perf.c +++ b/drivers/gpu/drm/i915/selftests/i915_perf.c @@ -262,8 +262,8 @@ static int live_noa_delay(void *arg) delay = intel_read_status_page(stream->engine, 0x102); delay -= intel_read_status_page(stream->engine, 0x100); - delay = div_u64(mul_u32_u32(delay, 1000 * 1000), - RUNTIME_INFO(i915)->cs_timestamp_frequency_khz); + delay = div_u64(mul_u32_u32(delay, 1000000000), + RUNTIME_INFO(i915)->cs_timestamp_frequency_hz); pr_info("GPU delay: %uns, expected %lluns\n", delay, expected); |