All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t 1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm
@ 2018-08-10  7:01 ` Chris Wilson
  0 siblings, 0 replies; 12+ messages in thread
From: Chris Wilson @ 2018-08-10  7:01 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev, imre.deak

Check that we restore runtime pm around debug suspends and hibernates.

v2: Differentiate between external test setup failure and one of
interest

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 tests/pm_rpm.c | 18 ++++++++++++++----
 1 file changed, 14 insertions(+), 4 deletions(-)

diff --git a/tests/pm_rpm.c b/tests/pm_rpm.c
index 4268bb19a..1fbdda4ed 100644
--- a/tests/pm_rpm.c
+++ b/tests/pm_rpm.c
@@ -707,8 +707,10 @@ static void setup_environment(void)
 
 	igt_info("Runtime PM support: %d\n", has_runtime_pm);
 	igt_info("PC8 residency support: %d\n", has_pc8);
-
 	igt_require(has_runtime_pm);
+
+	disable_all_screens(&ms_data);
+	igt_require(wait_for_suspended());
 }
 
 static void restore_environment(void)
@@ -1372,10 +1374,11 @@ static void __attribute__((noreturn)) stay_subtest(void)
 		sleep(600);
 }
 
-static void system_suspend_subtest(void)
+static void system_suspend_subtest(int state, int debug)
 {
 	disable_all_screens_and_wait(&ms_data);
-	igt_system_suspend_autoresume(SUSPEND_STATE_MEM, SUSPEND_TEST_NONE);
+
+	igt_system_suspend_autoresume(state, debug);
 	igt_assert(wait_for_suspended());
 }
 
@@ -1992,12 +1995,19 @@ int main(int argc, char *argv[])
 				WAIT_STATUS | WAIT_EXTRA);
 
 	/* System suspend */
+	igt_subtest("system-suspend-devices")
+		system_suspend_subtest(SUSPEND_STATE_MEM, SUSPEND_TEST_DEVICES);
 	igt_subtest("system-suspend")
-		system_suspend_subtest();
+		system_suspend_subtest(SUSPEND_STATE_MEM, SUSPEND_TEST_NONE);
 	igt_subtest("system-suspend-execbuf")
 		system_suspend_execbuf_subtest();
 	igt_subtest("system-suspend-modeset")
 		system_suspend_modeset_subtest();
+	igt_subtest("system-hibernate-devices")
+		system_suspend_subtest(SUSPEND_STATE_DISK,
+				       SUSPEND_TEST_DEVICES);
+	igt_subtest("system-hibernate")
+		system_suspend_subtest(SUSPEND_STATE_DISK, SUSPEND_TEST_NONE);
 
 	/* GEM stress */
 	igt_subtest("gem-execbuf-stress")
-- 
2.18.0

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* [Intel-gfx] [PATCH i-g-t 1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm
@ 2018-08-10  7:01 ` Chris Wilson
  0 siblings, 0 replies; 12+ messages in thread
From: Chris Wilson @ 2018-08-10  7:01 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev, imre.deak

Check that we restore runtime pm around debug suspends and hibernates.

v2: Differentiate between external test setup failure and one of
interest

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 tests/pm_rpm.c | 18 ++++++++++++++----
 1 file changed, 14 insertions(+), 4 deletions(-)

diff --git a/tests/pm_rpm.c b/tests/pm_rpm.c
index 4268bb19a..1fbdda4ed 100644
--- a/tests/pm_rpm.c
+++ b/tests/pm_rpm.c
@@ -707,8 +707,10 @@ static void setup_environment(void)
 
 	igt_info("Runtime PM support: %d\n", has_runtime_pm);
 	igt_info("PC8 residency support: %d\n", has_pc8);
-
 	igt_require(has_runtime_pm);
+
+	disable_all_screens(&ms_data);
+	igt_require(wait_for_suspended());
 }
 
 static void restore_environment(void)
@@ -1372,10 +1374,11 @@ static void __attribute__((noreturn)) stay_subtest(void)
 		sleep(600);
 }
 
-static void system_suspend_subtest(void)
+static void system_suspend_subtest(int state, int debug)
 {
 	disable_all_screens_and_wait(&ms_data);
-	igt_system_suspend_autoresume(SUSPEND_STATE_MEM, SUSPEND_TEST_NONE);
+
+	igt_system_suspend_autoresume(state, debug);
 	igt_assert(wait_for_suspended());
 }
 
@@ -1992,12 +1995,19 @@ int main(int argc, char *argv[])
 				WAIT_STATUS | WAIT_EXTRA);
 
 	/* System suspend */
+	igt_subtest("system-suspend-devices")
+		system_suspend_subtest(SUSPEND_STATE_MEM, SUSPEND_TEST_DEVICES);
 	igt_subtest("system-suspend")
