[PATCH i-g-t v3 5/7] tests/kms_psr2_sf: Use stored psr mode instead of PSR_MODE_2_SEL_FETCH
Jouni Högander
jouni.hogander at intel.com
Fri Jun 14 05:38:37 UTC 2024
We are already checking psr mode supported by system and storing it.
Use stored value instead of PSR_MODE_2_SEL_FETCH when enabling psr mode.
Signed-off-by: Jouni Högander <jouni.hogander at intel.com>
---
tests/intel/kms_psr2_sf.c | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/tests/intel/kms_psr2_sf.c b/tests/intel/kms_psr2_sf.c
index 4c3e34aa0..4fd9e0444 100644
--- a/tests/intel/kms_psr2_sf.c
+++ b/tests/intel/kms_psr2_sf.c
@@ -195,6 +195,10 @@ static bool set_sel_fetch_mode_for_output(data_t *data)
} else
igt_info("selective fetch not supported on output %s\n", data->output->name);
+ if (supported)
+ supported = psr_enable(data->drm_fd, data->debugfs_fd, data->psr_mode,
+ data->output);
+
return supported;
}
@@ -1053,11 +1057,6 @@ igt_main
data.fbc_flag = true;
}
- /* Test if PSR2 can be enabled */
- igt_require_f(psr_enable(data.drm_fd,
- data.debugfs_fd, PSR_MODE_2_SEL_FETCH, NULL),
- "Error enabling PSR2\n");
-
data.damage_area_count = MAX_DAMAGE_AREAS;
data.primary_format = DRM_FORMAT_XRGB8888;
--
2.34.1
More information about the igt-dev
mailing list