All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Anirban, Sk" <sk.anirban@intel.com>
To: Vinay Belgaumkar <vinay.belgaumkar@intel.com>,
	<intel-gfx@lists.freedesktop.org>,
	<igt-dev@lists.freedesktop.org>
Subject: Re: [PATCH v2 i-g-t 2/2] tests/xe_gt_freq: Disable efficient freq using sysfs
Date: Thu, 3 Dec 2026 23:32:57 +0530	[thread overview]
Message-ID: <bf185074-aa3a-4d27-8d75-01dcad531dc2@intel.com> (raw)
In-Reply-To: <20261113021149.3941522-4-vinay.belgaumkar@intel.com>

Hi Vinay,

On 13-11-2026 07:41, Vinay Belgaumkar wrote:
> With a sysfs interface available to disable RPe now, we should disable RPe
> and then proceed with the test. Before this sysfs was added, reducing min
> freq below RPe would automatically disable RPe. Now that we have a dedicated
> sysfs interface, use it. Tests that reduce GT freq below RPe should now
> directly disable RPe instead.

Please use tests/intel in the subject line.

>
> v2: Init ptr to NULL (Anirban)
>
> Cc: Sk Anirban <sk.anirban@intel.com>
> Signed-off-by: Vinay Belgaumkar <vinay.belgaumkar@intel.com>
> ---
>   tests/intel/xe_gt_freq.c | 12 ++++++++++++
>   1 file changed, 12 insertions(+)
>
> diff --git a/tests/intel/xe_gt_freq.c b/tests/intel/xe_gt_freq.c
> index ab1c30ea1..8a03f286d 100644
> --- a/tests/intel/xe_gt_freq.c
> +++ b/tests/intel/xe_gt_freq.c
> @@ -387,6 +387,7 @@ int igt_main()
>   	struct drm_xe_engine_class_instance *hwe;
>   	uint32_t *stash_min, *stash_max;
>   	int max_gt;
> +	u32 *stash_use_rpe = NULL;
>   
>   	igt_fixture() {
>   		fd = drm_open_driver(DRIVER_XE);
> @@ -397,10 +398,17 @@ int igt_main()
>   		/* The defaults are the same. Stashing the gt0 is enough */
>   		stash_min = (uint32_t *) malloc(sizeof(uint32_t) * (max_gt + 1));
>   		stash_max = (uint32_t *) malloc(sizeof(uint32_t) * (max_gt + 1));
> +		if (xe_sysfs_gt_has_node(fd, 0, "freq0/use_rpe"))
> +			stash_use_rpe = (uint32_t *) malloc(sizeof(uint32_t) * (max_gt + 1));
>   
>   		xe_for_each_gt(fd, gt) {
>   			stash_min[gt] = xe_gt_get_freq(fd, gt, "min");
>   			stash_max[gt] = xe_gt_get_freq(fd, gt, "max");
> +			/* Disable use of efficient freq */
> +			if (stash_use_rpe) {
> +				stash_use_rpe[gt] = xe_gt_get_use_rpe(fd, gt);
> +				xe_gt_set_use_rpe(fd, gt, 0);
> +			}
>   		}
>   		errno = 0;
>   	}
> @@ -481,9 +489,13 @@ int igt_main()
>   		xe_for_each_gt(fd, gt) {
>   			xe_gt_set_freq(fd, gt, "max", stash_max[gt]);
>   			xe_gt_set_freq(fd, gt, "min", stash_min[gt]);
> +			if (stash_use_rpe)
> +				xe_gt_set_use_rpe(fd, gt, stash_use_rpe[gt]);
>   		}
>   		free(stash_min);
>   		free(stash_max);
> +		if (stash_use_rpe)
> +			free(stash_use_rpe);
>   		drm_close_driver(fd);
>   	}
>   }
with that
Reviewed-by: Sk Anirban <sk.anirban@intel.com>

  reply	other threads:[~2026-12-03 18:03 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-13  2:11 [PATCH v2 i-g-t 1/2] lib/xe_gt: Add function to toggle efficient freq Vinay Belgaumkar
2026-11-13  2:11 ` [PATCH v2 i-g-t 2/2] tests/xe_gt_freq: Disable efficient freq using sysfs Vinay Belgaumkar
2026-12-03 18:02   ` Anirban, Sk [this message]
2026-11-13  3:38 ` ✓ Xe.CI.BAT: success for series starting with [v2,i-g-t,1/2] lib/xe_gt: Add function to toggle efficient freq Patchwork
2026-11-13  3:57 ` ✓ i915.CI.BAT: " Patchwork
2026-11-13 16:44 ` ✓ Xe.CI.FULL: " Patchwork
2026-11-14  8:06 ` ✗ i915.CI.Full: failure " Patchwork
2026-11-17 14:19 ` [PATCH v2 i-g-t 1/2] " Kamil Konieczny
2026-11-19  0:15   ` Belgaumkar, Vinay
2026-12-03 17:38 ` Anirban, Sk
2026-12-03 22:37   ` Belgaumkar, Vinay

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=bf185074-aa3a-4d27-8d75-01dcad531dc2@intel.com \
    --to=sk.anirban@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=vinay.belgaumkar@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.