summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorImre Deak <imre.deak@intel.com>2014-05-13 15:49:58 +0300
committerImre Deak <imre.deak@intel.com>2014-05-13 16:26:26 +0300
commit351e7d395041b4b87ad28a201c81acac40cb397f (patch)
treed7a26f99d56a5ce2f558f9edf01332d29f10be5c /tests
parent4e4ff4c1d1189f2dab59af1f1e868d88ab13624a (diff)
pm_pc8: add system-suspend subtest
Signed-off-by: Imre Deak <imre.deak@intel.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/pm_pc8.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/pm_pc8.c b/tests/pm_pc8.c
index 5a3ebc1d..649d427b 100644
--- a/tests/pm_pc8.c
+++ b/tests/pm_pc8.c
@@ -47,6 +47,7 @@
#include "intel_io.h"
#include "intel_chipset.h"
#include "ioctl_wrappers.h"
+#include "igt_aux.h"
#include "igt_kms.h"
#include "igt_debugfs.h"
@@ -1472,6 +1473,14 @@ static void stay_subtest(void)
sleep(600);
}
+static void system_suspend_subtest(void)
+{
+ disable_all_screens(&ms_data);
+ igt_assert(wait_for_suspended());
+ igt_system_suspend_autoresume();
+ igt_assert(wait_for_suspended());
+}
+
int main(int argc, char *argv[])
{
int rounds = 50;
@@ -1560,6 +1569,10 @@ int main(int argc, char *argv[])
modeset_subtest(SCREEN_TYPE_ANY, rounds,
WAIT_STATUS | WAIT_EXTRA);
+ /* System suspend */
+ igt_subtest("system-suspend")
+ system_suspend_subtest();
+
/* GEM stress */
igt_subtest("gem-execbuf-stress")
gem_execbuf_stress_subtest(rounds, WAIT_STATUS);