Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Belgaumkar, Vinay" <vinay.belgaumkar@intel.com>
To: Sk Anirban <sk.anirban@intel.com>, <igt-dev@lists.freedesktop.org>
Cc: <anshuman.gupta@intel.com>, <badal.nilawar@intel.com>,
	<riana.tauro@intel.com>, <karthik.poosa@intel.com>,
	<raag.jadav@intel.com>, <soham.purkait@intel.com>,
	<mallesh.koujalagi@intel.com>
Subject: Re: [PATCH] tests/xe_pmu: Fix gt-frequency failure with raised min freq
Date: Wed, 17 Jun 2026 10:32:52 -0700	[thread overview]
Message-ID: <11d084b2-d028-478d-a48a-e0ef21975b76@intel.com> (raw)
In-Reply-To: <20260616193656.2131881-2-sk.anirban@intel.com>


On 6/16/2026 12:36 PM, Sk Anirban wrote:
> The gt-frequency subtest can fail when the min frequency has
> already been raised above RPn before the test begins. Using that
> value as the original minimum prevents the later min_freq write
> from enabling the GuC ignore_efficient_freq parameter, so min_freq
> can keep moving toward RPe.
>
> Save RPn as the minimum baseline instead, ensuring the min_freq
> write enables ignore_efficient_freq and the final restore check
> returns min_freq to RPn.
It'll be good to mention RPe fluctuates dynamically based on thermal 
conditions, so better to test with RPn, which is fixed.
>
> Closes:https://gitlab.freedesktop.org/drm/xe/kernel/issues/8344
> Signed-off-by: Sk Anirban <sk.anirban@intel.com>
> ---
>   tests/intel/xe_pmu.c | 8 ++------
>   1 file changed, 2 insertions(+), 6 deletions(-)
>
> diff --git a/tests/intel/xe_pmu.c b/tests/intel/xe_pmu.c
> index fb4b871e7..4bbc801a1 100644
> --- a/tests/intel/xe_pmu.c
> +++ b/tests/intel/xe_pmu.c
> @@ -903,10 +903,8 @@ static void test_gt_frequency(int fd, struct drm_xe_engine_class_instance *eci)
>   	unsigned long config_rq_freq, config_act_freq;
>   	double min[2], max[2];
>   	uint32_t gt = eci->gt_id;
> -	uint32_t orig_min = xe_gt_get_freq(fd, eci->gt_id, "min");
> +	uint32_t orig_min = xe_gt_get_freq(fd, eci->gt_id, "rpn");
>   	uint32_t orig_max = xe_gt_get_freq(fd, eci->gt_id, "max");
> -	uint32_t current_min;
> -	uint32_t orig_rpe;
>   	uint32_t vm;
>   	int pmu_fd[2];
>   
> @@ -956,9 +954,7 @@ static void test_gt_frequency(int fd, struct drm_xe_engine_class_instance *eci)
>   	 * Restore min/max.
>   	 */
>   	igt_assert(xe_gt_set_freq(fd, gt, "min", orig_min) > 0);
> -	orig_rpe = xe_gt_get_freq(fd, gt, "rpe");
> -	current_min = xe_gt_get_freq(fd, gt, "min");
> -	igt_assert(current_min == orig_min || current_min == orig_rpe);
> +	igt_assert(xe_gt_get_freq(fd, gt, "min") == orig_min);

LGTM,

Reviewed-by: Vinay Belgaumkar <vinay.belgaumkar@intel.com>

>   
>   	igt_info("Minimum frequency: requested %.1f, actual %.1f\n",
>   		 min[0], min[1]);

      parent reply	other threads:[~2026-06-17 17:33 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-16 19:36 [PATCH] tests/xe_pmu: Fix gt-frequency failure with raised min freq Sk Anirban
2026-06-17  1:08 ` ✓ Xe.CI.BAT: success for " Patchwork
2026-06-17  1:43 ` ✓ i915.CI.BAT: " Patchwork
2026-06-17  7:00 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-06-17 17:32 ` Belgaumkar, Vinay [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=11d084b2-d028-478d-a48a-e0ef21975b76@intel.com \
    --to=vinay.belgaumkar@intel.com \
    --cc=anshuman.gupta@intel.com \
    --cc=badal.nilawar@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=karthik.poosa@intel.com \
    --cc=mallesh.koujalagi@intel.com \
    --cc=raag.jadav@intel.com \
    --cc=riana.tauro@intel.com \
    --cc=sk.anirban@intel.com \
    --cc=soham.purkait@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox