Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t] i915/gem_exec_suspend: Exercise S0 (aka s2idle)
@ 2019-10-07 11:06 Chris Wilson
  2019-10-25 19:16 ` [igt-dev] " Mika Kuoppala
  0 siblings, 1 reply; 3+ messages in thread
From: Chris Wilson @ 2019-10-07 11:06 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev

Exercise the first level of suspend, S0. This is basically the same as
our runtime-suspend, we need to put the device to sleep but otherwise
it is left powered up.

Ideally, we would measure the energy consumption in this state.

References: https://bugs.freedesktop.org/show_bug.cgi?id=111909
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 tests/i915/gem_exec_suspend.c         | 16 ++++++++++++----
 tests/intel-ci/fast-feedback.testlist |  1 +
 2 files changed, 13 insertions(+), 4 deletions(-)

diff --git a/tests/i915/gem_exec_suspend.c b/tests/i915/gem_exec_suspend.c
index e43a16e9e..f25f1a86b 100644
--- a/tests/i915/gem_exec_suspend.c
+++ b/tests/i915/gem_exec_suspend.c
@@ -32,10 +32,11 @@
 #include "igt_dummyload.h"
 
 #define NOSLEEP 0
-#define SUSPEND_DEVICES 1
-#define SUSPEND 2
-#define HIBERNATE_DEVICES 3
-#define HIBERNATE 4
+#define IDLE 1
+#define SUSPEND_DEVICES 2
+#define SUSPEND 3
+#define HIBERNATE_DEVICES 4
+#define HIBERNATE 5
 #define mode(x) ((x) & 0xff)
 
 #define LOCAL_I915_EXEC_BSD_SHIFT      (13)
@@ -195,6 +196,11 @@ static void run_test(int fd, unsigned engine, unsigned flags)
 	case NOSLEEP:
 		break;
 
+	case IDLE:
+		igt_system_suspend_autoresume(SUSPEND_STATE_FREEZE,
+					      SUSPEND_TEST_NONE);
+		break;
+
 	case SUSPEND_DEVICES:
 		igt_system_suspend_autoresume(SUSPEND_STATE_MEM,
 					      SUSPEND_TEST_DEVICES);
@@ -255,6 +261,8 @@ igt_main
 
 	igt_subtest("basic")
 		run_test(fd, ALL_ENGINES, NOSLEEP);
+	igt_subtest("basic-S0")
+		run_test(fd, ALL_ENGINES, IDLE);
 	igt_subtest("basic-S3-devices")
 		run_test(fd, ALL_ENGINES, SUSPEND_DEVICES);
 	igt_subtest("basic-S3")
diff --git a/tests/intel-ci/fast-feedback.testlist b/tests/intel-ci/fast-feedback.testlist
index e78e7fd0c..2553a68c3 100644
--- a/tests/intel-ci/fast-feedback.testlist
+++ b/tests/intel-ci/fast-feedback.testlist
@@ -56,6 +56,7 @@ igt@gem_exec_reloc@basic-write-read-active
 igt@gem_exec_reloc@basic-softpin
 igt@gem_exec_store@basic-all
 igt@gem_exec_suspend@basic
+igt@gem_exec_suspend@basic-s0
 igt@gem_exec_suspend@basic-s3
 igt@gem_exec_suspend@basic-s4-devices
 igt@gem_flink_basic@bad-flink
-- 
2.23.0

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

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

* Re: [igt-dev] [PATCH i-g-t] i915/gem_exec_suspend: Exercise S0 (aka s2idle)
  2019-10-07 11:06 [PATCH i-g-t] i915/gem_exec_suspend: Exercise S0 (aka s2idle) Chris Wilson
@ 2019-10-25 19:16 ` Mika Kuoppala
  2019-10-25 19:16   ` [Intel-gfx] " Mika Kuoppala
  0 siblings, 1 reply; 3+ messages in thread
From: Mika Kuoppala @ 2019-10-25 19:16 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx; +Cc: igt-dev

Chris Wilson <chris@chris-wilson.co.uk> writes:

> Exercise the first level of suspend, S0. This is basically the same as
> our runtime-suspend, we need to put the device to sleep but otherwise
> it is left powered up.
>
> Ideally, we would measure the energy consumption in this state.

This and the others.

Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>

>
> References: https://bugs.freedesktop.org/show_bug.cgi?id=111909
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> ---
>  tests/i915/gem_exec_suspend.c         | 16 ++++++++++++----
>  tests/intel-ci/fast-feedback.testlist |  1 +
>  2 files changed, 13 insertions(+), 4 deletions(-)
>
> diff --git a/tests/i915/gem_exec_suspend.c b/tests/i915/gem_exec_suspend.c
> index e43a16e9e..f25f1a86b 100644
> --- a/tests/i915/gem_exec_suspend.c
> +++ b/tests/i915/gem_exec_suspend.c
> @@ -32,10 +32,11 @@
>  #include "igt_dummyload.h"
>  
>  #define NOSLEEP 0
> -#define SUSPEND_DEVICES 1
> -#define SUSPEND 2
> -#define HIBERNATE_DEVICES 3
> -#define HIBERNATE 4
> +#define IDLE 1
> +#define SUSPEND_DEVICES 2
> +#define SUSPEND 3
> +#define HIBERNATE_DEVICES 4
> +#define HIBERNATE 5
>  #define mode(x) ((x) & 0xff)
>  
>  #define LOCAL_I915_EXEC_BSD_SHIFT      (13)
> @@ -195,6 +196,11 @@ static void run_test(int fd, unsigned engine, unsigned flags)
>  	case NOSLEEP:
>  		break;
>  
> +	case IDLE:
> +		igt_system_suspend_autoresume(SUSPEND_STATE_FREEZE,
> +					      SUSPEND_TEST_NONE);
> +		break;
> +
>  	case SUSPEND_DEVICES:
>  		igt_system_suspend_autoresume(SUSPEND_STATE_MEM,
>  					      SUSPEND_TEST_DEVICES);
> @@ -255,6 +261,8 @@ igt_main
>  
>  	igt_subtest("basic")
>  		run_test(fd, ALL_ENGINES, NOSLEEP);
> +	igt_subtest("basic-S0")
> +		run_test(fd, ALL_ENGINES, IDLE);
>  	igt_subtest("basic-S3-devices")
>  		run_test(fd, ALL_ENGINES, SUSPEND_DEVICES);
>  	igt_subtest("basic-S3")
> diff --git a/tests/intel-ci/fast-feedback.testlist b/tests/intel-ci/fast-feedback.testlist
> index e78e7fd0c..2553a68c3 100644
> --- a/tests/intel-ci/fast-feedback.testlist
> +++ b/tests/intel-ci/fast-feedback.testlist
> @@ -56,6 +56,7 @@ igt@gem_exec_reloc@basic-write-read-active
>  igt@gem_exec_reloc@basic-softpin
>  igt@gem_exec_store@basic-all
>  igt@gem_exec_suspend@basic
> +igt@gem_exec_suspend@basic-s0
>  igt@gem_exec_suspend@basic-s3
>  igt@gem_exec_suspend@basic-s4-devices
>  igt@gem_flink_basic@bad-flink
> -- 
> 2.23.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] 3+ messages in thread

* Re: [Intel-gfx] [igt-dev] [PATCH i-g-t] i915/gem_exec_suspend: Exercise S0 (aka s2idle)
  2019-10-25 19:16 ` [igt-dev] " Mika Kuoppala
