[PATCH i-g-t 1/6] tests/intel/xe_sriov_scheduling: Disable VFs before resetting sched params
Marcin Bernatowicz <[email protected]>
| Newsgroups | org.freedesktop.lists.igt-dev |
|---|---|
| Message-ID | <ac3abf6574371b4418cf898f16bfe9443f48a653.1787056235.git.marcin.bernatowicz@linux.intel.com> |
Disable VFs before clearing scheduling parameters in fixtures and final cleanup. This avoids resetting scheduling while VFs are still active, which can leave cleanup incomplete and cause subsequent VF probing to fail. Signed-off-by: Marcin Bernatowicz <[email protected]> Cc: Adam Miszczak <[email protected]> Cc: Jakub Kolakowski <[email protected]> Cc: Lukasz Laguna <[email protected]> Cc: Michal Wajdeczko <[email protected]> --- tests/intel/xe_sriov_scheduling.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/intel/xe_sriov_scheduling.c b/tests/intel/xe_sriov_scheduling.c index 5d30b961d..a2240e473 100644 --- a/tests/intel/xe_sriov_scheduling.c +++ b/tests/intel/xe_sriov_scheduling.c @@ -1565,9 +1565,9 @@ int igt_main_args("", long_opts, help_str, subm_opts_handler, NULL) } igt_fixture() { + xe_sriov_disable_vfs_restore_auto_provisioning(pf_fd); __set_vfs_scheduling_params(pf_fd, igt_sriov_get_total_vfs(pf_fd), &(struct vf_sched_params){}); - xe_sriov_disable_vfs_restore_auto_provisioning(pf_fd); } } @@ -1617,18 +1617,18 @@ int igt_main_args("", long_opts, help_str, subm_opts_handler, NULL) } igt_fixture() { + xe_sriov_disable_vfs_restore_auto_provisioning(pf_fd); __set_vfs_scheduling_params(pf_fd, igt_sriov_get_total_vfs(pf_fd), &(struct vf_sched_params){}); - xe_sriov_disable_vfs_restore_auto_provisioning(pf_fd); } } igt_fixture() { int ret; + xe_sriov_disable_vfs_restore_auto_provisioning(pf_fd); ret = __set_vfs_scheduling_params(pf_fd, igt_sriov_get_total_vfs(pf_fd), &(struct vf_sched_params){}); - xe_sriov_disable_vfs_restore_auto_provisioning(pf_fd); /* abort to avoid execution of next tests with enabled VFs */ igt_abort_on_f(igt_sriov_get_enabled_vfs(pf_fd) > 0, "Failed to disable VF(s)"); -- 2.43.0