-		system_suspend_subtest();
+		system_suspend_subtest(SUSPEND_STATE_MEM, SUSPEND_TEST_NONE);
 	igt_subtest("system-suspend-execbuf")
 		system_suspend_execbuf_subtest();
 	igt_subtest("system-suspend-modeset")
 		system_suspend_modeset_subtest();
+	igt_subtest("system-hibernate-devices")
+		system_suspend_subtest(SUSPEND_STATE_DISK,
+				       SUSPEND_TEST_DEVICES);
+	igt_subtest("system-hibernate")
+		system_suspend_subtest(SUSPEND_STATE_DISK, SUSPEND_TEST_NONE);
 
 	/* GEM stress */
 	igt_subtest("gem-execbuf-stress")
-- 
2.18.0

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* [PATCH i-g-t 2/2] igt/pm_rpm: Test reaquisition of runtime-pm after module reload
  2018-08-10  7:01 ` [Intel-gfx] " Chris Wilson
@ 2018-08-10  7:01   ` Chris Wilson
  -1 siblings, 0 replies; 12+ messages in thread
From: Chris Wilson @ 2018-08-10  7:01 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev, imre.deak

It doesn't work right now and desperately needs to be fixed...

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 tests/intel-ci/fast-feedback.testlist |  1 +
 tests/pm_rpm.c                        | 28 ++++++++++++++++++++++++---
 2 files changed, 26 insertions(+), 3 deletions(-)

diff --git a/tests/intel-ci/fast-feedback.testlist b/tests/intel-ci/fast-feedback.testlist
index 1f3b95357..c625904d5 100644
--- a/tests/intel-ci/fast-feedback.testlist
+++ b/tests/intel-ci/fast-feedback.testlist
@@ -272,3 +272,4 @@ igt@vgem_basic@unload
 igt@drv_module_reload@basic-reload
 igt@drv_module_reload@basic-no-display
 igt@drv_module_reload@basic-reload-inject
+igt@pm_rpm@module-reload
diff --git a/tests/pm_rpm.c b/tests/pm_rpm.c
index 1fbdda4ed..79cdf969a 100644
--- a/tests/pm_rpm.c
+++ b/tests/pm_rpm.c
@@ -692,7 +692,7 @@ static void setup_pc8(void)
 	has_pc8 = true;
 }
 
-static void setup_environment(void)
+static bool setup_environment(void)
 {
 	drm_fd = drm_open_driver_master(DRIVER_INTEL);
 	debugfs = igt_debugfs_dir(drm_fd);
@@ -710,7 +710,7 @@ static void setup_environment(void)
 	igt_require(has_runtime_pm);
 
 	disable_all_screens(&ms_data);
-	igt_require(wait_for_suspended());
+	return wait_for_suspended();
 }
 
 static void restore_environment(void)
@@ -1905,7 +1905,7 @@ int main(int argc, char *argv[])
 	 * PC8+. We don't want bug reports from cases where the machine is just
 	 * not properly configured. */
 	igt_fixture
-		setup_environment();
+		igt_require(setup_environment());
 
 	if (stay)
 		igt_subtest("stay")
@@ -2026,5 +2026,27 @@ int main(int argc, char *argv[])
 	igt_fixture
 		teardown_environment();
 
+	igt_subtest("module-reload") {
+		igt_debug("Reload w/o display\n");
+		igt_i915_driver_unload();
+		igt_assert_eq(igt_i915_driver_load("disable_display=1"), 0);
+
+		igt_assert(setup_environment());
+		basic_subtest();
+		drm_resources_equal_subtest();
+		pci_d3_state_subtest();
+		teardown_environment();
+
+		igt_debug("Reload as normal\n");
+		igt_i915_driver_unload();
+		igt_assert_eq(igt_i915_driver_load(NULL), 0);
+
+		igt_assert(setup_environment());
+		basic_subtest();
+		drm_resources_equal_subtest();
+		pci_d3_state_subtest();
+		teardown_environment();
+	}
+
 	igt_exit();
 }