@ 2019-10-25 19:16   ` Mika Kuoppala
  0 siblings, 0 replies; 3+ messages in thread
From: Mika Kuoppala @ 2019-10-25 19:16 UTC (permalink / raw)
  To: Chris Wilson, intel-gfx; +Cc: igt-dev

Chris Wilson <chris@chris-wilson.co.uk> writes:

> Exercise the first level of suspend, S0. This is basically the same as
> our runtime-suspend, we need to put the device to sleep but otherwise
> it is left powered up.
>
> Ideally, we would measure the energy consumption in this state.

This and the others.

Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>

>
> References: https://bugs.freedesktop.org/show_bug.cgi?id=111909
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> ---
>  tests/i915/gem_exec_suspend.c         | 16 ++++++++++++----
>  tests/intel-ci/fast-feedback.testlist |  1 +
>  2 files changed, 13 insertions(+), 4 deletions(-)
>
> diff --git a/tests/i915/gem_exec_suspend.c b/tests/i915/gem_exec_suspend.c
> index e43a16e9e..f25f1a86b 100644
> --- a/tests/i915/gem_exec_suspend.c
> +++ b/tests/i915/gem_exec_suspend.c
> @@ -32,10 +32,11 @@
>  #include "igt_dummyload.h"
>  
>  #define NOSLEEP 0
> -#define SUSPEND_DEVICES 1
> -#define SUSPEND 2
> -#define HIBERNATE_DEVICES 3
> -#define HIBERNATE 4
> +#define IDLE 1
> +#define SUSPEND_DEVICES 2
> +#define SUSPEND 3
> +#define HIBERNATE_DEVICES 4
> +#define HIBERNATE 5
>  #define mode(x) ((x) & 0xff)
>  
>  #define LOCAL_I915_EXEC_BSD_SHIFT      (13)
> @@ -195,6 +196,11 @@ static void run_test(int fd, unsigned engine, unsigned flags)
>  	case NOSLEEP:
>  		break;
>  
> +	case IDLE:
> +		igt_system_suspend_autoresume(SUSPEND_STATE_FREEZE,
> +					      SUSPEND_TEST_NONE);
> +		break;
> +
>  	case SUSPEND_DEVICES:
>  		igt_system_suspend_autoresume(SUSPEND_STATE_MEM,
>  					      SUSPEND_TEST_DEVICES);
> @@ -255,6 +261,8 @@ igt_main
>  
>  	igt_subtest("basic")
>  		run_test(fd, ALL_ENGINES, NOSLEEP);
> +	igt_subtest("basic-S0")
> +		run_test(fd, ALL_ENGINES, IDLE);
>  	igt_subtest("basic-S3-devices")
>  		run_test(fd, ALL_ENGINES, SUSPEND_DEVICES);
>  	igt_subtest("basic-S3")
> diff --git a/tests/intel-ci/fast-feedback.testlist b/tests/intel-ci/fast-feedback.testlist
> index e78e7fd0c..2553a68c3 100644
> --- a/tests/intel-ci/fast-feedback.testlist
> +++ b/tests/intel-ci/fast-feedback.testlist
> @@ -56,6 +56,7 @@ igt@gem_exec_reloc@basic-write-read-active
>  igt@gem_exec_reloc@basic-softpin
>  igt@gem_exec_store@basic-all
>  igt@gem_exec_suspend@basic
> +igt@gem_exec_suspend@basic-s0
>  igt@gem_exec_suspend@basic-s3
>  igt@gem_exec_suspend@basic-s4-devices
>  igt@gem_flink_basic@bad-flink
> -- 
> 2.23.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] 3+ messages in thread

end of thread, other threads:[~2019-10-25 19:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-10-07 11:06 [PATCH i-g-t] i915/gem_exec_suspend: Exercise S0 (aka s2idle) Chris Wilson
2019-10-25 19:16 ` [igt-dev] " Mika Kuoppala
2019-10-25 19:16   ` [Intel-gfx] " Mika Kuoppala

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