Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption
@ 2023-11-10  4:06 Vignesh Raman
  2023-11-10  4:50 ` [igt-dev] ✗ CI.xeBAT: failure for lib/igt_kms: Fix memory corruption (rev4) Patchwork
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Vignesh Raman @ 2023-11-10  4:06 UTC (permalink / raw)
  To: bhanuprakash.modem, daniels, igt-dev; +Cc: helen.koike

virtio-gpu kernel driver, which provides KMS, reports 16 for count_crtcs
which exceeds IGT_MAX_PIPES set to 8. The function igt_display_require
allocates memory for IGT_MAX_PIPES members of igt_pipe_t structures,
but then writes into it based on the count_crtcs reported by the kernel,
resulting in memory corruption.

 # malloc(): corrupted top size
 # Received signal SIGABRT.
 # Stack trace:
 #  #0 [fatal_sig_handler+0x17b]
 #  #1 [__sigaction+0x40]
 #  #2 [pthread_key_delete+0x14c]
 #  #3 [gsignal+0x12]
 #  #4 [abort+0xd3]
 #  #5 [__fsetlocking+0x290]
 #  #6 [timer_settime+0x37a]
 #  #7 [__default_morecore+0x1f1b]
 #  #8 [__libc_calloc+0x161]
 #  #9 [drmModeGetPlaneResources+0x44]
 #  #10 [igt_display_require+0x194]
 #  #11 [__igt_unique____real_main1356+0x93c]
 #  #12 [main+0x3f]
 #  #13 [__libc_init_first+0x8a]
 #  #14 [__libc_start_main+0x85]
 #  #15 [_start+0x21]

Increase IGT_MAX_PIPES to 16 to fix this memory corruption issue.
igt_display_require initializes display and allocate resources as
a prerequisite for the tests. Fail the test if count_crtcs exceeds
IGT_MAX_PIPES with debug information. Additionally, update the test
documentation to cover up to 16 pipes, and blacklist tests from
pipe-i to pipe-p on both the XE blocklist and the intel-ci blacklist.

This fix is required for drm-ci to run igt tests on virtio-gpu.

Reviewed-by: Daniel Stone <daniels@collabora.com>
Acked-by: Helen Koike <helen.koike@collabora.com>
Suggested-by: Daniel Stone <daniels@collabora.com>
Suggested-by: Bhanuprakash Modem <bhanuprakash.modem@intel.com>
Signed-off-by: Vignesh Raman <vignesh.raman@collabora.com>
---
 lib/igt_kms.c                   |  6 +++++-
 lib/igt_kms.h                   | 20 +++++++++++++++++++-
 tests/intel-ci/blacklist.txt    | 10 +++++++++-
 tests/intel-ci/xe.blocklist.txt |  6 +++---
 tests/intel/kms_ccs.c           | 24 ++++++++++++++++++++++++
 tests/kms_bw.c                  |  2 +-
 6 files changed, 61 insertions(+), 7 deletions(-)

diff --git a/lib/igt_kms.c b/lib/igt_kms.c
index 453103f90..6ad7cc127 100644
--- a/lib/igt_kms.c
+++ b/lib/igt_kms.c
@@ -906,7 +906,7 @@ static igt_plane_t *igt_get_assigned_primary(igt_output_t *output, igt_pipe_t *p
  */
 const char *kmstest_pipe_name(enum pipe pipe)
 {
-	static const char str[] = "A\0B\0C\0D\0E\0F\0G\0H";
+	static const char str[] = "A\0B\0C\0D\0E\0F\0G\0H\0I\0J\0K\0L\0M\0N\0O\0P";
 
 	_Static_assert(sizeof(str) == IGT_MAX_PIPES * 2,
 		       "Missing pipe name");
@@ -2770,6 +2770,10 @@ void igt_display_require(igt_display_t *display, int drm_fd)
 	}
 #endif
 
+	igt_assert_f(resources->count_crtcs <= IGT_MAX_PIPES,
+		     "count_crtcs exceeds IGT_MAX_PIPES, resources->count_crtcs=%d, IGT_MAX_PIPES=%d\n",
+		     resources->count_crtcs, IGT_MAX_PIPES);
+
 	display->n_pipes = IGT_MAX_PIPES;
 	display->pipes = calloc(sizeof(igt_pipe_t), display->n_pipes);
 	igt_assert_f(display->pipes, "Failed to allocate memory for %d pipes\n", display->n_pipes);
diff --git a/lib/igt_kms.h b/lib/igt_kms.h
index 9028ab9be..5c705b585 100644
--- a/lib/igt_kms.h
+++ b/lib/igt_kms.h
@@ -57,6 +57,16 @@
  * @PIPE_D: Fourth crtc.
  * @PIPE_E: Fifth crtc.
  * @PIPE_F: Sixth crtc.
+ * @PIPE_G: Seventh crtc.
+ * @PIPE_H: Eighth crtc.
+ * @PIPE_I: Ninth crtc.
+ * @PIPE_J: Tenth crtc.
+ * @PIPE_K: Eleventh crtc.
+ * @PIPE_L: Twelfth crtc.
+ * @PIPE_M: Thirteenth crtc.
+ * @PIPE_N: Fourteenth crtc.
+ * @PIPE_O: Fifteenth crtc.
+ * @PIPE_P: Sixteenth crtc.
  * @IGT_MAX_PIPES: Max number of pipes allowed.
  */
 enum pipe {
@@ -70,7 +80,15 @@ enum pipe {
         PIPE_F,
 	PIPE_G,
 	PIPE_H,
-        IGT_MAX_PIPES
+	PIPE_I,
+	PIPE_J,
+	PIPE_K,
+	PIPE_L,
+	PIPE_M,
+	PIPE_N,
+	PIPE_O,
+	PIPE_P,
+	IGT_MAX_PIPES
 };
 const char *kmstest_pipe_name(enum pipe pipe);
 int kmstest_pipe_to_index(char pipe);
diff --git a/tests/intel-ci/blacklist.txt b/tests/intel-ci/blacklist.txt
index e13759d3e..e439e2af4 100644
--- a/tests/intel-ci/blacklist.txt
+++ b/tests/intel-ci/blacklist.txt
@@ -117,12 +117,20 @@ igt@gem_ctx_isolation@.*-s4
 ###############################################
 igt@i915_suspend@shrink
 ###############################################
-# pipe-e, pipe-f, pipe-g, pipe-h no current HW support
+# pipe-e, pipe-f, pipe-g, pipe-h, pipe-i, pipe-j, pipe-k, pipe-l, pipe-m, pipe-n, pipe-o, pipe-p no current HW support
 ###############################################
 igt@.*@.*pipe-e($|-.*)
 igt@.*@.*pipe-f($|-.*)
 igt@.*@.*pipe-g($|-.*)
 igt@.*@.*pipe-h($|-.*)
+igt@.*@.*pipe-i($|-.*)
+igt@.*@.*pipe-j($|-.*)
+igt@.*@.*pipe-k($|-.*)
+igt@.*@.*pipe-l($|-.*)
+igt@.*@.*pipe-m($|-.*)
+igt@.*@.*pipe-n($|-.*)
+igt@.*@.*pipe-o($|-.*)
+igt@.*@.*pipe-p($|-.*)
 
 ###############################################
 # Temporary workarounds for CI-impacting bugs
diff --git a/tests/intel-ci/xe.blocklist.txt b/tests/intel-ci/xe.blocklist.txt
index 135ab18a3..bec6ee23b 100644
--- a/tests/intel-ci/xe.blocklist.txt
+++ b/tests/intel-ci/xe.blocklist.txt
@@ -44,11 +44,11 @@ igt@syncobj_.*
 igt@template
 igt@tools_test
 ##################################################################
-# KMS: Pipe E, F, G and H are not available on Intel hardware,
+# KMS: Pipe E, F, G, H, I, J, K, L, M, N, O and P are not available on Intel hardware,
 # hence can't use more than 4 displays.
 ##################################################################
-igt@.*@.*pipe-(e|f|g|h).*
-igt@kms_bw@.*-(5|6|7|8)-displays-.*
+igt@.*@.*pipe-(e|f|g|h|i|j|k|l|m|n|o|p).*
+igt@kms_bw@.*-(5|6|7|8|9|10|11|12|13|14|15|16)-displays-.*
 ##################################################################
 # KMS: Tests specific to i915 driver
 ##################################################################
diff --git a/tests/intel/kms_ccs.c b/tests/intel/kms_ccs.c
index 93e837b84..6dc30ac24 100644
--- a/tests/intel/kms_ccs.c
+++ b/tests/intel/kms_ccs.c
@@ -53,6 +53,14 @@
  * @pipe-F:                    Pipe F
  * @pipe-G:                    Pipe G
  * @pipe-H:                    Pipe H
+ * @pipe-I:                    Pipe I
+ * @pipe-J:                    Pipe J
+ * @pipe-K:                    Pipe K
+ * @pipe-L:                    Pipe L
+ * @pipe-M:                    Pipe M
+ * @pipe-N:                    Pipe N
+ * @pipe-O:                    Pipe O
+ * @pipe-P:                    Pipe P
  *
  * arg[2]:
  *
@@ -90,6 +98,14 @@
  * @pipe-F:                      Pipe F
  * @pipe-G:                      Pipe G
  * @pipe-H:                      Pipe H
+ * @pipe-I:                      Pipe I
+ * @pipe-J:                      Pipe J
+ * @pipe-K:                      Pipe K
+ * @pipe-L:                      Pipe L
+ * @pipe-M:                      Pipe M
+ * @pipe-N:                      Pipe N
+ * @pipe-O:                      Pipe O
+ * @pipe-P:                      Pipe P
  *
  * arg[2]:
  *
@@ -131,6 +147,14 @@
  * @pipe-F:                      Pipe F
  * @pipe-G:                      Pipe G
  * @pipe-H:                      Pipe H
+ * @pipe-I:                      Pipe I
+ * @pipe-J:                      Pipe J
+ * @pipe-K:                      Pipe K
+ * @pipe-L:                      Pipe L
+ * @pipe-M:                      Pipe M
+ * @pipe-N:                      Pipe N
+ * @pipe-O:                      Pipe O
+ * @pipe-P:                      Pipe P
  *
  * arg[2]:
  *
diff --git a/tests/kms_bw.c b/tests/kms_bw.c
index 5f9a020da..896114a3a 100644
--- a/tests/kms_bw.c
+++ b/tests/kms_bw.c
@@ -37,7 +37,7 @@
  * Mega feature: General Display Features
  * Test category: functionality test
  *
- * arg[1].values: 1, 2, 3, 4, 5, 6, 7, 8
+ * arg[1].values: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16
  *
  * arg[2]:
  *
-- 
2.40.1

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [igt-dev] ✗ CI.xeBAT: failure for lib/igt_kms: Fix memory corruption (rev4)
  2023-11-10  4:06 [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption Vignesh Raman
@ 2023-11-10  4:50 ` Patchwork
  2023-11-10  5:04 ` [igt-dev] ✗ Fi.CI.BAT: " Patchwork
  2023-11-10  6:06 ` [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption Modem, Bhanuprakash
  2 siblings, 0 replies; 5+ messages in thread
From: Patchwork @ 2023-11-10  4:50 UTC (permalink / raw)
  To: Vignesh Raman; +Cc: igt-dev

[-- Attachment #1: Type: text/plain, Size: 11439 bytes --]

== Series Details ==

Series: lib/igt_kms: Fix memory corruption (rev4)
URL   : https://patchwork.freedesktop.org/series/125599/
State : failure

== Summary ==

CI Bug Log - changes from XEIGT_7581_BAT -> XEIGTPW_10156_BAT
====================================================

Summary
-------

  **FAILURE**

  Serious unknown changes coming with XEIGTPW_10156_BAT absolutely need to be
  verified manually.
  
  If you think the reported changes have nothing to do with the changes
  introduced in XEIGTPW_10156_BAT, please notify your bug team (lgci.bug.filing@intel.com) to allow them
  to document this new failure mode, which will reduce false positives in CI.

  

Participating hosts (0 -> 3)
------------------------------

  Additional (3): bat-dg2-oem2 bat-adlp-7 bat-atsm-2 

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

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

### IGT changes ###

#### Possible regressions ####

  * igt@kms_cursor_legacy@basic-flip-after-cursor-legacy:
    - bat-adlp-7:         NOTRUN -> [FAIL][1]
   [1]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-adlp-7/igt@kms_cursor_legacy@basic-flip-after-cursor-legacy.html

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

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

### IGT changes ###

#### Issues hit ####

  * igt@kms_addfb_basic@addfb25-y-tiled-small-legacy:
    - bat-dg2-oem2:       NOTRUN -> [SKIP][2] ([Intel XE#623])
   [2]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@kms_addfb_basic@addfb25-y-tiled-small-legacy.html

  * igt@kms_addfb_basic@basic-y-tiled-legacy:
    - bat-dg2-oem2:       NOTRUN -> [SKIP][3] ([Intel XE#624])
   [3]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@kms_addfb_basic@basic-y-tiled-legacy.html

  * igt@kms_addfb_basic@invalid-set-prop-any:
    - bat-atsm-2:         NOTRUN -> [SKIP][4] ([i915#6077]) +33 other tests skip
   [4]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@kms_addfb_basic@invalid-set-prop-any.html

  * igt@kms_addfb_basic@tile-pitch-mismatch:
    - bat-dg2-oem2:       NOTRUN -> [FAIL][5] ([Intel XE#609]) +1 other test fail
   [5]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@kms_addfb_basic@tile-pitch-mismatch.html
    - bat-adlp-7:         NOTRUN -> [FAIL][6] ([Intel XE#609]) +2 other tests fail
   [6]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-adlp-7/igt@kms_addfb_basic@tile-pitch-mismatch.html

  * igt@kms_cursor_legacy@basic-flip-after-cursor-legacy:
    - bat-atsm-2:         NOTRUN -> [SKIP][7] ([Intel XE#782]) +5 other tests skip
   [7]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@kms_cursor_legacy@basic-flip-after-cursor-legacy.html

  * igt@kms_cursor_legacy@basic-flip-before-cursor-varying-size:
    - bat-dg2-oem2:       NOTRUN -> [FAIL][8] ([Intel XE#692] / [Intel XE#773])
   [8]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@kms_cursor_legacy@basic-flip-before-cursor-varying-size.html

  * igt@kms_dsc@dsc-basic:
    - bat-atsm-2:         NOTRUN -> [SKIP][9] ([Intel XE#784])
   [9]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@kms_dsc@dsc-basic.html
    - bat-dg2-oem2:       NOTRUN -> [SKIP][10] ([Intel XE#423])
   [10]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@kms_dsc@dsc-basic.html
    - bat-adlp-7:         NOTRUN -> [SKIP][11] ([Intel XE#423])
   [11]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-adlp-7/igt@kms_dsc@dsc-basic.html

  * igt@kms_flip@basic-flip-vs-wf_vblank:
    - bat-atsm-2:         NOTRUN -> [SKIP][12] ([Intel XE#541]) +3 other tests skip
   [12]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@kms_flip@basic-flip-vs-wf_vblank.html

  * igt@kms_flip@basic-flip-vs-wf_vblank@a-dp3:
    - bat-dg2-oem2:       NOTRUN -> [FAIL][13] ([Intel XE#480]) +1 other test fail
   [13]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@kms_flip@basic-flip-vs-wf_vblank@a-dp3.html

  * igt@kms_flip@basic-flip-vs-wf_vblank@a-edp1:
    - bat-adlp-7:         NOTRUN -> [FAIL][14] ([Intel XE#480]) +1 other test fail
   [14]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-adlp-7/igt@kms_flip@basic-flip-vs-wf_vblank@a-edp1.html

  * igt@kms_force_connector_basic@prune-stale-modes:
    - bat-dg2-oem2:       NOTRUN -> [SKIP][15] ([i915#5274])
   [15]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@kms_force_connector_basic@prune-stale-modes.html

  * igt@kms_frontbuffer_tracking@basic:
    - bat-dg2-oem2:       NOTRUN -> [FAIL][16] ([Intel XE#608])
   [16]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@kms_frontbuffer_tracking@basic.html
    - bat-adlp-7:         NOTRUN -> [DMESG-FAIL][17] ([Intel XE#282] / [i915#2017])
   [17]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-adlp-7/igt@kms_frontbuffer_tracking@basic.html
    - bat-atsm-2:         NOTRUN -> [SKIP][18] ([Intel XE#783])
   [18]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@kms_frontbuffer_tracking@basic.html

  * igt@kms_hdmi_inject@inject-audio:
    - bat-atsm-2:         NOTRUN -> [SKIP][19] ([Intel XE#540]) +3 other tests skip
   [19]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@kms_hdmi_inject@inject-audio.html

  * igt@kms_pipe_crc_basic@compare-crc-sanitycheck-nv12@pipe-b-dp-3:
    - bat-dg2-oem2:       NOTRUN -> [FAIL][20] ([Intel XE#400] / [Intel XE#616]) +2 other tests fail
   [20]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@kms_pipe_crc_basic@compare-crc-sanitycheck-nv12@pipe-b-dp-3.html

  * igt@kms_pipe_crc_basic@compare-crc-sanitycheck-xr24:
    - bat-atsm-2:         NOTRUN -> [SKIP][21] ([i915#1836]) +6 other tests skip
   [21]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@kms_pipe_crc_basic@compare-crc-sanitycheck-xr24.html

  * igt@kms_prop_blob@basic:
    - bat-atsm-2:         NOTRUN -> [SKIP][22] ([Intel XE#780])
   [22]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@kms_prop_blob@basic.html

  * igt@kms_psr@primary_page_flip:
    - bat-dg2-oem2:       NOTRUN -> [SKIP][23] ([Intel XE#535]) +2 other tests skip
   [23]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@kms_psr@primary_page_flip.html

  * igt@kms_psr@sprite_plane_onoff:
    - bat-atsm-2:         NOTRUN -> [SKIP][24] ([Intel XE#535]) +2 other tests skip
   [24]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@kms_psr@sprite_plane_onoff.html

  * igt@xe_compute@compute-square:
    - bat-atsm-2:         NOTRUN -> [SKIP][25] ([Intel XE#672])
   [25]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@xe_compute@compute-square.html
    - bat-dg2-oem2:       NOTRUN -> [SKIP][26] ([Intel XE#672])
   [26]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@xe_compute@compute-square.html

  * igt@xe_evict@evict-beng-small-external:
    - bat-adlp-7:         NOTRUN -> [SKIP][27] ([Intel XE#261] / [Intel XE#688]) +15 other tests skip
   [27]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-adlp-7/igt@xe_evict@evict-beng-small-external.html

  * igt@xe_exec_fault_mode@many-basic:
    - bat-dg2-oem2:       NOTRUN -> [SKIP][28] ([Intel XE#288]) +17 other tests skip
   [28]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@xe_exec_fault_mode@many-basic.html

  * igt@xe_exec_fault_mode@twice-userptr-invalidate:
    - bat-adlp-7:         NOTRUN -> [SKIP][29] ([Intel XE#288]) +17 other tests skip
   [29]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-adlp-7/igt@xe_exec_fault_mode@twice-userptr-invalidate.html

  * igt@xe_exec_fault_mode@twice-userptr-invalidate-imm:
    - bat-atsm-2:         NOTRUN -> [SKIP][30] ([Intel XE#288]) +17 other tests skip
   [30]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@xe_exec_fault_mode@twice-userptr-invalidate-imm.html

  * igt@xe_huc_copy@huc_copy:
    - bat-atsm-2:         NOTRUN -> [SKIP][31] ([Intel XE#255])
   [31]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-atsm-2/igt@xe_huc_copy@huc_copy.html
    - bat-dg2-oem2:       NOTRUN -> [SKIP][32] ([Intel XE#255])
   [32]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-dg2-oem2/igt@xe_huc_copy@huc_copy.html

  * igt@xe_mmap@vram:
    - bat-adlp-7:         NOTRUN -> [SKIP][33] ([Intel XE#263])
   [33]: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/bat-adlp-7/igt@xe_mmap@vram.html

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

  [Intel XE#255]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/255
  [Intel XE#261]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/261
  [Intel XE#263]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/263
  [Intel XE#282]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/282
  [Intel XE#288]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/288
  [Intel XE#400]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/400
  [Intel XE#423]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/423
  [Intel XE#480]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/480
  [Intel XE#524]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/524
  [Intel XE#535]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/535
  [Intel XE#540]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/540
  [Intel XE#541]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/541
  [Intel XE#608]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/608
  [Intel XE#609]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/609
  [Intel XE#616]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/616
  [Intel XE#623]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/623
  [Intel XE#624]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/624
  [Intel XE#672]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/672
  [Intel XE#688]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/688
  [Intel XE#692]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/692
  [Intel XE#773]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/773
  [Intel XE#780]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/780
  [Intel XE#782]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/782
  [Intel XE#783]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/783
  [Intel XE#784]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/784
  [i915#1836]: https://gitlab.freedesktop.org/drm/intel/issues/1836
  [i915#2017]: https://gitlab.freedesktop.org/drm/intel/issues/2017
  [i915#5274]: https://gitlab.freedesktop.org/drm/intel/issues/5274
  [i915#6077]: https://gitlab.freedesktop.org/drm/intel/issues/6077


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

  * IGT: IGT_7581 -> IGTPW_10156
  * Linux: xe-484-b11007e91f8785a96903d9d3c3d1efbe7e969eaf -> xe-485-b3890fb4386dcef68a96888141c4cc773f6241ce

  IGTPW_10156: 10156
  IGT_7581: 7581
  xe-484-b11007e91f8785a96903d9d3c3d1efbe7e969eaf: b11007e91f8785a96903d9d3c3d1efbe7e969eaf
  xe-485-b3890fb4386dcef68a96888141c4cc773f6241ce: b3890fb4386dcef68a96888141c4cc773f6241ce

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/intel-xe/IGTPW_10156/index.html

[-- Attachment #2: Type: text/html, Size: 13247 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [igt-dev] ✗ Fi.CI.BAT: failure for lib/igt_kms: Fix memory corruption (rev4)
  2023-11-10  4:06 [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption Vignesh Raman
  2023-11-10  4:50 ` [igt-dev] ✗ CI.xeBAT: failure for lib/igt_kms: Fix memory corruption (rev4) Patchwork
@ 2023-11-10  5:04 ` Patchwork
  2023-11-10  6:06 ` [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption Modem, Bhanuprakash
  2 siblings, 0 replies; 5+ messages in thread
From: Patchwork @ 2023-11-10  5:04 UTC (permalink / raw)
  To: Vignesh Raman; +Cc: igt-dev

[-- Attachment #1: Type: text/plain, Size: 10361 bytes --]

== Series Details ==

Series: lib/igt_kms: Fix memory corruption (rev4)
URL   : https://patchwork.freedesktop.org/series/125599/
State : failure

== Summary ==

CI Bug Log - changes from CI_DRM_13859 -> IGTPW_10156
====================================================

Summary
-------

  **FAILURE**

  Serious unknown changes coming with IGTPW_10156 absolutely need to be
  verified manually.
  
  If you think the reported changes have nothing to do with the changes
  introduced in IGTPW_10156, please notify your bug team (lgci.bug.filing@intel.com) 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_10156/index.html

Participating hosts (33 -> 32)
------------------------------

  Additional (1): bat-dg2-9 
  Missing    (2): fi-kbl-soraka bat-adlp-11 

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

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

### IGT changes ###

#### Possible regressions ####

  * igt@i915_selftest@live@hangcheck:
    - bat-mtlp-6:         [PASS][1] -> [DMESG-WARN][2]
   [1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_13859/bat-mtlp-6/igt@i915_selftest@live@hangcheck.html
   [2]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-mtlp-6/igt@i915_selftest@live@hangcheck.html

  * igt@i915_selftest@live@reset:
    - fi-apl-guc:         [PASS][3] -> [DMESG-WARN][4] +36 other tests dmesg-warn
   [3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_13859/fi-apl-guc/igt@i915_selftest@live@reset.html
   [4]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/fi-apl-guc/igt@i915_selftest@live@reset.html

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

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

### IGT changes ###

#### Issues hit ####

  * igt@gem_mmap@basic:
    - bat-dg2-9:          NOTRUN -> [SKIP][5] ([i915#4083])
   [5]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@gem_mmap@basic.html

  * igt@gem_mmap_gtt@basic:
    - bat-dg2-9:          NOTRUN -> [SKIP][6] ([i915#4077]) +2 other tests skip
   [6]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@gem_mmap_gtt@basic.html

  * igt@gem_render_tiled_blits@basic:
    - bat-dg2-9:          NOTRUN -> [SKIP][7] ([i915#4079]) +1 other test skip
   [7]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@gem_render_tiled_blits@basic.html

  * igt@i915_module_load@reload:
    - fi-apl-guc:         [PASS][8] -> [DMESG-WARN][9] ([i915#180] / [i915#1982] / [i915#8585])
   [8]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_13859/fi-apl-guc/igt@i915_module_load@reload.html
   [9]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/fi-apl-guc/igt@i915_module_load@reload.html

  * igt@i915_pm_rpm@module-reload:
    - fi-apl-guc:         [PASS][10] -> [DMESG-WARN][11] ([i915#180] / [i915#8585]) +2 other tests dmesg-warn
   [10]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_13859/fi-apl-guc/igt@i915_pm_rpm@module-reload.html
   [11]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/fi-apl-guc/igt@i915_pm_rpm@module-reload.html

  * igt@i915_pm_rps@basic-api:
    - bat-dg2-9:          NOTRUN -> [SKIP][12] ([i915#6621])
   [12]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@i915_pm_rps@basic-api.html

  * igt@kms_addfb_basic@addfb25-4-tiled:
    - fi-apl-guc:         [PASS][13] -> [DMESG-WARN][14] ([i915#8585] / [i915#8703]) +40 other tests dmesg-warn
   [13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_13859/fi-apl-guc/igt@kms_addfb_basic@addfb25-4-tiled.html
   [14]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/fi-apl-guc/igt@kms_addfb_basic@addfb25-4-tiled.html

  * igt@kms_addfb_basic@addfb25-y-tiled-small-legacy:
    - bat-dg2-9:          NOTRUN -> [SKIP][15] ([i915#5190])
   [15]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@kms_addfb_basic@addfb25-y-tiled-small-legacy.html

  * igt@kms_addfb_basic@basic-y-tiled-legacy:
    - bat-dg2-9:          NOTRUN -> [SKIP][16] ([i915#4215] / [i915#5190])
   [16]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@kms_addfb_basic@basic-y-tiled-legacy.html

  * igt@kms_addfb_basic@framebuffer-vs-set-tiling:
    - bat-dg2-9:          NOTRUN -> [SKIP][17] ([i915#4212]) +6 other tests skip
   [17]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@kms_addfb_basic@framebuffer-vs-set-tiling.html

  * igt@kms_addfb_basic@tile-pitch-mismatch:
    - bat-dg2-9:          NOTRUN -> [SKIP][18] ([i915#4212] / [i915#5608])
   [18]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@kms_addfb_basic@tile-pitch-mismatch.html

  * igt@kms_cursor_legacy@basic-busy-flip-before-cursor-legacy:
    - bat-dg2-9:          NOTRUN -> [SKIP][19] ([i915#4103] / [i915#4213] / [i915#5608]) +1 other test skip
   [19]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@kms_cursor_legacy@basic-busy-flip-before-cursor-legacy.html

  * igt@kms_flip@basic-flip-vs-dpms@c-dp1:
    - fi-apl-guc:         [PASS][20] -> [DMESG-WARN][21] ([i915#180] / [i915#8585] / [i915#8703]) +31 other tests dmesg-warn
   [20]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_13859/fi-apl-guc/igt@kms_flip@basic-flip-vs-dpms@c-dp1.html
   [21]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/fi-apl-guc/igt@kms_flip@basic-flip-vs-dpms@c-dp1.html

  * igt@kms_flip@basic-flip-vs-wf_vblank@a-dp1:
    - fi-apl-guc:         [PASS][22] -> [DMESG-WARN][23] ([i915#180] / [i915#1982] / [i915#8585] / [i915#8703]) +1 other test dmesg-warn
   [22]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_13859/fi-apl-guc/igt@kms_flip@basic-flip-vs-wf_vblank@a-dp1.html
   [23]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/fi-apl-guc/igt@kms_flip@basic-flip-vs-wf_vblank@a-dp1.html

  * igt@kms_force_connector_basic@force-load-detect:
    - bat-dg2-9:          NOTRUN -> [SKIP][24] ([fdo#109285])
   [24]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@kms_force_connector_basic@force-load-detect.html

  * igt@kms_force_connector_basic@prune-stale-modes:
    - bat-dg2-9:          NOTRUN -> [SKIP][25] ([i915#5274])
   [25]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@kms_force_connector_basic@prune-stale-modes.html

  * igt@kms_psr@sprite_plane_onoff:
    - bat-dg2-9:          NOTRUN -> [SKIP][26] ([i915#1072]) +3 other tests skip
   [26]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@kms_psr@sprite_plane_onoff.html

  * igt@kms_setmode@basic-clone-single-crtc:
    - bat-dg2-9:          NOTRUN -> [SKIP][27] ([i915#3555] / [i915#4098])
   [27]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@kms_setmode@basic-clone-single-crtc.html

  * igt@prime_vgem@basic-fence-flip:
    - bat-dg2-9:          NOTRUN -> [SKIP][28] ([i915#3708])
   [28]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@prime_vgem@basic-fence-flip.html

  * igt@prime_vgem@basic-fence-mmap:
    - bat-dg2-9:          NOTRUN -> [SKIP][29] ([i915#3708] / [i915#4077]) +1 other test skip
   [29]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@prime_vgem@basic-fence-mmap.html

  * igt@prime_vgem@basic-write:
    - bat-dg2-9:          NOTRUN -> [SKIP][30] ([i915#3291] / [i915#3708]) +2 other tests skip
   [30]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-9/igt@prime_vgem@basic-write.html

  
#### Possible fixes ####

  * igt@i915_selftest@live@hangcheck:
    - bat-dg2-11:         [DMESG-FAIL][31] -> [PASS][32]
   [31]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_13859/bat-dg2-11/igt@i915_selftest@live@hangcheck.html
   [32]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-dg2-11/igt@i915_selftest@live@hangcheck.html

  * igt@kms_pipe_crc_basic@read-crc-frame-sequence@pipe-d-edp-1:
    - bat-rplp-1:         [ABORT][33] ([i915#8668]) -> [PASS][34]
   [33]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_13859/bat-rplp-1/igt@kms_pipe_crc_basic@read-crc-frame-sequence@pipe-d-edp-1.html
   [34]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_10156/bat-rplp-1/igt@kms_pipe_crc_basic@read-crc-frame-sequence@pipe-d-edp-1.html

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

  [fdo#109285]: https://bugs.freedesktop.org/show_bug.cgi?id=109285
  [i915#1072]: https://gitlab.freedesktop.org/drm/intel/issues/1072
  [i915#180]: https://gitlab.freedesktop.org/drm/intel/issues/180
  [i915#1982]: https://gitlab.freedesktop.org/drm/intel/issues/1982
  [i915#3291]: https://gitlab.freedesktop.org/drm/intel/issues/3291
  [i915#3555]: https://gitlab.freedesktop.org/drm/intel/issues/3555
  [i915#3708]: https://gitlab.freedesktop.org/drm/intel/issues/3708
  [i915#4077]: https://gitlab.freedesktop.org/drm/intel/issues/4077
  [i915#4079]: https://gitlab.freedesktop.org/drm/intel/issues/4079
  [i915#4083]: https://gitlab.freedesktop.org/drm/intel/issues/4083
  [i915#4098]: https://gitlab.freedesktop.org/drm/intel/issues/4098
  [i915#4103]: https://gitlab.freedesktop.org/drm/intel/issues/4103
  [i915#4212]: https://gitlab.freedesktop.org/drm/intel/issues/4212
  [i915#4213]: https://gitlab.freedesktop.org/drm/intel/issues/4213
  [i915#4215]: https://gitlab.freedesktop.org/drm/intel/issues/4215
  [i915#5190]: https://gitlab.freedesktop.org/drm/intel/issues/5190
  [i915#5274]: https://gitlab.freedesktop.org/drm/intel/issues/5274
  [i915#5354]: https://gitlab.freedesktop.org/drm/intel/issues/5354
  [i915#5608]: https://gitlab.freedesktop.org/drm/intel/issues/5608
  [i915#6621]: https://gitlab.freedesktop.org/drm/intel/issues/6621
  [i915#8585]: https://gitlab.freedesktop.org/drm/intel/issues/8585
  [i915#8668]: https://gitlab.freedesktop.org/drm/intel/issues/8668
  [i915#8703]: https://gitlab.freedesktop.org/drm/intel/issues/8703


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

  * CI: CI-20190529 -> None
  * IGT: IGT_7581 -> IGTPW_10156

  CI-20190529: 20190529
  CI_DRM_13859: 9155ae0ae05f320d84eaf2c4e81413bf937a5f3c @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_10156: 10156
  IGT_7581: 7581


Testlist changes
----------------

+++ 744 lines
--- 0 lines

== Logs ==

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

[-- Attachment #2: Type: text/html, Size: 12607 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption
  2023-11-10  4:06 [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption Vignesh Raman
  2023-11-10  4:50 ` [igt-dev] ✗ CI.xeBAT: failure for lib/igt_kms: Fix memory corruption (rev4) Patchwork
  2023-11-10  5:04 ` [igt-dev] ✗ Fi.CI.BAT: " Patchwork
@ 2023-11-10  6:06 ` Modem, Bhanuprakash
  2023-11-10  6:52   ` Vignesh Raman
  2 siblings, 1 reply; 5+ messages in thread
From: Modem, Bhanuprakash @ 2023-11-10  6:06 UTC (permalink / raw)
  To: Vignesh Raman, daniels, igt-dev; +Cc: helen.koike

Hi Vignesh,

On Fri-10-11-2023 09:36 am, Vignesh Raman wrote:
> virtio-gpu kernel driver, which provides KMS, reports 16 for count_crtcs
> which exceeds IGT_MAX_PIPES set to 8. The function igt_display_require
> allocates memory for IGT_MAX_PIPES members of igt_pipe_t structures,
> but then writes into it based on the count_crtcs reported by the kernel,
> resulting in memory corruption.
> 
>   # malloc(): corrupted top size
>   # Received signal SIGABRT.
>   # Stack trace:
>   #  #0 [fatal_sig_handler+0x17b]
>   #  #1 [__sigaction+0x40]
>   #  #2 [pthread_key_delete+0x14c]
>   #  #3 [gsignal+0x12]
>   #  #4 [abort+0xd3]
>   #  #5 [__fsetlocking+0x290]
>   #  #6 [timer_settime+0x37a]
>   #  #7 [__default_morecore+0x1f1b]
>   #  #8 [__libc_calloc+0x161]
>   #  #9 [drmModeGetPlaneResources+0x44]
>   #  #10 [igt_display_require+0x194]
>   #  #11 [__igt_unique____real_main1356+0x93c]
>   #  #12 [main+0x3f]
>   #  #13 [__libc_init_first+0x8a]
>   #  #14 [__libc_start_main+0x85]
>   #  #15 [_start+0x21]
> 
> Increase IGT_MAX_PIPES to 16 to fix this memory corruption issue.
> igt_display_require initializes display and allocate resources as
> a prerequisite for the tests. Fail the test if count_crtcs exceeds
> IGT_MAX_PIPES with debug information. Additionally, update the test
> documentation to cover up to 16 pipes, and blacklist tests from
> pipe-i to pipe-p on both the XE blocklist and the intel-ci blacklist.
> 
> This fix is required for drm-ci to run igt tests on virtio-gpu.
> 
> Reviewed-by: Daniel Stone <daniels@collabora.com>
> Acked-by: Helen Koike <helen.koike@collabora.com>
> Suggested-by: Daniel Stone <daniels@collabora.com>
> Suggested-by: Bhanuprakash Modem <bhanuprakash.modem@intel.com>
> Signed-off-by: Vignesh Raman <vignesh.raman@collabora.com>
> ---
>   lib/igt_kms.c                   |  6 +++++-
>   lib/igt_kms.h                   | 20 +++++++++++++++++++-
>   tests/intel-ci/blacklist.txt    | 10 +++++++++-
>   tests/intel-ci/xe.blocklist.txt |  6 +++---
>   tests/intel/kms_ccs.c           | 24 ++++++++++++++++++++++++
>   tests/kms_bw.c                  |  2 +-

Probably, you need to split this patch into 3.

1- lib
2- tests
3- intel-ci

>   6 files changed, 61 insertions(+), 7 deletions(-)
> 
> diff --git a/lib/igt_kms.c b/lib/igt_kms.c
> index 453103f90..6ad7cc127 100644
> --- a/lib/igt_kms.c
> +++ b/lib/igt_kms.c
> @@ -906,7 +906,7 @@ static igt_plane_t *igt_get_assigned_primary(igt_output_t *output, igt_pipe_t *p
>    */
>   const char *kmstest_pipe_name(enum pipe pipe)
>   {
> -	static const char str[] = "A\0B\0C\0D\0E\0F\0G\0H";
> +	static const char str[] = "A\0B\0C\0D\0E\0F\0G\0H\0I\0J\0K\0L\0M\0N\0O\0P";
>   
>   	_Static_assert(sizeof(str) == IGT_MAX_PIPES * 2,
>   		       "Missing pipe name");
> @@ -2770,6 +2770,10 @@ void igt_display_require(igt_display_t *display, int drm_fd)
>   	}
>   #endif
>   
> +	igt_assert_f(resources->count_crtcs <= IGT_MAX_PIPES,
--------^
Could be igt_require_f()?

IMHO, we need to skip the test instead of fail. Since it is a basic 
requirement to fill display struct.

> +		     "count_crtcs exceeds IGT_MAX_PIPES, resources->count_crtcs=%d, IGT_MAX_PIPES=%d\n",
> +		     resources->count_crtcs, IGT_MAX_PIPES);
> +
>   	display->n_pipes = IGT_MAX_PIPES;
>   	display->pipes = calloc(sizeof(igt_pipe_t), display->n_pipes);
>   	igt_assert_f(display->pipes, "Failed to allocate memory for %d pipes\n", display->n_pipes);
> diff --git a/lib/igt_kms.h b/lib/igt_kms.h
> index 9028ab9be..5c705b585 100644
> --- a/lib/igt_kms.h
> +++ b/lib/igt_kms.h
> @@ -57,6 +57,16 @@
>    * @PIPE_D: Fourth crtc.
>    * @PIPE_E: Fifth crtc.
>    * @PIPE_F: Sixth crtc.
> + * @PIPE_G: Seventh crtc.
> + * @PIPE_H: Eighth crtc.
> + * @PIPE_I: Ninth crtc.
> + * @PIPE_J: Tenth crtc.
> + * @PIPE_K: Eleventh crtc.
> + * @PIPE_L: Twelfth crtc.
> + * @PIPE_M: Thirteenth crtc.
> + * @PIPE_N: Fourteenth crtc.
> + * @PIPE_O: Fifteenth crtc.
> + * @PIPE_P: Sixteenth crtc.
>    * @IGT_MAX_PIPES: Max number of pipes allowed.
>    */
>   enum pipe {
> @@ -70,7 +80,15 @@ enum pipe {
>           PIPE_F,
>   	PIPE_G,
>   	PIPE_H,
> -        IGT_MAX_PIPES
> +	PIPE_I,
> +	PIPE_J,
> +	PIPE_K,
> +	PIPE_L,
> +	PIPE_M,
> +	PIPE_N,
> +	PIPE_O,
> +	PIPE_P,
> +	IGT_MAX_PIPES
>   };
>   const char *kmstest_pipe_name(enum pipe pipe);
>   int kmstest_pipe_to_index(char pipe);
> diff --git a/tests/intel-ci/blacklist.txt b/tests/intel-ci/blacklist.txt
> index e13759d3e..e439e2af4 100644
> --- a/tests/intel-ci/blacklist.txt
> +++ b/tests/intel-ci/blacklist.txt
> @@ -117,12 +117,20 @@ igt@gem_ctx_isolation@.*-s4
>   ###############################################
>   igt@i915_suspend@shrink
>   ###############################################
> -# pipe-e, pipe-f, pipe-g, pipe-h no current HW support
> +# pipe-e, pipe-f, pipe-g, pipe-h, pipe-i, pipe-j, pipe-k, pipe-l, pipe-m, pipe-n, pipe-o, pipe-p no current HW support
>   ###############################################
>   igt@.*@.*pipe-e($|-.*)
>   igt@.*@.*pipe-f($|-.*)
>   igt@.*@.*pipe-g($|-.*)
>   igt@.*@.*pipe-h($|-.*)
> +igt@.*@.*pipe-i($|-.*)
> +igt@.*@.*pipe-j($|-.*)
> +igt@.*@.*pipe-k($|-.*)
> +igt@.*@.*pipe-l($|-.*)
> +igt@.*@.*pipe-m($|-.*)
> +igt@.*@.*pipe-n($|-.*)
> +igt@.*@.*pipe-o($|-.*)
> +igt@.*@.*pipe-p($|-.*)

Shall we simplify the regex as below?

igt@.*@.*pipe-[e-pE-P]($|-.*)

>   
>   ###############################################
>   # Temporary workarounds for CI-impacting bugs
> diff --git a/tests/intel-ci/xe.blocklist.txt b/tests/intel-ci/xe.blocklist.txt
> index 135ab18a3..bec6ee23b 100644
> --- a/tests/intel-ci/xe.blocklist.txt
> +++ b/tests/intel-ci/xe.blocklist.txt
> @@ -44,11 +44,11 @@ igt@syncobj_.*
>   igt@template
>   igt@tools_test
>   ##################################################################
> -# KMS: Pipe E, F, G and H are not available on Intel hardware,
> +# KMS: Pipe E, F, G, H, I, J, K, L, M, N, O and P are not available on Intel hardware,
>   # hence can't use more than 4 displays.
>   ##################################################################
> -igt@.*@.*pipe-(e|f|g|h).*
> -igt@kms_bw@.*-(5|6|7|8)-displays-.*
> +igt@.*@.*pipe-(e|f|g|h|i|j|k|l|m|n|o|p).*
> +igt@kms_bw@.*-(5|6|7|8|9|10|11|12|13|14|15|16)-displays-.*

igt@.*@.*pipe-[e-pE-P].*
igt@kms_bw@.*-([5-9]|1[0-6])-displays-.*

I used to validate my regex at https://regex101.com/

You can get my R-b after addressing above comments.

- Bhanu

>   ##################################################################
>   # KMS: Tests specific to i915 driver
>   ##################################################################
> diff --git a/tests/intel/kms_ccs.c b/tests/intel/kms_ccs.c
> index 93e837b84..6dc30ac24 100644
> --- a/tests/intel/kms_ccs.c
> +++ b/tests/intel/kms_ccs.c
> @@ -53,6 +53,14 @@
>    * @pipe-F:                    Pipe F
>    * @pipe-G:                    Pipe G
>    * @pipe-H:                    Pipe H
> + * @pipe-I:                    Pipe I
> + * @pipe-J:                    Pipe J
> + * @pipe-K:                    Pipe K
> + * @pipe-L:                    Pipe L
> + * @pipe-M:                    Pipe M
> + * @pipe-N:                    Pipe N
> + * @pipe-O:                    Pipe O
> + * @pipe-P:                    Pipe P
>    *
>    * arg[2]:
>    *
> @@ -90,6 +98,14 @@
>    * @pipe-F:                      Pipe F
>    * @pipe-G:                      Pipe G
>    * @pipe-H:                      Pipe H
> + * @pipe-I:                      Pipe I
> + * @pipe-J:                      Pipe J
> + * @pipe-K:                      Pipe K
> + * @pipe-L:                      Pipe L
> + * @pipe-M:                      Pipe M
> + * @pipe-N:                      Pipe N
> + * @pipe-O:                      Pipe O
> + * @pipe-P:                      Pipe P
>    *
>    * arg[2]:
>    *
> @@ -131,6 +147,14 @@
>    * @pipe-F:                      Pipe F
>    * @pipe-G:                      Pipe G
>    * @pipe-H:                      Pipe H
> + * @pipe-I:                      Pipe I
> + * @pipe-J:                      Pipe J
> + * @pipe-K:                      Pipe K
> + * @pipe-L:                      Pipe L
> + * @pipe-M:                      Pipe M
> + * @pipe-N:                      Pipe N
> + * @pipe-O:                      Pipe O
> + * @pipe-P:                      Pipe P
>    *
>    * arg[2]:
>    *
> diff --git a/tests/kms_bw.c b/tests/kms_bw.c
> index 5f9a020da..896114a3a 100644
> --- a/tests/kms_bw.c
> +++ b/tests/kms_bw.c
> @@ -37,7 +37,7 @@
>    * Mega feature: General Display Features
>    * Test category: functionality test
>    *
> - * arg[1].values: 1, 2, 3, 4, 5, 6, 7, 8
> + * arg[1].values: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16
>    *
>    * arg[2]:
>    *

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption
  2023-11-10  6:06 ` [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption Modem, Bhanuprakash
@ 2023-11-10  6:52   ` Vignesh Raman
  0 siblings, 0 replies; 5+ messages in thread
From: Vignesh Raman @ 2023-11-10  6:52 UTC (permalink / raw)
  To: Modem, Bhanuprakash, daniels, igt-dev; +Cc: helen.koike

Hi Bhanu,

On 10/11/23 11:36, Modem, Bhanuprakash wrote:
>> ---
>>   lib/igt_kms.c                   |  6 +++++-
>>   lib/igt_kms.h                   | 20 +++++++++++++++++++-
>>   tests/intel-ci/blacklist.txt    | 10 +++++++++-
>>   tests/intel-ci/xe.blocklist.txt |  6 +++---
>>   tests/intel/kms_ccs.c           | 24 ++++++++++++++++++++++++
>>   tests/kms_bw.c                  |  2 +-
> 
> Probably, you need to split this patch into 3.
> 
> 1- lib
> 2- tests
> 3- intel-ci

Sure, will split the changes into 3 commits.

>> @@ -2770,6 +2770,10 @@ void igt_display_require(igt_display_t 
>> *display, int drm_fd)
>>       }
>>   #endif
>> +    igt_assert_f(resources->count_crtcs <= IGT_MAX_PIPES,
> --------^
> Could be igt_require_f()?
> 
> IMHO, we need to skip the test instead of fail. Since it is a basic 
> requirement to fill display struct.

Okay, will skip the test. I was going through the failures mentioned in
https://patchwork.freedesktop.org/series/125599/

Are these known issues?

>> --- a/tests/intel-ci/blacklist.txt
>> +++ b/tests/intel-ci/blacklist.txt
>> @@ -117,12 +117,20 @@ igt@gem_ctx_isolation@.*-s4
>>   ###############################################
>>   igt@i915_suspend@shrink
>>   ###############################################
>> -# pipe-e, pipe-f, pipe-g, pipe-h no current HW support
>> +# pipe-e, pipe-f, pipe-g, pipe-h, pipe-i, pipe-j, pipe-k, pipe-l, 
>> pipe-m, pipe-n, pipe-o, pipe-p no current HW support
>>   ###############################################
>>   igt@.*@.*pipe-e($|-.*)
>>   igt@.*@.*pipe-f($|-.*)
>>   igt@.*@.*pipe-g($|-.*)
>>   igt@.*@.*pipe-h($|-.*)
>> +igt@.*@.*pipe-i($|-.*)
>> +igt@.*@.*pipe-j($|-.*)
>> +igt@.*@.*pipe-k($|-.*)
>> +igt@.*@.*pipe-l($|-.*)
>> +igt@.*@.*pipe-m($|-.*)
>> +igt@.*@.*pipe-n($|-.*)
>> +igt@.*@.*pipe-o($|-.*)
>> +igt@.*@.*pipe-p($|-.*)
> 
> Shall we simplify the regex as below?
> 
> igt@.*@.*pipe-[e-pE-P]($|-.*)

Yes, this looks good.

> 
>>   ###############################################
>>   # Temporary workarounds for CI-impacting bugs
>> diff --git a/tests/intel-ci/xe.blocklist.txt 
>> b/tests/intel-ci/xe.blocklist.txt
>> index 135ab18a3..bec6ee23b 100644
>> --- a/tests/intel-ci/xe.blocklist.txt
>> +++ b/tests/intel-ci/xe.blocklist.txt
>> @@ -44,11 +44,11 @@ igt@syncobj_.*
>>   igt@template
>>   igt@tools_test
>>   ##################################################################
>> -# KMS: Pipe E, F, G and H are not available on Intel hardware,
>> +# KMS: Pipe E, F, G, H, I, J, K, L, M, N, O and P are not available 
>> on Intel hardware,
>>   # hence can't use more than 4 displays.
>>   ##################################################################
>> -igt@.*@.*pipe-(e|f|g|h).*
>> -igt@kms_bw@.*-(5|6|7|8)-displays-.*
>> +igt@.*@.*pipe-(e|f|g|h|i|j|k|l|m|n|o|p).*
>> +igt@kms_bw@.*-(5|6|7|8|9|10|11|12|13|14|15|16)-displays-.*
> 
> igt@.*@.*pipe-[e-pE-P].*
> igt@kms_bw@.*-([5-9]|1[0-6])-displays-.*
> 
> I used to validate my regex at https://regex101.com/
> 
> You can get my R-b after addressing above comments.

Thank you.

Regards,
Vignesh

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-11-10  6:53 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-10  4:06 [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption Vignesh Raman
2023-11-10  4:50 ` [igt-dev] ✗ CI.xeBAT: failure for lib/igt_kms: Fix memory corruption (rev4) Patchwork
2023-11-10  5:04 ` [igt-dev] ✗ Fi.CI.BAT: " Patchwork
2023-11-10  6:06 ` [igt-dev] [PATCH i-g-t v4] lib/igt_kms: Fix memory corruption Modem, Bhanuprakash
2023-11-10  6:52   ` Vignesh Raman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox