From: "Piotr Piórkowski" <piotr.piorkowski@intel.com>
To: Marcin Bernatowicz <marcin.bernatowicz@linux.intel.com>
Cc: <igt-dev@lists.freedesktop.org>, <lukasz.laguna@intel.com>
Subject: Re: [PATCH v2 i-g-t 1/2] tests/intel/xe_sriov_flr: Add basic FLR subtest
Date: Fri, 27 Feb 2026 17:17:22 +0100 [thread overview]
Message-ID: <20260227161722.vi3tlkeyk5k6eyll@intel.com> (raw)
In-Reply-To: <20260227152734.256604-2-marcin.bernatowicz@linux.intel.com>
Marcin Bernatowicz <marcin.bernatowicz@linux.intel.com> wrote on pią [2026-lut-27 16:27:33 +0100]:
> Add flr-basic subtest intended as a minimal smoke test for the VF reset
> sysfs write path while still using the xe-vfio-pci based synchronization:
> the test skips if xe-vfio-pci binding is disabled, if the xe_vfio_pci
> module is not loaded, or if any VF under test is not bound to
> xe-vfio-pci.
>
> Signed-off-by: Marcin Bernatowicz <marcin.bernatowicz@linux.intel.com>
> Cc: Lukasz Laguna <lukasz.laguna@intel.com>
> Cc: Piotr Piórkowski <piotr.piorkowski@intel.com>
> ---
> v2: Rename flr-reset-only to flr-basic, and adjust commit message. (Piotr)
> ---
> tests/intel/xe_sriov_flr.c | 65 ++++++++++++++++++++++++++++++++++++++
> 1 file changed, 65 insertions(+)
>
> diff --git a/tests/intel/xe_sriov_flr.c b/tests/intel/xe_sriov_flr.c
> index b73727787..2080f4e85 100644
> --- a/tests/intel/xe_sriov_flr.c
> +++ b/tests/intel/xe_sriov_flr.c
> @@ -29,6 +29,12 @@
> * Functionality: FLR
> * Description: Examine behavior of SR-IOV VF FLR
> *
> + * SUBTEST: flr-basic
> + * Run type: BAT
> + * Description:
> + * Initiates FLR without any additional state checks.
> + * Useful as a basic smoke test of the reset sysfs write path.
> + *
> * SUBTEST: flr-vf1-clear
> * Run type: BAT
> * Description:
> @@ -1016,6 +1022,60 @@ static void regs_subcheck_cleanup(struct subcheck_data *data)
> {
> }
>
> +static void reset_only_subcheck_init(struct subcheck_data *data)
> +{
> + if (!g_use_xe_vfio_pci) {
> + set_skip_reason(data, "xe-vfio-pci binding is disabled\n");
> + return;
> + }
> +
> + if (!igt_kmod_is_loaded("xe_vfio_pci"))
> + set_skip_reason(data, "xe_vfio_pci is not loaded\n");
> +}
> +
> +static void reset_only_subcheck_prepare_vf(int vf_id, struct subcheck_data *data)
> +{
> + char *slot = igt_sriov_get_vf_pci_slot_alloc(data->pf_fd, vf_id);
> + char bound[64];
> + int bound_ret;
> +
> + igt_assert(slot);
> +
> + bound_ret = igt_pci_get_bound_driver_name(slot, bound, sizeof(bound));
> + if (bound_ret <= 0 || strcmp(bound, "xe-vfio-pci") != 0)
> + set_skip_reason(data, "VF%u not bound to xe-vfio-pci\n", vf_id);
> +
> + free(slot);
> +}
> +
> +static void noop_subcheck_verify_vf(int vf_id, int flr_vf_id, struct subcheck_data *data)
> +{
> +}
> +
> +static void noop_subcheck_cleanup(struct subcheck_data *data)
> +{
> +}
> +
> +static void reset_only_test(int pf_fd, int num_vfs, flr_exec_strategy exec_strategy)
> +{
> + struct subcheck_data base = {
> + .pf_fd = pf_fd,
> + .num_vfs = num_vfs,
> + .tile = 0,
> + .stop_reason = NULL,
> + };
> + struct subcheck check = {
> + .data = &base,
> + .name = "reset-only",
> + .init = reset_only_subcheck_init,
> + .prepare_vf = reset_only_subcheck_prepare_vf,
> + .verify_vf = noop_subcheck_verify_vf,
> + .cleanup = noop_subcheck_cleanup,
> + };
> +
> + verify_flr(pf_fd, num_vfs, &check, 1, exec_strategy);
> +}
> +
> static void clear_tests(int pf_fd, int num_vfs, flr_exec_strategy exec_strategy)
> {
> const uint8_t num_tiles = xe_tiles_count(pf_fd);
> @@ -1141,6 +1201,11 @@ int igt_main_args("vw:", long_options, help_str, opt_handler, NULL)
> autoprobe = igt_sriov_is_driver_autoprobe_enabled(pf_fd);
> }
>
> + igt_describe("Initiate FLR without any additional state checks.");
> + igt_subtest("flr-basic") {
> + reset_only_test(pf_fd, 1, execute_sequential_flr);
> + }
> +
> igt_describe("Verify LMEM, GGTT, and SCRATCH_REGS are properly cleared after VF1 FLR");
> igt_subtest("flr-vf1-clear") {
> clear_tests(pf_fd, 1, execute_sequential_flr);
LGTM:
Reviewed-by: Piotr Piórkowski <piotr.piorkowski@intel.com>
> --
> 2.43.0
>
--
next prev parent reply other threads:[~2026-02-27 16:17 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-27 15:27 [PATCH v2 i-g-t 0/2] xe_sriov_flr: basic FLR smoke test Marcin Bernatowicz
2026-02-27 15:27 ` [PATCH v2 i-g-t 1/2] tests/intel/xe_sriov_flr: Add basic FLR subtest Marcin Bernatowicz
2026-02-27 16:17 ` Piotr Piórkowski [this message]
2026-02-27 15:27 ` [PATCH v2 i-g-t 2/2] tests/intel/xe_sriov_flr: Add --extended for flr-basic Marcin Bernatowicz
2026-02-27 16:17 ` Piotr Piórkowski
2026-02-27 21:22 ` ✓ Xe.CI.BAT: success for xe_sriov_flr: basic FLR smoke test Patchwork
2026-02-27 21:39 ` ✓ i915.CI.BAT: " Patchwork
2026-02-28 1:53 ` ✗ i915.CI.Full: failure " Patchwork
2026-02-28 11:00 ` ✗ Xe.CI.FULL: " Patchwork
2026-03-02 9:32 ` 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=20260227161722.vi3tlkeyk5k6eyll@intel.com \
--to=piotr.piorkowski@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=lukasz.laguna@intel.com \
--cc=marcin.bernatowicz@linux.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