public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t 1/2] tests/kms_properties: Add additional prperty test infrastructure
@ 2018-10-11  0:14 Radhakrishna Sripada
  2018-10-11  0:14 ` [igt-dev] [PATCH i-g-t 2/2] tests/kms_properties: Add functional test for "max bpc" property Radhakrishna Sripada
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Radhakrishna Sripada @ 2018-10-11  0:14 UTC (permalink / raw)
  To: igt-dev

We currently test the existimg properties by setting them with default value.
Add infrastructure to perform additional test on a desired property.

Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Radhakrishna Sripada <radhakrishna.sripada@intel.com>
---
 tests/kms_properties.c | 28 +++++++++++++++++++++++++++-
 1 file changed, 27 insertions(+), 1 deletion(-)

diff --git a/tests/kms_properties.c b/tests/kms_properties.c
index 9548cf44017a..bd3e82761f6e 100644
--- a/tests/kms_properties.c
+++ b/tests/kms_properties.c
@@ -29,6 +29,13 @@
 #include <string.h>
 #include <time.h>
 
+struct additional_test {
+	char *name;
+	uint32_t obj_type;
+	void (*prop_test)(int fd, uint32_t id, uint32_t type, drmModePropertyPtr prop,
+			  uint32_t prop_id, uint64_t prop_value, bool atomic);
+};
+
 static void prepare_pipe(igt_display_t *display, enum pipe pipe, igt_output_t *output, struct igt_fb *fb)
 {
 	drmModeModeInfo *mode = igt_output_get_mode(output);
@@ -75,11 +82,27 @@ static bool ignore_property(uint32_t obj_type, uint32_t prop_flags,
 	return false;
 }
 
+static const struct additional_test property_functional_test[] = {};
+
+static bool has_additional_test_lookup(uint32_t obj_type, const char *name,
+				bool atomic, int *index)
+{
+	int i;
+
+	for (i = 0; i < ARRAY_SIZE(property_functional_test); i++)
+		if (property_functional_test[i].obj_type == obj_type &&
+		    strcmp(name, property_functional_test[i].name)) {
+			*index = i;
+			return true;
+		}
+
+	return false;
+}
 static void test_properties(int fd, uint32_t type, uint32_t id, bool atomic)
 {
 	drmModeObjectPropertiesPtr props =
 		drmModeObjectGetProperties(fd, id, type);
-	int i, ret;
+	int i, j, ret;
 	drmModeAtomicReqPtr req = NULL;
 
 	igt_assert(props);
@@ -114,6 +137,9 @@ static void test_properties(int fd, uint32_t type, uint32_t id, bool atomic)
 			igt_assert_eq(ret, 0);
 		}
 
+		if (has_additional_test_lookup(type, prop->name, atomic, &j))
+			property_functional_test[j].prop_test(fd, id, type, prop, prop_id, prop_value, atomic);
+
 		drmModeFreeProperty(prop);
 	}
 
-- 
2.9.3

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* [igt-dev] [PATCH i-g-t 2/2] tests/kms_properties: Add functional test for "max bpc" property
  2018-10-11  0:14 [igt-dev] [PATCH i-g-t 1/2] tests/kms_properties: Add additional prperty test infrastructure Radhakrishna Sripada
@ 2018-10-11  0:14 ` Radhakrishna Sripada
  2018-10-11  1:28 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/2] tests/kms_properties: Add additional prperty test infrastructure Patchwork
  2018-10-11 11:03 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
  2 siblings, 0 replies; 4+ messages in thread
From: Radhakrishna Sripada @ 2018-10-11  0:14 UTC (permalink / raw)
  To: igt-dev

Test the values in the range advertised by the "max bpc" property.

Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Radhakrishna Sripada <radhakrishna.sripada@intel.com>
---
 tests/kms_properties.c | 32 +++++++++++++++++++++++++++++++-
 1 file changed, 31 insertions(+), 1 deletion(-)

diff --git a/tests/kms_properties.c b/tests/kms_properties.c
index bd3e82761f6e..97b5b950b5a5 100644
--- a/tests/kms_properties.c
+++ b/tests/kms_properties.c
@@ -82,7 +82,37 @@ static bool ignore_property(uint32_t obj_type, uint32_t prop_flags,
 	return false;
 }
 
