[igt-dev] [PATCH i-g-t 3/4] tests/gem_ctx_freq: Disable SLPC efficient freq for the test

Umesh Nerlige Ramappa umesh.nerlige.ramappa at intel.com
Wed Jun 7 21:35:01 UTC 2023


On Mon, Jun 05, 2023 at 06:21:49PM -0700, Ashutosh Dixit wrote:
>When SLPC efficient freq is enabled, GPU frequencies can be outside the
>min/max range set from sysfs. Any test which compares actual GPU frequency
>against set frequencies is therefore meaninful only when SLPC efficient

typo: meaningful

>freq is disabled.
>
>Bug: https://gitlab.freedesktop.org/drm/intel/-/issues/6786
>Signed-off-by: Ashutosh Dixit <ashutosh.dixit at intel.com>
>---
> tests/i915/gem_ctx_freq.c | 15 ++++++++++++++-
> 1 file changed, 14 insertions(+), 1 deletion(-)
>
>diff --git a/tests/i915/gem_ctx_freq.c b/tests/i915/gem_ctx_freq.c
>index b2f6c2af55e1..6dfcf4187d4b 100644
>--- a/tests/i915/gem_ctx_freq.c
>+++ b/tests/i915/gem_ctx_freq.c
>@@ -131,6 +131,15 @@ static bool get_sysfs_freq(int dirfd, uint32_t *min, uint32_t *max)
> 		igt_sysfs_rps_scanf(dirfd, RPS_MAX_FREQ_MHZ, "%u", max) == 1);
> }
>
>+static void slpc_ignore_efficient_freq(int dirfd, bool val)
>+{
>+	if (!(gem_using_guc_submission(i915) && i915_is_slpc_enabled(i915)))
>+		return;

I think i915_is_slpc_enabled(i915) should be enough here, since 
intel_guc_debugfs_register() in kmd does not create "guc_slpc_info" if 
guc is not enabled.

Regards,
Umesh



More information about the igt-dev mailing list