aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2024-02-02 00:06:57 +0000
committerAndroid Build Coastguard Worker <android-build-coastguard-worker@google.com>2024-02-02 00:06:57 +0000
commit4de25c63ff93e60eb75544fd105a984abd76181a (patch)
treefc3494e715903121eaae8c77f6739f949e7780bf
parente8a0c8d60f0889a80d3a4d893279c2ea7ec41629 (diff)
parentcc9741b5fa1dcd6d469ffec471c7f51468e804c8 (diff)
downloadigt-gpu-tools-android14-qpr3-s2-release.tar.gz
Change-Id: Ie90dcd9bcdd4b0af46f216210816a41f77dbae21
-rw-r--r--benchmarks/kms_throughput.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/benchmarks/kms_throughput.c b/benchmarks/kms_throughput.c
index 692304518..7acb9245f 100644
--- a/benchmarks/kms_throughput.c
+++ b/benchmarks/kms_throughput.c
@@ -335,6 +335,15 @@ void get_tuning(struct tuning *tuning,
tuning->mode = get_peak_mode(output);
igt_require(tuning->mode);
+ if (igt_output_get_mode(output) != tuning->mode)
+ {
+ igt_output_override_mode(output, tuning->mode);
+ igt_display_commit2(p->display, COMMIT_ATOMIC);
+ }
+
+ igt_info("Chosen mode:\n");
+ kmstest_dump_mode(tuning->mode);
+
tuning->num_iterations = 1000;
tuning->num_fb_sets = 2;
@@ -412,18 +421,10 @@ igt_main
prepare(&display, p, output);
- struct tuning tuning;
- get_tuning(&tuning, &display, p, output);
-
drmModeModeInfoPtr orig_mode = igt_output_get_mode(output);
- if (orig_mode != tuning.mode)
- {
- igt_output_override_mode(output, tuning.mode);
- igt_display_commit2(&display, COMMIT_ATOMIC);
- }
- igt_info("Chosen mode:\n");
- kmstest_dump_mode(tuning.mode);
+ struct tuning tuning;
+ get_tuning(&tuning, &display, p, output);
{
struct igt_fb **fb_sets =