-static const struct additional_test property_functional_test[] = {};
+static void max_bpc_prop_test(int fd, uint32_t id, uint32_t type, drmModePropertyPtr prop,
+			      uint32_t prop_id, uint64_t prop_value, bool atomic)
+{
+	drmModeAtomicReqPtr req = NULL;
+	int i, ret;
+
+	if (atomic)
+		req = drmModeAtomicAlloc();
+
+	for ( i = prop->values[0]; i < prop->values[1] ; i++) {
+		if (!atomic) {
+			ret = drmModeObjectSetProperty(fd, id, type, prop_id, i);
+
+			igt_assert_eq(ret, 0);
+		} else {
+			ret = drmModeAtomicAddProperty(req, id, prop_id, i);
+			igt_assert(ret >= 0);
+
+			ret = drmModeAtomicCommit(fd, req, DRM_MODE_ATOMIC_TEST_ONLY, NULL);
+			igt_assert_eq(ret, 0);
+		}
+	}
+
+	if (atomic)
+		drmModeAtomicFree(req);
+}
+
+static const struct additional_test property_functional_test[] = {
+									{"max bpc", DRM_MODE_OBJECT_CONNECTOR,
+									 max_bpc_prop_test},
+								 };
 
 static bool has_additional_test_lookup(uint32_t obj_type, const char *name,
 				bool atomic, int *index)
-- 
2.9.3

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/2] tests/kms_properties: Add additional prperty test infrastructure
  2018-10-11  0:14 [igt-dev] [PATCH i-g-t 1/2] tests/kms_properties: Add additional prperty test infrastructure Radhakrishna Sripada
  2018-10-11  0:14 ` [igt-dev] [PATCH i-g-t 2/2] tests/kms_properties: Add functional test for "max bpc" property Radhakrishna Sripada
@ 2018-10-11  1:28 ` Patchwork
  2018-10-11 11:03 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
  2 siblings, 0 replies; 4+ messages in thread
From: Patchwork @ 2018-10-11  1:28 UTC (permalink / raw)
  To: Radhakrishna Sripada; +Cc: igt-dev

== Series Details ==

Series: series starting with [i-g-t,1/2] tests/kms_properties: Add additional prperty test infrastructure
URL   : https://patchwork.freedesktop.org/series/50838/
State : success

== Summary ==

= CI Bug Log - changes from CI_DRM_4958 -> IGTPW_1936 =

== Summary - SUCCESS ==

  No regressions found.

  External URL: https://patchwork.freedesktop.org/api/1.0/series/50838/revisions/1/mbox/

