Skip to contentSkip to conversation

tests/i915/i915_pm_dc: Fix DC9 test

PATCH Superseded Jigar Bhatt 4 participants 5 messages Sep 8, 2021 – Sep 9, 2021

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tests/i915/i915_pm_dc: Fix DC9 test

Currently, check_dc9 is being called with reference (previous) counter being read after dpms_off call. At this time, already the counter is 0.
We need to read the counter before dpms_off is called so that it holds the previous value which had incremented while testing shallow states (DC5 or DC6).

---
 tests/i915/i915_pm_dc.c | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)
tests/i915/i915_pm_dc.c +6 -5
index 9d0a15d8..d1925e5a 100644
@@ -400,8 +400,8 @@ static bool check_dc9(uint32_t debugfs_fd, int prev_dc, bool dc6_supported, int
 	 * so we rely on dc5/dc6 counter reset to check if display engine was in DC9.
 	 */
 	return igt_wait(dc6_supported ? read_dc_counter(debugfs_fd, CHECK_DC6) <
-			prev_dc : read_dc_counter(debugfs_fd, CHECK_DC5) <
-			prev_dc, seconds, 100);
+			prev_dc : read_dc_counter(debugfs_fd, CHECK_DC5) < prev_dc
+			, seconds, 100);
 }
 
 static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported)
