From: Umesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com>
To: igt-dev@lists.freedesktop.org, marcin.bernatowicz@intel.com,
soham.purkait@intel.com
Subject: [PATCH] tests/intel/xe_pmu: Fix test to accept single VF configs
Date: Mon, 28 Sep 2026 11:57:18 -0700 [thread overview]
Message-ID: <20260928185717.2846223-2-umesh.nerlige.ramappa@intel.com> (raw)
Some platforms my support just one VF, so remove the need for 2 VFs in
the tests.
Signed-off-by: Umesh Nerlige Ramappa <umesh.nerlige.ramappa@intel.com>
---
tests/intel/xe_pmu.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/tests/intel/xe_pmu.c b/tests/intel/xe_pmu.c
index 364e643fe5bb..d41ebba1faef 100644
--- a/tests/intel/xe_pmu.c
+++ b/tests/intel/xe_pmu.c
@@ -982,7 +982,7 @@ static void test_gt_frequency(int fd, struct drm_xe_engine_class_instance *eci)
static unsigned int enable_and_provision_vfs(int fd)
{
- unsigned int num_vfs, vf;
+ unsigned int num_vfs, vf, total_vfs;
uint32_t pf_exec_quantum_ms = 64, vf_exec_quantum_ms = 32;
uint32_t pf_preempt_timeout_us = 64000, vf_preempt_timeout_us = 32000;
@@ -995,11 +995,13 @@ static unsigned int enable_and_provision_vfs(int fd)
NULL);
autoprobe = igt_sriov_is_driver_autoprobe_enabled(fd);
+ total_vfs = igt_sriov_get_total_vfs(fd);
+ num_vfs = total_vfs > 2 ? 2 : total_vfs;
+
/* Enable VF's */
igt_sriov_disable_driver_autoprobe(fd);
- igt_sriov_enable_vfs(fd, 2);
- num_vfs = igt_sriov_get_enabled_vfs(fd);
- igt_require(num_vfs == 2);
+ igt_sriov_enable_vfs(fd, num_vfs);
+ igt_require(igt_sriov_get_enabled_vfs(fd) == num_vfs);
/* Set 32ms for VF execution quantum and 64ms for PF execution quantum */
xe_sriov_admin_bulk_set_exec_quantum_ms(fd, vf_exec_quantum_ms);
--
2.53.0
next reply other threads:[~2026-09-28 18:58 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-28 18:57 Umesh Nerlige Ramappa [this message]
2026-09-28 22:19 ` ✓ Xe.CI.BAT: success for tests/intel/xe_pmu: Fix test to accept single VF configs Patchwork
2026-09-28 22:35 ` ✓ i915.CI.BAT: " Patchwork
2026-09-29 4:18 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-10-01 21:19 ` Umesh Nerlige Ramappa
2026-09-29 7:10 ` ✗ i915.CI.Full: " Patchwork
2026-10-01 10:31 ` [PATCH] " Bernatowicz, Marcin
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=20260928185717.2846223-2-umesh.nerlige.ramappa@intel.com \
--to=umesh.nerlige.ramappa@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=marcin.bernatowicz@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