== Known issues ==

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

  === IGT changes ===

    ==== Issues hit ====

    igt@drv_module_reload@basic-reload:
      fi-blb-e6850:       PASS -> INCOMPLETE (fdo#107718)

    igt@kms_pipe_crc_basic@hang-read-crc-pipe-a:
      fi-byt-clapper:     PASS -> FAIL (fdo#103191, fdo#107362)

    
    ==== Possible fixes ====

    igt@pm_rpm@basic-pci-d3-state:
      fi-skl-6600u:       FAIL (fdo#107707) -> PASS

    igt@prime_vgem@basic-fence-flip:
      fi-ilk-650:         FAIL (fdo#104008) -> PASS

    
  fdo#103191 https://bugs.freedesktop.org/show_bug.cgi?id=103191
  fdo#104008 https://bugs.freedesktop.org/show_bug.cgi?id=104008
  fdo#107362 https://bugs.freedesktop.org/show_bug.cgi?id=107362
  fdo#107707 https://bugs.freedesktop.org/show_bug.cgi?id=107707
  fdo#107718 https://bugs.freedesktop.org/show_bug.cgi?id=107718


== Participating hosts (48 -> 40) ==

  Missing    (8): fi-cnl-u fi-ilk-m540 fi-hsw-4200u fi-byt-squawks fi-icl-u2 fi-bwr-2160 fi-bsw-cyan fi-ctg-p8600 


== Build changes ==

    * IGT: IGT_4672 -> IGTPW_1936

  CI_DRM_4958: 9990e1665029dc2ef4a9c0632b8a2f516263e595 @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_1936: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_1936/
  IGT_4672: 4497591d2572831a9f07fd9e48a2571bfcffe354 @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_1936/issues.html
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

* [igt-dev] ✗ Fi.CI.IGT: failure for series starting with [i-g-t,1/2] tests/kms_properties: Add additional prperty test infrastructure
  2018-10-11  0:14 [igt-dev] [PATCH i-g-t 1/2] tests/kms_properties: Add additional prperty test infrastructure Radhakrishna Sripada
  2018-10-11  0:14 ` [igt-dev] [PATCH i-g-t 2/2] tests/kms_properties: Add functional test for "max bpc" property Radhakrishna Sripada
  2018-10-11  1:28 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/2] tests/kms_properties: Add additional prperty test infrastructure Patchwork
@ 2018-10-11 11:03 ` Patchwork
  2 siblings, 0 replies; 4+ messages in thread
From: Patchwork @ 2018-10-11 11:03 UTC (permalink / raw)
  To: Radhakrishna Sripada; +Cc: igt-dev

== Series Details ==

Series: series starting with [i-g-t,1/2] tests/kms_properties: Add additional prperty test infrastructure
URL   : https://patchwork.freedesktop.org/series/50838/
State : failure

== Summary ==

= CI Bug Log - changes from IGT_4672_full -> IGTPW_1936_full =

== Summary - FAILURE ==

  Serious unknown changes coming with IGTPW_1936_full absolutely need to be
  verified manually.
  
  If you think the reported changes have nothing to do with the changes
  introduced in IGTPW_1936_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://patchwork.freedesktop.org/api/1.0/series/50838/revisions/1/mbox/

== Possible new issues ==

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

  === IGT changes ===

    ==== Possible regressions ====

    igt@kms_properties@connector-properties-atomic:
      shard-apl:          PASS -> FAIL
      shard-glk:          PASS -> FAIL
      shard-hsw:          PASS -> FAIL
      shard-kbl:          PASS -> FAIL

    
    ==== Warnings ====

    igt@pm_rc6_residency@rc6-accuracy:
      shard-snb:          PASS -> SKIP

    
== Known issues ==

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

  === IGT changes ===

    ==== Issues hit ====

    igt@drv_suspend@shrink:
      shard-glk:          PASS -> INCOMPLETE (k.org#198133, fdo#103359, fdo#106886)

    igt@gem_mmap_gtt@big-copy-odd:
      shard-apl:          PASS -> INCOMPLETE (fdo#103927)

    igt@kms_color@pipe-a-legacy-gamma:
      shard-kbl:          PASS -> FAIL (fdo#104782, fdo#108145)
      shard-apl:          PASS -> FAIL (fdo#104782, fdo#108145)

    igt@kms_cursor_crc@cursor-128x128-sliding:
      shard-apl:          PASS -> FAIL (fdo#103232) +1

    igt@kms_cursor_crc@cursor-128x128-suspend:
      shard-glk:          PASS -> FAIL (fdo#103232) +3

    igt@kms_cursor_crc@cursor-256x256-suspend:
      shard-kbl:          PASS -> FAIL (fdo#103191, fdo#103232) +1
      shard-apl:          PASS -> FAIL (fdo#103191, fdo#103232)

    igt@kms_cursor_crc@cursor-64x64-random:
      shard-kbl:          PASS -> FAIL (fdo#103232) +1

    igt@kms_fbcon_fbt@fbc-suspend:
      shard-kbl:          PASS -> INCOMPLETE (fdo#103665)

    igt@kms_flip@2x-flip-vs-expired-vblank:
      shard-hsw:          PASS -> FAIL (fdo#102887)

    igt@kms_flip@flip-vs-expired-vblank-interruptible:
      shard-glk:          PASS -> FAIL (fdo#105363)

    igt@kms_frontbuffer_tracking@fbc-1p-primscrn-spr-indfb-draw-mmap-gtt:
      shard-apl:          PASS -> FAIL (fdo#103167) +3
      shard-kbl:          PASS -> FAIL (fdo#103167)

    igt@kms_frontbuffer_tracking@fbc-2p-primscrn-spr-indfb-onoff:
      shard-glk:          PASS -> FAIL (fdo#103167) +10

    igt@kms_plane@plane-position-covered-pipe-b-planes:
      shard-glk:          PASS -> FAIL (fdo#103166) +2

    {igt@kms_plane_alpha_blend@pipe-a-constant-alpha-max}:
      shard-glk:          PASS -> FAIL (fdo#108145) +1
      shard-kbl:          PASS -> FAIL (fdo#108145) +1
      shard-apl:          PASS -> FAIL (fdo#108145)

    igt@kms_plane_multiple@atomic-pipe-b-tiling-yf:
      shard-apl:          PASS -> FAIL (fdo#103166)

    
    ==== Possible fixes ====

    igt@kms_cursor_crc@cursor-256x256-sliding:
      shard-glk:          FAIL (fdo#103232) -> PASS +2

    igt@kms_cursor_crc@cursor-64x64-sliding:
      shard-apl:          FAIL (fdo#103232) -> PASS +1
      shard-kbl:          FAIL (fdo#103232) -> PASS

    igt@kms_cursor_legacy@2x-long-cursor-vs-flip-atomic:
      shard-hsw:          FAIL (fdo#105767) -> PASS

    igt@kms_frontbuffer_tracking@fbc-2p-primscrn-spr-indfb-draw-mmap-wc:
      shard-glk:          FAIL (fdo#103167) -> PASS +1

    igt@kms_plane_multiple@atomic-pipe-b-tiling-x:
      shard-glk:          FAIL (fdo#103166) -> PASS +1
      shard-apl:          FAIL (fdo#103166) -> PASS +2

    
    ==== Warnings ====

    igt@kms_cursor_crc@cursor-64x64-suspend:
      shard-glk:          INCOMPLETE (fdo#103359, k.org#198133) -> FAIL (fdo#103232)

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

  fdo#102887 https://bugs.freedesktop.org/show_bug.cgi?id=102887
  fdo#103166 https://bugs.freedesktop.org/show_bug.cgi?id=103166
  fdo#103167 https://bugs.freedesktop.org/show_bug.cgi?id=103167
  fdo#103191 https://bugs.freedesktop.org/show_bug.cgi?id=103191
  fdo#103232 https://bugs.freedesktop.org/show_bug.cgi?id=103232
  fdo#103359 https://bugs.freedesktop.org/show_bug.cgi?id=103359
  fdo#103665 https://bugs.freedesktop.org/show_bug.cgi?id=103665
  fdo#103927 https://bugs.freedesktop.org/show_bug.cgi?id=103927
  fdo#104782 https://bugs.freedesktop.org/show_bug.cgi?id=104782
  fdo#105363 https://bugs.freedesktop.org/show_bug.cgi?id=105363
  fdo#105767 https://bugs.freedesktop.org/show_bug.cgi?id=105767
  fdo#106886 https://bugs.freedesktop.org/show_bug.cgi?id=106886
  fdo#108145 https://bugs.freedesktop.org/show_bug.cgi?id=108145
  k.org#198133 https://bugzilla.kernel.org/show_bug.cgi?id=198133


== Participating hosts (6 -> 5) ==

  Missing    (1): shard-skl 


== Build changes ==

    * IGT: IGT_4672 -> IGTPW_1936
    * Linux: CI_DRM_4952 -> CI_DRM_4958

  CI_DRM_4952: a62e43ba13605a478b22307ea1790d48aea029a6 @ git://anongit.freedesktop.org/gfx-ci/linux
  CI_DRM_4958: 9990e1665029dc2ef4a9c0632b8a2f516263e595 @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_1936: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_1936/
  IGT_4672: 4497591d2572831a9f07fd9e48a2571bfcffe354 @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_1936/shards.html
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

end of thread, other threads:[~2018-10-11 11:03 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-10-11  0:14 [igt-dev] [PATCH i-g-t 1/2] tests/kms_properties: Add additional prperty test infrastructure Radhakrishna Sripada
2018-10-11  0:14 ` [igt-dev] [PATCH i-g-t 2/2] tests/kms_properties: Add functional test for "max bpc" property Radhakrishna Sripada
2018-10-11  1:28 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/2] tests/kms_properties: Add additional prperty test infrastructure Patchwork
2018-10-11 11:03 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork

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