@@ -418,15 +418,16 @@ static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported)
 static void test_dc9_dpms(data_t *data)
 {
 	bool dc6_supported;
+	int prev_dc;
 
 	require_dc_counter(data->debugfs_fd, CHECK_DC5);
 	dc6_supported = support_dc6(data->debugfs_fd);
 	setup_dc9_dpms(data, dc6_supported ? read_dc_counter(data->debugfs_fd, CHECK_DC6) :
 			read_dc_counter(data->debugfs_fd, CHECK_DC5), dc6_supported);
+	prev_dc = dc6_supported ? read_dc_counter(data->debugfs_fd, CHECK_DC6) :
+		read_dc_counter(data->debugfs_fd, CHECK_DC5);
 	dpms_off(data);
-	igt_assert_f(check_dc9(data->debugfs_fd, dc6_supported ?
-				read_dc_counter(data->debugfs_fd, CHECK_DC6) :
-				read_dc_counter(data->debugfs_fd, CHECK_DC5),
+	igt_assert_f(check_dc9(data->debugfs_fd, prev_dc,
 				dc6_supported, 3000), "Not in DC9\n");
 	dpms_on(data);
 }
Signature · 1 line
2.25.1
#1 lore raw

[igt-dev] ✓ Fi.CI.BAT: success for tests/i915/i915_pm_dc: Fix DC9 test (rev4)

== Series Details ==

== Series Details ==

Series: tests/i915/i915_pm_dc: Fix DC9 test (rev4)
URL : https://patchwork.freedesktop.org/series/93180/
State : success

== Summary ==

CI Bug Log - changes from CI_DRM_10562 -> IGTPW_6210
====================================================

Summary
-------

**SUCCESS**

No regressions found.

External URL: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/index.html

Known issues
------------

Here are the changes found in IGTPW_6210 that come from known issues:

### IGT changes ###

#### Issues hit ####

* igt@amdgpu/amd_cs_nop@sync-fork-compute0:
- fi-snb-2600: NOTRUN -> [SKIP][1] ([fdo#109271]) +17 similar issues
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/fi-snb-2600/igt@amdgpu/[email protected]

* igt@runner@aborted:
- fi-bdw-5557u: NOTRUN -> [FAIL][2] ([i915#1602] / [i915#2029])
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/fi-bdw-5557u/igt@[email protected]

#### Possible fixes ####

* igt@i915_selftest@live@hangcheck:
- fi-snb-2600: [INCOMPLETE][3] ([i915#3921]) -> [PASS][4]
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/fi-snb-2600/igt@i915_selftest@[email protected]
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/fi-snb-2600/igt@i915_selftest@[email protected]

{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).

[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[i915#1602]: https://gitlab.freedesktop.org/drm/intel/issues/1602
[i915#2029]: https://gitlab.freedesktop.org/drm/intel/issues/2029
[i915#3303]: https://gitlab.freedesktop.org/drm/intel/issues/3303
[i915#3921]: https://gitlab.freedesktop.org/drm/intel/issues/3921

Participating hosts (47 -> 39)
------------------------------

Missing (8): fi-ilk-m540 bat-adls-5 bat-dg1-6 fi-bsw-cyan bat-adlp-4 fi-ctg-p8600 fi-bdw-samus bat-jsl-1

Build changes
-------------

* CI: CI-20190529 -> None
* IGT: IGT_6200 -> IGTPW_6210

CI-20190529: 20190529
CI_DRM_10562: d38c3e456e48f3cc74f454615dedc5a82e258402 @ git://anongit.freedesktop.org/gfx-ci/linux
IGTPW_6210: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/index.html
IGT_6200: 3a6585c472dff11ece952b745244f05e4c93ede5 @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/index.html

#2 lore raw

[igt-dev] ✗ Fi.CI.IGT: failure for tests/i915/i915_pm_dc: Fix DC9 test (rev4)

In reply to Jigar Bhatt
== Series Details ==

== Series Details ==

Series: tests/i915/i915_pm_dc: Fix DC9 test (rev4)
URL : https://patchwork.freedesktop.org/series/93180/
State : failure

== Summary ==

CI Bug Log - changes from CI_DRM_10562_full -> IGTPW_6210_full
====================================================

Summary
-------

**FAILURE**

Serious unknown changes coming with IGTPW_6210_full absolutely need to be verified manually.

If you think the reported changes have nothing to do with the changes introduced in IGTPW_6210_full, please notify your bug team to allow them to document this new failure mode, which will reduce false positives in CI.

External URL: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/index.html

Possible new issues
-------------------

Here are the unknown changes that may have been introduced in IGTPW_6210_full:

### IGT changes ###

#### Possible regressions ####

* igt@gem_ppgtt@blt-vs-render-ctxn:
- shard-snb: NOTRUN -> [DMESG-FAIL][1]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-snb7/igt@[email protected]

* igt@kms_flip_scaled_crc@flip-32bpp-ytile-to-32bpp-ytileccs:
- shard-iclb: [PASS][2] -> [SKIP][3]
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-iclb1/igt@[email protected]
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb2/igt@[email protected]

Known issues
------------

Here are the changes found in IGTPW_6210_full that come from known issues:

### IGT changes ###

#### Issues hit ####

* igt@gem_create@create-clear:
- shard-glk: [PASS][4] -> [FAIL][5] ([i915#1888] / [i915#3160])
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-glk2/igt@[email protected]
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk7/igt@[email protected]

* igt@gem_ctx_persistence@legacy-engines-mixed-process:
- shard-snb: NOTRUN -> [SKIP][6] ([fdo#109271] / [i915#1099]) +5 similar issues
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-snb5/igt@[email protected]

* igt@gem_ctx_sseu@engines:
- shard-tglb: NOTRUN -> [SKIP][7] ([i915#280])
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb6/igt@[email protected]

* igt@gem_exec_fair@basic-none-rrul@rcs0:
- shard-glk: NOTRUN -> [FAIL][8] ([i915#2842])
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk2/igt@gem_exec_fair@[email protected]

* igt@gem_exec_fair@basic-none-solo@rcs0:
- shard-tglb: NOTRUN -> [FAIL][9] ([i915#2842])
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb7/igt@gem_exec_fair@[email protected]

* igt@gem_exec_fair@basic-none@vcs1:
- shard-iclb: NOTRUN -> [FAIL][10] ([i915#2842])
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb4/igt@gem_exec_fair@[email protected]

* igt@gem_exec_fair@basic-none@vecs0:
- shard-apl: [PASS][11] -> [FAIL][12] ([i915#2842] / [i915#3468])
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-apl3/igt@gem_exec_fair@[email protected]
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl6/igt@gem_exec_fair@[email protected]

* igt@gem_exec_fair@basic-pace-share@rcs0:
- shard-glk: [PASS][13] -> [FAIL][14] ([i915#2842]) +1 similar issue
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-glk9/igt@gem_exec_fair@[email protected]
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk4/igt@gem_exec_fair@[email protected]

* igt@gem_exec_fair@basic-pace@bcs0:
- shard-tglb: [PASS][15] -> [FAIL][16] ([i915#2842])
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-tglb5/igt@gem_exec_fair@[email protected]
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb3/igt@gem_exec_fair@[email protected]

* igt@gem_exec_fair@basic-throttle@rcs0:
- shard-iclb: [PASS][17] -> [FAIL][18] ([i915#2849])
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-iclb4/igt@gem_exec_fair@[email protected]
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb1/igt@gem_exec_fair@[email protected]

* igt@gem_render_copy@yf-tiled-to-vebox-linear:
- shard-iclb: NOTRUN -> [SKIP][19] ([i915#768])
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb1/igt@[email protected]

* igt@gem_userptr_blits@coherency-sync:
- shard-tglb: NOTRUN -> [SKIP][20] ([fdo#110542])
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb5/igt@[email protected]

* igt@gem_userptr_blits@create-destroy-unsync:
- shard-tglb: NOTRUN -> [SKIP][21] ([i915#3297]) +1 similar issue
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb1/igt@[email protected]

* igt@gem_userptr_blits@dmabuf-sync:
- shard-kbl: NOTRUN -> [SKIP][22] ([fdo#109271] / [i915#3323])
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl6/igt@[email protected]
- shard-apl: NOTRUN -> [SKIP][23] ([fdo#109271] / [i915#3323])
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl1/igt@[email protected]

* igt@gem_userptr_blits@vma-merge:
- shard-kbl: NOTRUN -> [FAIL][24] ([i915#3318])
[24]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl7/igt@[email protected]

* igt@gen3_render_tiledy_blits:
- shard-tglb: NOTRUN -> [SKIP][25] ([fdo#109289]) +4 similar issues
[25]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb6/igt@gen3_render_tiledy_blits.html

* igt@gen9_exec_parse@bb-start-cmd:
- shard-tglb: NOTRUN -> [SKIP][26] ([i915#2856])
[26]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb3/igt@[email protected]

* igt@i915_pm_rpm@dpms-non-lpsp:
- shard-iclb: NOTRUN -> [SKIP][27] ([fdo#110892])
[27]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb1/igt@[email protected]

* igt@i915_pm_rpm@gem-execbuf-stress-pc8:
- shard-tglb: NOTRUN -> [SKIP][28] ([fdo#109506] / [i915#2411])
[28]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb5/igt@[email protected]

* igt@i915_query@query-topology-unsupported:
- shard-tglb: NOTRUN -> [SKIP][29] ([fdo#109302])
[29]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb3/igt@[email protected]

* igt@i915_selftest@live@hangcheck:
- shard-snb: NOTRUN -> [INCOMPLETE][30] ([i915#3921])
[30]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-snb6/igt@i915_selftest@[email protected]

* igt@i915_suspend@sysfs-reader:
- shard-apl: [PASS][31] -> [DMESG-WARN][32] ([i915#180]) +1 similar issue
[31]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-apl2/igt@[email protected]
[32]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl6/igt@[email protected]

* igt@kms_big_fb@linear-32bpp-rotate-0:
- shard-glk: [PASS][33] -> [DMESG-WARN][34] ([i915#118] / [i915#95]) +2 similar issues
[33]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-glk2/igt@[email protected]
[34]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk2/igt@[email protected]

* igt@kms_big_fb@x-tiled-8bpp-rotate-90:
- shard-tglb: NOTRUN -> [SKIP][35] ([fdo#111614]) +1 similar issue
[35]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb2/igt@[email protected]

* igt@kms_big_fb@x-tiled-max-hw-stride-64bpp-rotate-180-hflip:
- shard-kbl: NOTRUN -> [SKIP][36] ([fdo#109271] / [i915#3777]) +1 similar issue
[36]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl4/igt@[email protected]

* igt@kms_big_fb@yf-tiled-32bpp-rotate-270:
- shard-tglb: NOTRUN -> [SKIP][37] ([fdo#111615]) +7 similar issues
[37]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb7/igt@[email protected]

* igt@kms_ccs@pipe-a-bad-rotation-90-y_tiled_gen12_mc_ccs:
- shard-glk: NOTRUN -> [SKIP][38] ([fdo#109271] / [i915#3886]) +2 similar issues
[38]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk7/igt@kms_ccs@pipe-a-bad-rotation-90-y_tiled_gen12_mc_ccs.html
- shard-tglb: NOTRUN -> [SKIP][39] ([i915#3689] / [i915#3886]) +2 similar issues
[39]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb6/igt@kms_ccs@pipe-a-bad-rotation-90-y_tiled_gen12_mc_ccs.html

* igt@kms_ccs@pipe-a-crc-sprite-planes-basic-y_tiled_ccs:
- shard-tglb: NOTRUN -> [SKIP][40] ([i915#3689]) +14 similar issues
[40]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb2/igt@kms_ccs@pipe-a-crc-sprite-planes-basic-y_tiled_ccs.html

* igt@kms_ccs@pipe-c-ccs-on-another-bo-y_tiled_gen12_mc_ccs:
- shard-kbl: NOTRUN -> [SKIP][41] ([fdo#109271] / [i915#3886]) +8 similar issues
[41]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl2/igt@kms_ccs@pipe-c-ccs-on-another-bo-y_tiled_gen12_mc_ccs.html

* igt@kms_ccs@pipe-c-ccs-on-another-bo-y_tiled_gen12_rc_ccs_cc:
- shard-iclb: NOTRUN -> [SKIP][42] ([fdo#109278] / [i915#3886]) +2 similar issues
[42]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb3/igt@kms_ccs@pipe-c-ccs-on-another-bo-y_tiled_gen12_rc_ccs_cc.html
- shard-apl: NOTRUN -> [SKIP][43] ([fdo#109271] / [i915#3886]) +14 similar issues
[43]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl6/igt@kms_ccs@pipe-c-ccs-on-another-bo-y_tiled_gen12_rc_ccs_cc.html

* igt@kms_cdclk@mode-transition:
- shard-iclb: NOTRUN -> [SKIP][44] ([i915#3742])
[44]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb8/igt@[email protected]
- shard-tglb: NOTRUN -> [SKIP][45] ([i915#3742])
[45]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb6/igt@[email protected]

* igt@kms_chamelium@dp-hpd-storm-disable:
- shard-glk: NOTRUN -> [SKIP][46] ([fdo#109271] / [fdo#111827]) +8 similar issues
[46]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk2/igt@[email protected]

* igt@kms_chamelium@vga-hpd-for-each-pipe:
- shard-kbl: NOTRUN -> [SKIP][47] ([fdo#109271] / [fdo#111827]) +16 similar issues
[47]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl6/igt@[email protected]

* igt@kms_color_chamelium@pipe-a-ctm-limited-range:
- shard-apl: NOTRUN -> [SKIP][48] ([fdo#109271] / [fdo#111827]) +29 similar issues
[48]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl6/igt@[email protected]

* igt@kms_color_chamelium@pipe-a-degamma:
- shard-iclb: NOTRUN -> [SKIP][49] ([fdo#109284] / [fdo#111827]) +4 similar issues
[49]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb5/igt@[email protected]

* igt@kms_color_chamelium@pipe-c-ctm-0-25:
- shard-tglb: NOTRUN -> [SKIP][50] ([fdo#109284] / [fdo#111827]) +12 similar issues
[50]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb2/igt@[email protected]

* igt@kms_color_chamelium@pipe-invalid-ctm-matrix-sizes:
- shard-snb: NOTRUN -> [SKIP][51] ([fdo#109271] / [fdo#111827]) +23 similar issues
[51]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-snb2/igt@[email protected]

* igt@kms_content_protection@legacy:
- shard-iclb: NOTRUN -> [SKIP][52] ([fdo#109300] / [fdo#111066]) +1 similar issue
[52]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb5/igt@[email protected]
- shard-kbl: NOTRUN -> [TIMEOUT][53] ([i915#1319])
[53]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl7/igt@[email protected]
- shard-apl: NOTRUN -> [TIMEOUT][54] ([i915#1319])
[54]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl7/igt@[email protected]

* igt@kms_content_protection@uevent:
- shard-kbl: NOTRUN -> [FAIL][55] ([i915#2105])
[55]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl7/igt@[email protected]
- shard-tglb: NOTRUN -> [SKIP][56] ([fdo#111828]) +2 similar issues
[56]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb6/igt@[email protected]

* igt@kms_cursor_crc@pipe-a-cursor-suspend:
- shard-kbl: [PASS][57] -> [DMESG-WARN][58] ([i915#180])
[57]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-kbl6/igt@[email protected]
[58]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl7/igt@[email protected]

* igt@kms_cursor_crc@pipe-b-cursor-32x32-onscreen:
- shard-tglb: NOTRUN -> [SKIP][59] ([i915#3319]) +1 similar issue
[59]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb3/igt@[email protected]

* igt@kms_cursor_crc@pipe-b-cursor-512x170-random:
- shard-tglb: NOTRUN -> [SKIP][60] ([fdo#109279] / [i915#3359]) +4 similar issues
[60]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb5/igt@[email protected]
- shard-iclb: NOTRUN -> [SKIP][61] ([fdo#109278] / [fdo#109279])
[61]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb5/igt@[email protected]

* igt@kms_cursor_crc@pipe-b-cursor-size-change:
- shard-snb: [PASS][62] -> [FAIL][63] ([i915#4024])
[62]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-snb7/igt@[email protected]
[63]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-snb5/igt@[email protected]
- shard-kbl: [PASS][64] -> [FAIL][65] ([i915#3444])
[64]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-kbl4/igt@[email protected]
[65]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl3/igt@[email protected]
- shard-glk: [PASS][66] -> [FAIL][67] ([i915#3444])
[66]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-glk6/igt@[email protected]
[67]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk3/igt@[email protected]

* igt@kms_cursor_crc@pipe-c-cursor-max-size-offscreen:
- shard-tglb: NOTRUN -> [SKIP][68] ([i915#3359]) +5 similar issues
[68]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb7/igt@[email protected]

* igt@kms_cursor_crc@pipe-d-cursor-256x256-onscreen:
- shard-kbl: NOTRUN -> [SKIP][69] ([fdo#109271]) +187 similar issues
[69]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl3/igt@[email protected]

* igt@kms_cursor_edge_walk@pipe-d-128x128-right-edge:
- shard-snb: NOTRUN -> [SKIP][70] ([fdo#109271]) +375 similar issues
[70]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-snb5/igt@[email protected]

* igt@kms_cursor_legacy@cursorb-vs-flipb-legacy:
- shard-iclb: NOTRUN -> [SKIP][71] ([fdo#109274] / [fdo#109278])
[71]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb3/igt@[email protected]

* igt@kms_dither@fb-8bpc-vs-panel-8bpc@edp-1-pipe-a:
- shard-tglb: NOTRUN -> [SKIP][72] ([i915#3788])
[72]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb6/igt@kms_dither@[email protected]

* igt@kms_flip_scaled_crc@flip-32bpp-ytileccs-to-64bpp-ytile:
- shard-tglb: NOTRUN -> [SKIP][73] ([i915#2587])
[73]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb1/igt@[email protected]

* igt@kms_flip_scaled_crc@flip-64bpp-ytile-to-32bpp-ytilercccs:
- shard-apl: NOTRUN -> [SKIP][74] ([fdo#109271] / [i915#2672])
[74]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl2/igt@[email protected]

* igt@kms_frontbuffer_tracking@fbc-2p-primscrn-cur-indfb-draw-blt:
- shard-iclb: NOTRUN -> [SKIP][75] ([fdo#109280]) +13 similar issues
[75]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb1/igt@[email protected]

* igt@kms_frontbuffer_tracking@fbcpsr-2p-primscrn-cur-indfb-draw-mmap-gtt:
- shard-tglb: NOTRUN -> [SKIP][76] ([fdo#111825]) +41 similar issues
[76]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb1/igt@kms_frontbuffer_tracking@fbcpsr-2p-primscrn-cur-indfb-draw-mmap-gtt.html

* igt@kms_frontbuffer_tracking@psr-rgb565-draw-mmap-cpu:
- shard-glk: NOTRUN -> [SKIP][77] ([fdo#109271]) +64 similar issues
[77]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk6/igt@[email protected]

* igt@kms_pipe_b_c_ivb@pipe-b-double-modeset-then-modeset-pipe-c:
- shard-iclb: NOTRUN -> [SKIP][78] ([fdo#109289]) +1 similar issue
[78]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb2/igt@[email protected]

* igt@kms_pipe_crc_basic@compare-crc-sanitycheck-pipe-d:
- shard-apl: NOTRUN -> [SKIP][79] ([fdo#109271] / [i915#533]) +4 similar issues
[79]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl3/igt@[email protected]

* igt@kms_pipe_crc_basic@nonblocking-crc-pipe-d-frame-sequence:
- shard-kbl: NOTRUN -> [SKIP][80] ([fdo#109271] / [i915#533]) +1 similar issue
[80]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl3/igt@[email protected]

* igt@kms_pipe_crc_basic@suspend-read-crc-pipe-b:
- shard-tglb: [PASS][81] -> [INCOMPLETE][82] ([i915#456])
[81]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-tglb3/igt@[email protected]
[82]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb7/igt@[email protected]

* igt@kms_plane_alpha_blend@pipe-a-alpha-opaque-fb:
- shard-apl: NOTRUN -> [FAIL][83] ([fdo#108145] / [i915#265]) +2 similar issues
[83]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl3/igt@[email protected]

* igt@kms_plane_alpha_blend@pipe-b-alpha-basic:
- shard-kbl: NOTRUN -> [FAIL][84] ([fdo#108145] / [i915#265])
[84]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl6/igt@[email protected]

* igt@kms_plane_alpha_blend@pipe-b-alpha-transparent-fb:
- shard-apl: NOTRUN -> [FAIL][85] ([i915#265]) +1 similar issue
[85]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl6/igt@[email protected]

* igt@kms_plane_lowres@pipe-a-tiling-none:
- shard-tglb: NOTRUN -> [SKIP][86] ([i915#3536]) +2 similar issues
[86]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb5/igt@[email protected]

* igt@kms_plane_multiple@atomic-pipe-b-tiling-yf:
- shard-tglb: NOTRUN -> [SKIP][87] ([fdo#112054])
[87]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb6/igt@[email protected]

* igt@kms_plane_scaling@scaler-with-clipping-clamping@pipe-c-scaler-with-clipping-clamping:
- shard-apl: NOTRUN -> [SKIP][88] ([fdo#109271] / [i915#2733])
[88]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl8/igt@kms_plane_scaling@scaler-with-clipping-clamping@pipe-c-scaler-with-clipping-clamping.html

* igt@kms_psr2_sf@overlay-primary-update-sf-dmg-area-3:
- shard-glk: NOTRUN -> [SKIP][89] ([fdo#109271] / [i915#658]) +1 similar issue
[89]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk8/igt@[email protected]

* igt@kms_psr2_sf@overlay-primary-update-sf-dmg-area-4:
- shard-apl: NOTRUN -> [SKIP][90] ([fdo#109271] / [i915#658]) +8 similar issues
[90]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl2/igt@[email protected]

* igt@kms_psr2_sf@plane-move-sf-dmg-area-0:
- shard-tglb: NOTRUN -> [SKIP][91] ([i915#2920]) +2 similar issues
[91]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb3/igt@[email protected]
- shard-iclb: NOTRUN -> [SKIP][92] ([i915#658])
[92]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb4/igt@[email protected]

* igt@kms_psr2_sf@primary-plane-update-sf-dmg-area-2:
- shard-kbl: NOTRUN -> [SKIP][93] ([fdo#109271] / [i915#658]) +4 similar issues
[93]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl3/igt@[email protected]

* igt@kms_psr@psr2_cursor_plane_onoff:
- shard-tglb: NOTRUN -> [FAIL][94] ([i915#132] / [i915#3467]) +3 similar issues
[94]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb8/igt@kms_psr@psr2_cursor_plane_onoff.html

* igt@kms_psr@psr2_cursor_render:
- shard-iclb: [PASS][95] -> [SKIP][96] ([fdo#109441]) +1 similar issue
[95]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-iclb2/igt@kms_psr@psr2_cursor_render.html
[96]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb1/igt@kms_psr@psr2_cursor_render.html

* igt@kms_psr@psr2_sprite_render:
- shard-iclb: NOTRUN -> [SKIP][97] ([fdo#109441])
[97]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb6/igt@kms_psr@psr2_sprite_render.html

* igt@kms_vblank@pipe-a-ts-continuation-suspend:
- shard-apl: [PASS][98] -> [DMESG-WARN][99] ([i915#180] / [i915#295])
[98]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-apl2/igt@[email protected]
[99]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl8/igt@[email protected]

* igt@kms_vblank@pipe-d-ts-continuation-idle:
- shard-apl: NOTRUN -> [SKIP][100] ([fdo#109271]) +270 similar issues
[100]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl2/igt@[email protected]

* igt@kms_vblank@pipe-d-ts-continuation-idle-hang:
- shard-iclb: NOTRUN -> [SKIP][101] ([fdo#109278]) +14 similar issues
[101]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb4/igt@[email protected]

* igt@kms_writeback@writeback-check-output:
- shard-apl: NOTRUN -> [SKIP][102] ([fdo#109271] / [i915#2437]) +1 similar issue
[102]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl3/igt@[email protected]

* igt@nouveau_crc@pipe-b-ctx-flip-skip-current-frame:
- shard-tglb: NOTRUN -> [SKIP][103] ([i915#2530]) +5 similar issues
[103]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb6/igt@[email protected]
- shard-iclb: NOTRUN -> [SKIP][104] ([i915#2530])
[104]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb6/igt@[email protected]

* igt@nouveau_crc@pipe-d-source-outp-complete:
- shard-iclb: NOTRUN -> [SKIP][105] ([fdo#109278] / [i915#2530])
[105]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb5/igt@[email protected]

* igt@perf@polling-parameterized:
- shard-tglb: [PASS][106] -> [FAIL][107] ([i915#1542])
[106]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-tglb3/igt@[email protected]
[107]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb6/igt@[email protected]

* igt@prime_nv_api@i915_nv_reimport_twice_check_flink_name:
- shard-tglb: NOTRUN -> [SKIP][108] ([fdo#109291]) +4 similar issues
[108]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb2/igt@prime_nv_api@i915_nv_reimport_twice_check_flink_name.html

* igt@prime_vgem@coherency-gtt:
- shard-tglb: NOTRUN -> [SKIP][109] ([fdo#111656])
[109]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb2/igt@[email protected]

* igt@sysfs_clients@busy:
- shard-iclb: NOTRUN -> [SKIP][110] ([i915#2994])
[110]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb1/igt@[email protected]

* igt@sysfs_clients@create:
- shard-apl: NOTRUN -> [SKIP][111] ([fdo#109271] / [i915#2994]) +3 similar issues
[111]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl1/igt@[email protected]

* igt@sysfs_clients@sema-10:
- shard-glk: NOTRUN -> [SKIP][112] ([fdo#109271] / [i915#2994])
[112]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk4/igt@[email protected]

* igt@sysfs_clients@sema-25:
- shard-kbl: NOTRUN -> [SKIP][113] ([fdo#109271] / [i915#2994]) +2 similar issues
[113]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl6/igt@[email protected]

#### Possible fixes ####

* igt@fbdev@read:
- shard-kbl: [FAIL][114] -> [PASS][115]
[114]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-kbl7/igt@[email protected]
[115]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl4/igt@[email protected]
- shard-glk: [FAIL][116] -> [PASS][117]
[116]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-glk9/igt@[email protected]
[117]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk8/igt@[email protected]
- shard-apl: [FAIL][118] -> [PASS][119]
[118]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-apl7/igt@[email protected]
[119]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-apl3/igt@[email protected]
- shard-tglb: [FAIL][120] -> [PASS][121]
[120]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-tglb6/igt@[email protected]
[121]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb2/igt@[email protected]
- shard-snb: [FAIL][122] -> [PASS][123]
[122]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-snb2/igt@[email protected]
[123]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-snb5/igt@[email protected]
- shard-iclb: [FAIL][124] -> [PASS][125]
[124]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-iclb7/igt@[email protected]
[125]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb3/igt@[email protected]

* igt@gem_ctx_isolation@preservation-s3@rcs0:
- shard-tglb: [INCOMPLETE][126] ([i915#1373]) -> [PASS][127]
[126]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-tglb7/igt@gem_ctx_isolation@[email protected]
[127]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb8/igt@gem_ctx_isolation@[email protected]

* igt@gem_exec_fair@basic-none-rrul@rcs0:
- shard-kbl: [FAIL][128] ([i915#2842]) -> [PASS][129]
[128]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-kbl7/igt@gem_exec_fair@[email protected]
[129]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-kbl6/igt@gem_exec_fair@[email protected]

* igt@gem_exec_fair@basic-pace-solo@rcs0:
- shard-glk: [FAIL][130] ([i915#2842]) -> [PASS][131] +1 similar issue
[130]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-glk1/igt@gem_exec_fair@[email protected]
[131]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-glk3/igt@gem_exec_fair@[email protected]
- shard-tglb: [FAIL][132] ([i915#2842]) -> [PASS][133]
[132]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-tglb8/igt@gem_exec_fair@[email protected]
[133]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-tglb8/igt@gem_exec_fair@[email protected]

* igt@gem_exec_fair@basic-pace@vcs0:
- shard-iclb: [FAIL][134] ([i915#2842]) -> [PASS][135] +1 similar issue
[134]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-iclb4/igt@gem_exec_fair@[email protected]
[135]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb8/igt@gem_exec_fair@[email protected]

* igt@gem_mmap_gtt@cpuset-big-copy-odd:
- shard-iclb: [FAIL][136] ([i915#307]) -> [PASS][137]
[136]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10562/shard-iclb8/igt@[email protected]
[137]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/shard-iclb6/igt@[email protected]

* igt@i915_pm_backlight@fade_with_suspend:
- shard-tglb: [INCOMPLETE][138] ([i915#456]) -> [PASS][139]
[138]: https://int

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_6210/index.html

#3 lore raw
In reply to Jigar Bhatt
Quoted 28 lines · Jigar Bhatt

Currently, check_dc9 is being called with reference (previous) counter being read after dpms_off call. At this time, already the counter is 0.
We need to read the counter before dpms_off is called so that it holds the previous value which had incremented while testing shallow states (DC5 or DC6).

---
 tests/i915/i915_pm_dc.c | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)
tests/i915/i915_pm_dc.c +2 -2
index 9d0a15d8..d1925e5a 100644
@@ -400,8 +400,8 @@ static bool check_dc9(uint32_t debugfs_fd, int prev_dc, bool dc6_supported, int
 	 * so we rely on dc5/dc6 counter reset to check if display engine was in DC9.
 	 */
 	return igt_wait(dc6_supported ? read_dc_counter(debugfs_fd, CHECK_DC6) <
-			prev_dc : read_dc_counter(debugfs_fd, CHECK_DC5) <
-			prev_dc, seconds, 100);
+			prev_dc : read_dc_counter(debugfs_fd, CHECK_DC5) < prev_dc
+			, seconds, 100);
 }
 
 static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported)

tests/i915/i915_pm_dc.c static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported) · line 420

Quoted 3 lines
tests/i915/i915_pm_dc.c +0 -0
@@ -418,15 +418,16 @@ static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported)
 static void test_dc9_dpms(data_t *data)
 
 	bool dc6_supported;

The fix looks good, but while at it could you also make things a bit cleaner by

	int dc_target = support_dc6() ? CHECK_DC6 : CHECK_DC5;

tests/i915/i915_pm_dc.c static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported) · line 426

Quoted 6 lines
tests/i915/i915_pm_dc.c +1 -0
+	int prev_dc;
 
 	require_dc_counter(data->debugfs_fd, CHECK_DC5);
 	dc6_supported = support_dc6(data->debugfs_fd);
 	setup_dc9_dpms(data, dc6_supported ? read_dc_counter(data->debugfs_fd, CHECK_DC6) :
 			read_dc_counter(data->debugfs_fd, CHECK_DC5), dc6_supported);
	setup_dc9_dpms(data, dc_target);

and read out the counter within setup_dc9_dpms().

tests/i915/i915_pm_dc.c static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported) · line 428

Quoted 2 lines
tests/i915/i915_pm_dc.c +2 -0
+	prev_dc = dc6_supported ? read_dc_counter(data->debugfs_fd, CHECK_DC6) :
+		read_dc_counter(data->debugfs_fd, CHECK_DC5);
	prev_dc = read_dc_counter(dc_target);

tests/i915/i915_pm_dc.c static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported) · line 431

Quoted 6 lines
tests/i915/i915_pm_dc.c +1 -3
 	dpms_off(data);
-	igt_assert_f(check_dc9(data->debugfs_fd, dc6_supported ?
-				read_dc_counter(data->debugfs_fd, CHECK_DC6) :
-				read_dc_counter(data->debugfs_fd, CHECK_DC5),
+	igt_assert_f(check_dc9(data->debugfs_fd, prev_dc,
 				dc6_supported, 3000), "Not in DC9\n");
		     check_dc9(data->debugfs_fd, target_dc, 3000, ...

and simplify check_dc9() accordingly?

Quoted 5 lines
tests/i915/i915_pm_dc.c +0 -0
 	dpms_on(data);
 }
Signature · 1 line
2.25.1
#4 lore raw
Quoted 72 lines

-----Original Message-----
From: Deak, Imre <[email protected]>
Sent: Thursday, September 9, 2021 12:25 AM
To: Bhatt, Jigar <[email protected]>
Cc: [email protected]; Shankar, Uma <[email protected]>; Varide, Nischal <[email protected]>; Gupta, Anshuman <[email protected]>
Subject: Re: [ PATCH i-g-t v1 ] tests/i915/i915_pm_dc: Fix DC9 test

tests/i915/i915_pm_dc.c static bool check_dc9(uint32_t debugfs_fd, int

Quoted 17 lines · Jigar Bhatt

Currently, check_dc9 is being called with reference (previous) counter being read after dpms_off call.
At this time, already the counter is 0.
We need to read the counter before dpms_off is called so that it holds the previous value which had incremented while testing shallow states (DC5 or DC6).

---
 tests/i915/i915_pm_dc.c | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)
tests/i915/i915_pm_dc.c index renamed from tests/i915/i915_pm_dc.c +0 -0

9d0a15d8..d1925e5a 100644

tests/i915/i915_pm_dc.c +0 -0
@@ -400,8 +400,8 @@ static bool check_dc9(uint32_t debugfs_fd, int

prev_dc, bool dc6_supported, int

tests/i915/i915_pm_dc.c static bool check_dc9(uint32_t debugfs_fd, int · line 400

Quoted 1 line
tests/i915/i915_pm_dc.c +0 -0
 	 * so we rely on dc5/dc6 counter reset to check if display engine was in

DC9.

tests/i915/i915_pm_dc.c static bool check_dc9(uint32_t debugfs_fd, int · line 402

Quoted 2 lines
tests/i915/i915_pm_dc.c +0 -0
 	 */
 	return igt_wait(dc6_supported ? read_dc_counter(debugfs_fd,

CHECK_DC6) <

tests/i915/i915_pm_dc.c static bool check_dc9(uint32_t debugfs_fd, int prev_dc, bool dc6_supported, int

Quoted 3 lines
tests/i915/i915_pm_dc.c +1 -2
-			prev_dc : read_dc_counter(debugfs_fd, CHECK_DC5) <
-			prev_dc, seconds, 100);
+			prev_dc : read_dc_counter(debugfs_fd, CHECK_DC5) <

prev_dc

Quoted 9 lines
tests/i915/i915_pm_dc.c +1 -0
+			, seconds, 100);
 }
 
 static void setup_dc9_dpms(data_t *data, int prev_dc, bool

dc6_supported) @@ -418,15 +418,16 @@ static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported) static void test_dc9_dpms(data_t *data)

bool dc6_supported;

The fix looks good, but while at it could you also make things a bit cleaner by

	int dc_target = support_dc6() ? CHECK_DC6 : CHECK_DC5;
Quoted 7 lines
tests/i915/i915_pm_dc.c +1 -0
+	int prev_dc;
 
 	require_dc_counter(data->debugfs_fd, CHECK_DC5);
 	dc6_supported = support_dc6(data->debugfs_fd);
 	setup_dc9_dpms(data, dc6_supported ? read_dc_counter(data-

debugfs_fd, CHECK_DC6) :
read_dc_counter(data->debugfs_fd, CHECK_DC5),

dc6_supported);

	setup_dc9_dpms(data, dc_target);

and read out the counter within setup_dc9_dpms().

tests/i915/i915_pm_dc.c

Quoted 1 line
tests/i915/i915_pm_dc.c +1 -0
+	prev_dc = dc6_supported ? read_dc_counter(data->debugfs_fd,

CHECK_DC6) :

tests/i915/i915_pm_dc.c static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported) · line 428

Quoted 1 line
tests/i915/i915_pm_dc.c +1 -0
+		read_dc_counter(data->debugfs_fd, CHECK_DC5);
	prev_dc = read_dc_counter(dc_target);
Quoted 8 lines

tests/i915/i915_pm_dc.c static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported)

Quoted 3 lines
tests/i915/i915_pm_dc.c +0 -2
 	dpms_off(data);
-	igt_assert_f(check_dc9(data->debugfs_fd, dc6_supported ?
-				read_dc_counter(data->debugfs_fd,

CHECK_DC6) :

tests/i915/i915_pm_dc.c

Quoted 1 line
tests/i915/i915_pm_dc.c +0 -1
-				read_dc_counter(data->debugfs_fd,

CHECK_DC5),

tests/i915/i915_pm_dc.c static void setup_dc9_dpms(data_t *data, int prev_dc, bool dc6_supported) · line 431

Quoted 2 lines
tests/i915/i915_pm_dc.c +1 -0
+	igt_assert_f(check_dc9(data->debugfs_fd, prev_dc,
 				dc6_supported, 3000), "Not in DC9\n");

This test can also fail due to any wakeup which lead to runtime resume (kms connector polling is one of example), which will disable DC9 in DC_STATE_EN register. To debug such failure it would be better to dump the i915_pm_runtime_status debugfs file in case of test failure. Like below example:
igt_assert_f(dc_state_wait_entry(data->debugfs_fd, dc_flag, prev_dc_count),

                     "%s st\n%s:\n%s\n", tmp, PWR_DOMAIN_INFO,
                     data->pwr_dmn_info = igt_sysfs_get(data->debugfs_fd, PWR_DOMAIN_INFO));

Br,
Anshuman Gupta.

Quoted 10 lines
		     check_dc9(data->debugfs_fd, target_dc, 3000, ...

and simplify check_dc9() accordingly?

Quoted 5 lines

dpms_on(data);
}
--
2.25.1