-- 
2.18.0

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* [igt-dev] [PATCH i-g-t 2/2] igt/pm_rpm: Test reaquisition of runtime-pm after module reload
@ 2018-08-10  7:01   ` Chris Wilson
  0 siblings, 0 replies; 12+ messages in thread
From: Chris Wilson @ 2018-08-10  7:01 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev, imre.deak

It doesn't work right now and desperately needs to be fixed...

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 tests/intel-ci/fast-feedback.testlist |  1 +
 tests/pm_rpm.c                        | 28 ++++++++++++++++++++++++---
 2 files changed, 26 insertions(+), 3 deletions(-)

diff --git a/tests/intel-ci/fast-feedback.testlist b/tests/intel-ci/fast-feedback.testlist
index 1f3b95357..c625904d5 100644
--- a/tests/intel-ci/fast-feedback.testlist
+++ b/tests/intel-ci/fast-feedback.testlist
@@ -272,3 +272,4 @@ igt@vgem_basic@unload
 igt@drv_module_reload@basic-reload
 igt@drv_module_reload@basic-no-display
 igt@drv_module_reload@basic-reload-inject
+igt@pm_rpm@module-reload
diff --git a/tests/pm_rpm.c b/tests/pm_rpm.c
index 1fbdda4ed..79cdf969a 100644
--- a/tests/pm_rpm.c
+++ b/tests/pm_rpm.c
@@ -692,7 +692,7 @@ static void setup_pc8(void)
 	has_pc8 = true;
 }
 
-static void setup_environment(void)
+static bool setup_environment(void)
 {
 	drm_fd = drm_open_driver_master(DRIVER_INTEL);
 	debugfs = igt_debugfs_dir(drm_fd);
@@ -710,7 +710,7 @@ static void setup_environment(void)
 	igt_require(has_runtime_pm);
 
 	disable_all_screens(&ms_data);
-	igt_require(wait_for_suspended());
+	return wait_for_suspended();
 }
 
 static void restore_environment(void)
@@ -1905,7 +1905,7 @@ int main(int argc, char *argv[])
 	 * PC8+. We don't want bug reports from cases where the machine is just
 	 * not properly configured. */
 	igt_fixture
-		setup_environment();
+		igt_require(setup_environment());
 
 	if (stay)
 		igt_subtest("stay")
@@ -2026,5 +2026,27 @@ int main(int argc, char *argv[])
 	igt_fixture
 		teardown_environment();
 
+	igt_subtest("module-reload") {
+		igt_debug("Reload w/o display\n");
+		igt_i915_driver_unload();
+		igt_assert_eq(igt_i915_driver_load("disable_display=1"), 0);
+
+		igt_assert(setup_environment());
+		basic_subtest();
+		drm_resources_equal_subtest();
+		pci_d3_state_subtest();
+		teardown_environment();
+
+		igt_debug("Reload as normal\n");
+		igt_i915_driver_unload();
+		igt_assert_eq(igt_i915_driver_load(NULL), 0);
+
+		igt_assert(setup_environment());
+		basic_subtest();
+		drm_resources_equal_subtest();
+		pci_d3_state_subtest();
+		teardown_environment();
+	}
+
 	igt_exit();
 }
-- 
2.18.0

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

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

* [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm
  2018-08-10  7:01 ` [Intel-gfx] " Chris Wilson
  (?)
  (?)
@ 2018-08-10 12:38 ` Patchwork
  -1 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2018-08-10 12:38 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev

== Series Details ==

Series: series starting with [i-g-t,1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm
URL   : https://patchwork.freedesktop.org/series/47988/
State : success

== Summary ==

= CI Bug Log - changes from CI_DRM_4642 -> IGTPW_1699 =

== Summary - SUCCESS ==

  No regressions found.

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

== Known issues ==

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

  === IGT changes ===

    ==== Issues hit ====

    igt@drv_module_reload@basic-reload-inject:
      fi-glk-j4005:       PASS -> DMESG-WARN (fdo#106725, fdo#106248)

    igt@drv_selftest@live_workarounds:
      fi-cnl-psr:         PASS -> DMESG-FAIL (fdo#107292)

    igt@kms_frontbuffer_tracking@basic:
      {fi-byt-clapper}:   PASS -> FAIL (fdo#103167)

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

    {igt@kms_psr@sprite_plane_onoff}:
      {fi-bdw-samus}:     NOTRUN -> FAIL (fdo#107360)

    
    ==== Possible fixes ====

    igt@drv_selftest@live_workarounds:
      {fi-bsw-kefka}:     DMESG-FAIL (fdo#107292) -> PASS
      fi-bdw-5557u:       DMESG-FAIL (fdo#107292) -> PASS

    
    ==== Warnings ====

    {igt@kms_psr@primary_page_flip}:
      fi-cnl-psr:         DMESG-WARN (fdo#107372) -> DMESG-FAIL (fdo#107372)

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

  fdo#103167 https://bugs.freedesktop.org/show_bug.cgi?id=103167
  fdo#103191 https://bugs.freedesktop.org/show_bug.cgi?id=103191
  fdo#106248 https://bugs.freedesktop.org/show_bug.cgi?id=106248
  fdo#106725 https://bugs.freedesktop.org/show_bug.cgi?id=106725
  fdo#107292 https://bugs.freedesktop.org/show_bug.cgi?id=107292
  fdo#107360 https://bugs.freedesktop.org/show_bug.cgi?id=107360
  fdo#107362 https://bugs.freedesktop.org/show_bug.cgi?id=107362
  fdo#107372 https://bugs.freedesktop.org/show_bug.cgi?id=107372


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

  Additional (1): fi-bdw-samus 
  Missing    (6): fi-kbl-soraka fi-ilk-m540 fi-hsw-4200u fi-byt-squawks fi-bsw-cyan fi-ctg-p8600 


== Build changes ==

    * IGT: IGT_4591 -> IGTPW_1699

  CI_DRM_4642: 0de4e9a02a422ebe523f59c3b462c949673746b6 @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_1699: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_1699/
  IGT_4591: 6cb3d7dbe5831a7b2b5b7a4638d8a8b7ac624f5f @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools



== Testlist changes ==

+igt@pm_rpm@module-reload
+igt@pm_rpm@system-hibernate
+igt@pm_rpm@system-hibernate-devices
+igt@pm_rpm@system-suspend-devices

== Logs ==

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

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

* [igt-dev] ✓ Fi.CI.IGT: success for series starting with [i-g-t,1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm
  2018-08-10  7:01 ` [Intel-gfx] " Chris Wilson
                   ` (2 preceding siblings ...)
  (?)
@ 2018-08-10 15:42 ` Patchwork
  -1 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2018-08-10 15:42 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev

== Series Details ==

Series: series starting with [i-g-t,1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm
URL   : https://patchwork.freedesktop.org/series/47988/
State : success

== Summary ==

= CI Bug Log - changes from IGT_4591_full -> IGTPW_1699_full =

== Summary - SUCCESS ==

  No regressions found.

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

== Possible new issues ==

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

  === IGT changes ===

    ==== Possible regressions ====

    {igt@pm_rpm@module-reload}:
      shard-hsw:          NOTRUN -> FAIL
      shard-glk:          NOTRUN -> FAIL
      shard-apl:          NOTRUN -> FAIL
      shard-kbl:          NOTRUN -> FAIL

    
== Known issues ==

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

  === IGT changes ===

    ==== Issues hit ====

    igt@gem_exec_schedule@pi-ringfull-render:
      shard-glk:          NOTRUN -> FAIL (fdo#103158)

    igt@gem_persistent_relocs@forked-faulting-reloc:
      shard-snb:          PASS -> INCOMPLETE (fdo#105411)

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

    igt@kms_setmode@basic:
      shard-apl:          PASS -> FAIL (fdo#99912)
      shard-glk:          NOTRUN -> FAIL (fdo#99912)

    igt@kms_universal_plane@cursor-fb-leak-pipe-c:
      shard-apl:          PASS -> FAIL (fdo#107241)

    
    ==== Possible fixes ====

    igt@gem_exec_store@basic-blt:
      shard-snb:          INCOMPLETE (fdo#105411) -> PASS

    igt@kms_available_modes_crc@available_mode_test_crc:
      shard-snb:          FAIL (fdo#106641) -> PASS

    igt@kms_pipe_crc_basic@suspend-read-crc-pipe-a:
      shard-kbl:          INCOMPLETE (fdo#103665) -> PASS

    igt@kms_setmode@basic:
      shard-kbl:          FAIL (fdo#99912) -> PASS

    igt@pm_rpm@i2c:
      shard-apl:          FAIL (fdo#106539) -> PASS
      shard-glk:          FAIL (fdo#106539) -> PASS
      shard-hsw:          FAIL (fdo#106539) -> PASS
      shard-kbl:          FAIL (fdo#106539) -> PASS

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

  fdo#103158 https://bugs.freedesktop.org/show_bug.cgi?id=103158
  fdo#103665 https://bugs.freedesktop.org/show_bug.cgi?id=103665
  fdo#105411 https://bugs.freedesktop.org/show_bug.cgi?id=105411
  fdo#106539 https://bugs.freedesktop.org/show_bug.cgi?id=106539
  fdo#106641 https://bugs.freedesktop.org/show_bug.cgi?id=106641
  fdo#107241 https://bugs.freedesktop.org/show_bug.cgi?id=107241
  fdo#99912 https://bugs.freedesktop.org/show_bug.cgi?id=99912


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

  No changes in participating hosts


== Build changes ==

    * IGT: IGT_4591 -> IGTPW_1699
    * Linux: CI_DRM_4636 -> CI_DRM_4642

  CI_DRM_4636: 084bb2fb549650b6da80976c9bc594779ce342b4 @ git://anongit.freedesktop.org/gfx-ci/linux
  CI_DRM_4642: 0de4e9a02a422ebe523f59c3b462c949673746b6 @ git://anongit.freedesktop.org/gfx-ci/linux
  IGTPW_1699: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_1699/
  IGT_4591: 6cb3d7dbe5831a7b2b5b7a4638d8a8b7ac624f5f @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools

== Logs ==

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

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

* Re: [PATCH i-g-t 1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm
  2018-08-10  7:01 ` [Intel-gfx] " Chris Wilson
@ 2018-08-14 13:52   ` Imre Deak
  -1 siblings, 0 replies; 12+ messages in thread
From: Imre Deak @ 2018-08-14 13:52 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev, imre.deak, intel-gfx

On Fri, Aug 10, 2018 at 08:01:15AM +0100, Chris Wilson wrote:
> Check that we restore runtime pm around debug suspends and hibernates.
> 
> v2: Differentiate between external test setup failure and one of
> interest
> 
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> ---
>  tests/pm_rpm.c | 18 ++++++++++++++----
>  1 file changed, 14 insertions(+), 4 deletions(-)
> 
> diff --git a/tests/pm_rpm.c b/tests/pm_rpm.c
> index 4268bb19a..1fbdda4ed 100644
> --- a/tests/pm_rpm.c
> +++ b/tests/pm_rpm.c
> @@ -707,8 +707,10 @@ static void setup_environment(void)
>  
>  	igt_info("Runtime PM support: %d\n", has_runtime_pm);
>  	igt_info("PC8 residency support: %d\n", has_pc8);
> -
>  	igt_require(has_runtime_pm);
> +
> +	disable_all_screens(&ms_data);
> +	igt_require(wait_for_suspended());

For some subtests (e.g. basic-rte) this check is the only (real)
purpose. So shouldn't this be added to specific subtests instead (e.g.
the system suspend ones) to avoid converting fail to skip?

Otherwise looks ok.

>  }
>  
>  static void restore_environment(void)
> @@ -1372,10 +1374,11 @@ static void __attribute__((noreturn)) stay_subtest(void)
>  		sleep(600);
>  }
>  
> -static void system_suspend_subtest(void)
> +static void system_suspend_subtest(int state, int debug)
>  {
>  	disable_all_screens_and_wait(&ms_data);
> -	igt_system_suspend_autoresume(SUSPEND_STATE_MEM, SUSPEND_TEST_NONE);
> +
> +	igt_system_suspend_autoresume(state, debug);
>  	igt_assert(wait_for_suspended());
>  }
>  
> @@ -1992,12 +1995,19 @@ int main(int argc, char *argv[])
>  				WAIT_STATUS | WAIT_EXTRA);
>  
>  	/* System suspend */
> +	igt_subtest("system-suspend-devices")
> +		system_suspend_subtest(SUSPEND_STATE_MEM, SUSPEND_TEST_DEVICES);
>  	igt_subtest("system-suspend")
> -		system_suspend_subtest();
> +		system_suspend_subtest(SUSPEND_STATE_MEM, SUSPEND_TEST_NONE);
>  	igt_subtest("system-suspend-execbuf")
>  		system_suspend_execbuf_subtest();
>  	igt_subtest("system-suspend-modeset")
>  		system_suspend_modeset_subtest();
> +	igt_subtest("system-hibernate-devices")
> +		system_suspend_subtest(SUSPEND_STATE_DISK,
> +				       SUSPEND_TEST_DEVICES);
> +	igt_subtest("system-hibernate")
> +		system_suspend_subtest(SUSPEND_STATE_DISK, SUSPEND_TEST_NONE);
>  
>  	/* GEM stress */
>  	igt_subtest("gem-execbuf-stress")
> -- 
> 2.18.0
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [Intel-gfx] [PATCH i-g-t 1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm
@ 2018-08-14 13:52   ` Imre Deak
  0 siblings, 0 replies; 12+ messages in thread
From: Imre Deak @ 2018-08-14 13:52 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev, imre.deak, intel-gfx

On Fri, Aug 10, 2018 at 08:01:15AM +0100, Chris Wilson wrote:
> Check that we restore runtime pm around debug suspends and hibernates.
> 
> v2: Differentiate between external test setup failure and one of
> interest
> 
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> ---
>  tests/pm_rpm.c | 18 ++++++++++++++----
>  1 file changed, 14 insertions(+), 4 deletions(-)
> 
> diff --git a/tests/pm_rpm.c b/tests/pm_rpm.c
> index 4268bb19a..1fbdda4ed 100644
> --- a/tests/pm_rpm.c
> +++ b/tests/pm_rpm.c
> @@ -707,8 +707,10 @@ static void setup_environment(void)
>  
>  	igt_info("Runtime PM support: %d\n", has_runtime_pm);
>  	igt_info("PC8 residency support: %d\n", has_pc8);
> -
>  	igt_require(has_runtime_pm);
> +
> +	disable_all_screens(&ms_data);
> +	igt_require(wait_for_suspended());

For some subtests (e.g. basic-rte) this check is the only (real)
purpose. So shouldn't this be added to specific subtests instead (e.g.
the system suspend ones) to avoid converting fail to skip?

Otherwise looks ok.

>  }
>  
>  static void restore_environment(void)
> @@ -1372,10 +1374,11 @@ static void __attribute__((noreturn)) stay_subtest(void)
>  		sleep(600);
>  }
>  
> -static void system_suspend_subtest(void)
> +static void system_suspend_subtest(int state, int debug)
>  {
>  	disable_all_screens_and_wait(&ms_data);
> -	igt_system_suspend_autoresume(SUSPEND_STATE_MEM, SUSPEND_TEST_NONE);
> +
> +	igt_system_suspend_autoresume(state, debug);
>  	igt_assert(wait_for_suspended());
>  }
>  
> @@ -1992,12 +1995,19 @@ int main(int argc, char *argv[])
>  				WAIT_STATUS | WAIT_EXTRA);
>  
>  	/* System suspend */
> +	igt_subtest("system-suspend-devices")
> +		system_suspend_subtest(SUSPEND_STATE_MEM, SUSPEND_TEST_DEVICES);
>  	igt_subtest("system-suspend")
> -		system_suspend_subtest();
> +		system_suspend_subtest(SUSPEND_STATE_MEM, SUSPEND_TEST_NONE);
>  	igt_subtest("system-suspend-execbuf")
>  		system_suspend_execbuf_subtest();
>  	igt_subtest("system-suspend-modeset")
>  		system_suspend_modeset_subtest();
> +	igt_subtest("system-hibernate-devices")
> +		system_suspend_subtest(SUSPEND_STATE_DISK,
> +				       SUSPEND_TEST_DEVICES);
> +	igt_subtest("system-hibernate")
> +		system_suspend_subtest(SUSPEND_STATE_DISK, SUSPEND_TEST_NONE);
>  
>  	/* GEM stress */
>  	igt_subtest("gem-execbuf-stress")
> -- 
> 2.18.0
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [PATCH i-g-t 1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm
  2018-08-14 13:52   ` [Intel-gfx] " Imre Deak
@ 2018-08-14 14:03     ` Chris Wilson
  -1 siblings, 0 replies; 12+ messages in thread
From: Chris Wilson @ 2018-08-14 14:03 UTC (permalink / raw)
  To: Imre Deak; +Cc: igt-dev, imre.deak, intel-gfx

Quoting Imre Deak (2018-08-14 14:52:16)
> On Fri, Aug 10, 2018 at 08:01:15AM +0100, Chris Wilson wrote:
> > Check that we restore runtime pm around debug suspends and hibernates.
> > 
> > v2: Differentiate between external test setup failure and one of
> > interest
> > 
> > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> > ---
> >  tests/pm_rpm.c | 18 ++++++++++++++----
> >  1 file changed, 14 insertions(+), 4 deletions(-)
> > 
> > diff --git a/tests/pm_rpm.c b/tests/pm_rpm.c
> > index 4268bb19a..1fbdda4ed 100644
> > --- a/tests/pm_rpm.c
> > +++ b/tests/pm_rpm.c
> > @@ -707,8 +707,10 @@ static void setup_environment(void)
> >  
> >       igt_info("Runtime PM support: %d\n", has_runtime_pm);
> >       igt_info("PC8 residency support: %d\n", has_pc8);
> > -
> >       igt_require(has_runtime_pm);
> > +
> > +     disable_all_screens(&ms_data);
> > +     igt_require(wait_for_suspended());
> 
> For some subtests (e.g. basic-rte) this check is the only (real)
> purpose. So shouldn't this be added to specific subtests instead (e.g.
> the system suspend ones) to avoid converting fail to skip?

The flip flop from PASS/SKIP is still significant, so I don't worry too
much. With a little tweak, it shall be done.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [Intel-gfx] [PATCH i-g-t 1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm
@ 2018-08-14 14:03     ` Chris Wilson
  0 siblings, 0 replies; 12+ messages in thread
From: Chris Wilson @ 2018-08-14 14:03 UTC (permalink / raw)
  To: Imre Deak; +Cc: igt-dev, imre.deak, intel-gfx

Quoting Imre Deak (2018-08-14 14:52:16)
> On Fri, Aug 10, 2018 at 08:01:15AM +0100, Chris Wilson wrote:
> > Check that we restore runtime pm around debug suspends and hibernates.
> > 
> > v2: Differentiate between external test setup failure and one of
> > interest
> > 
> > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> > ---
> >  tests/pm_rpm.c | 18 ++++++++++++++----
> >  1 file changed, 14 insertions(+), 4 deletions(-)
> > 
> > diff --git a/tests/pm_rpm.c b/tests/pm_rpm.c
> > index 4268bb19a..1fbdda4ed 100644
> > --- a/tests/pm_rpm.c
> > +++ b/tests/pm_rpm.c
> > @@ -707,8 +707,10 @@ static void setup_environment(void)
> >  
> >       igt_info("Runtime PM support: %d\n", has_runtime_pm);
> >       igt_info("PC8 residency support: %d\n", has_pc8);
> > -
> >       igt_require(has_runtime_pm);
> > +
> > +     disable_all_screens(&ms_data);
> > +     igt_require(wait_for_suspended());
> 
> For some subtests (e.g. basic-rte) this check is the only (real)
> purpose. So shouldn't this be added to specific subtests instead (e.g.
> the system suspend ones) to avoid converting fail to skip?

The flip flop from PASS/SKIP is still significant, so I don't worry too
much. With a little tweak, it shall be done.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [igt-dev] [PATCH i-g-t 2/2] igt/pm_rpm: Test reaquisition of runtime-pm after module reload
  2018-08-10  7:01   ` [igt-dev] " Chris Wilson
@ 2018-08-14 14:11     ` Imre Deak
  -1 siblings, 0 replies; 12+ messages in thread
From: Imre Deak @ 2018-08-14 14:11 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev, imre.deak, intel-gfx

On Fri, Aug 10, 2018 at 08:01:16AM +0100, Chris Wilson wrote:
> It doesn't work right now and desperately needs to be fixed...
> 
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

On both patches:
Reviewed-by: Imre Deak <imre.deak@intel.com>

> ---
>  tests/intel-ci/fast-feedback.testlist |  1 +
>  tests/pm_rpm.c                        | 28 ++++++++++++++++++++++++---
>  2 files changed, 26 insertions(+), 3 deletions(-)
> 
> diff --git a/tests/intel-ci/fast-feedback.testlist b/tests/intel-ci/fast-feedback.testlist
> index 1f3b95357..c625904d5 100644
> --- a/tests/intel-ci/fast-feedback.testlist
> +++ b/tests/intel-ci/fast-feedback.testlist
> @@ -272,3 +272,4 @@ igt@vgem_basic@unload
>  igt@drv_module_reload@basic-reload
>  igt@drv_module_reload@basic-no-display
>  igt@drv_module_reload@basic-reload-inject
> +igt@pm_rpm@module-reload
> diff --git a/tests/pm_rpm.c b/tests/pm_rpm.c
> index 1fbdda4ed..79cdf969a 100644
> --- a/tests/pm_rpm.c
> +++ b/tests/pm_rpm.c
> @@ -692,7 +692,7 @@ static void setup_pc8(void)
>  	has_pc8 = true;
>  }
>  
> -static void setup_environment(void)
> +static bool setup_environment(void)
>  {
>  	drm_fd = drm_open_driver_master(DRIVER_INTEL);
>  	debugfs = igt_debugfs_dir(drm_fd);
> @@ -710,7 +710,7 @@ static void setup_environment(void)
>  	igt_require(has_runtime_pm);
>  
>  	disable_all_screens(&ms_data);
> -	igt_require(wait_for_suspended());
> +	return wait_for_suspended();
>  }
>  
>  static void restore_environment(void)
> @@ -1905,7 +1905,7 @@ int main(int argc, char *argv[])
>  	 * PC8+. We don't want bug reports from cases where the machine is just
>  	 * not properly configured. */
>  	igt_fixture
> -		setup_environment();
> +		igt_require(setup_environment());
>  
>  	if (stay)
>  		igt_subtest("stay")
> @@ -2026,5 +2026,27 @@ int main(int argc, char *argv[])
>  	igt_fixture
>  		teardown_environment();
>  
> +	igt_subtest("module-reload") {
> +		igt_debug("Reload w/o display\n");
> +		igt_i915_driver_unload();
> +		igt_assert_eq(igt_i915_driver_load("disable_display=1"), 0);
> +
> +		igt_assert(setup_environment());
> +		basic_subtest();
> +		drm_resources_equal_subtest();
> +		pci_d3_state_subtest();
> +		teardown_environment();
> +
> +		igt_debug("Reload as normal\n");
> +		igt_i915_driver_unload();
> +		igt_assert_eq(igt_i915_driver_load(NULL), 0);
> +
> +		igt_assert(setup_environment());
> +		basic_subtest();
> +		drm_resources_equal_subtest();
> +		pci_d3_state_subtest();
> +		teardown_environment();
> +	}
> +
>  	igt_exit();
>  }
> -- 
> 2.18.0
> 
> _______________________________________________
> igt-dev mailing list
> igt-dev@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/igt-dev
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [igt-dev] [PATCH i-g-t 2/2] igt/pm_rpm: Test reaquisition of runtime-pm after module reload
@ 2018-08-14 14:11     ` Imre Deak
  0 siblings, 0 replies; 12+ messages in thread
From: Imre Deak @ 2018-08-14 14:11 UTC (permalink / raw)
  To: Chris Wilson; +Cc: igt-dev, imre.deak, intel-gfx

On Fri, Aug 10, 2018 at 08:01:16AM +0100, Chris Wilson wrote:
> It doesn't work right now and desperately needs to be fixed...
> 
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

On both patches:
Reviewed-by: Imre Deak <imre.deak@intel.com>

> ---
>  tests/intel-ci/fast-feedback.testlist |  1 +
>  tests/pm_rpm.c                        | 28 ++++++++++++++++++++++++---
>  2 files changed, 26 insertions(+), 3 deletions(-)
> 
> diff --git a/tests/intel-ci/fast-feedback.testlist b/tests/intel-ci/fast-feedback.testlist
> index 1f3b95357..c625904d5 100644
> --- a/tests/intel-ci/fast-feedback.testlist
> +++ b/tests/intel-ci/fast-feedback.testlist
> @@ -272,3 +272,4 @@ igt@vgem_basic@unload
>  igt@drv_module_reload@basic-reload
>  igt@drv_module_reload@basic-no-display
>  igt@drv_module_reload@basic-reload-inject
> +igt@pm_rpm@module-reload
> diff --git a/tests/pm_rpm.c b/tests/pm_rpm.c
> index 1fbdda4ed..79cdf969a 100644
> --- a/tests/pm_rpm.c
> +++ b/tests/pm_rpm.c
> @@ -692,7 +692,7 @@ static void setup_pc8(void)
>  	has_pc8 = true;
>  }
>  
> -static void setup_environment(void)
> +static bool setup_environment(void)
>  {
>  	drm_fd = drm_open_driver_master(DRIVER_INTEL);
>  	debugfs = igt_debugfs_dir(drm_fd);
> @@ -710,7 +710,7 @@ static void setup_environment(void)
>  	igt_require(has_runtime_pm);
>  
>  	disable_all_screens(&ms_data);
> -	igt_require(wait_for_suspended());
> +	return wait_for_suspended();
>  }
>  
>  static void restore_environment(void)
> @@ -1905,7 +1905,7 @@ int main(int argc, char *argv[])
>  	 * PC8+. We don't want bug reports from cases where the machine is just
>  	 * not properly configured. */
>  	igt_fixture
> -		setup_environment();
> +		igt_require(setup_environment());
>  
>  	if (stay)
>  		igt_subtest("stay")
> @@ -2026,5 +2026,27 @@ int main(int argc, char *argv[])
>  	igt_fixture
>  		teardown_environment();
>  
> +	igt_subtest("module-reload") {
> +		igt_debug("Reload w/o display\n");
> +		igt_i915_driver_unload();
> +		igt_assert_eq(igt_i915_driver_load("disable_display=1"), 0);
> +
> +		igt_assert(setup_environment());
> +		basic_subtest();
> +		drm_resources_equal_subtest();
> +		pci_d3_state_subtest();
> +		teardown_environment();
> +
> +		igt_debug("Reload as normal\n");
> +		igt_i915_driver_unload();
> +		igt_assert_eq(igt_i915_driver_load(NULL), 0);
> +
> +		igt_assert(setup_environment());
> +		basic_subtest();
> +		drm_resources_equal_subtest();
> +		pci_d3_state_subtest();
> +		teardown_environment();
> +	}
> +
>  	igt_exit();
>  }
> -- 
> 2.18.0
> 
> _______________________________________________
> igt-dev mailing list
> igt-dev@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/igt-dev
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

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

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

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-08-10  7:01 [PATCH i-g-t 1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm Chris Wilson
2018-08-10  7:01 ` [Intel-gfx] " Chris Wilson
2018-08-10  7:01 ` [PATCH i-g-t 2/2] igt/pm_rpm: Test reaquisition of runtime-pm after module reload Chris Wilson
2018-08-10  7:01   ` [igt-dev] " Chris Wilson
2018-08-14 14:11   ` Imre Deak
2018-08-14 14:11     ` Imre Deak
2018-08-10 12:38 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/2] igt/pm_rpm: Test incomplete(debug) suspends vs rpm Patchwork
2018-08-10 15:42 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2018-08-14 13:52 ` [PATCH i-g-t 1/2] " Imre Deak
2018-08-14 13:52   ` [Intel-gfx] " Imre Deak
2018-08-14 14:03   ` Chris Wilson
2018-08-14 14:03     ` [Intel-gfx] " Chris Wilson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.