[Intel-gfx] [CI 5/5] igt/gem_workarounds: Add hibernation coverage
Chris Wilson
chris at chris-wilson.co.uk
Tue Oct 3 13:40:45 UTC 2017
Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
---
tests/gem_workarounds.c | 16 +++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)
diff --git a/tests/gem_workarounds.c b/tests/gem_workarounds.c
index 74bb11d2..dc39a76b 100644
--- a/tests/gem_workarounds.c
+++ b/tests/gem_workarounds.c
@@ -34,6 +34,7 @@ static int gen;
enum operation {
GPU_RESET,
SUSPEND_RESUME,
+ HIBERNATE_RESUME,
SIMPLE_READ,
};
@@ -61,12 +62,6 @@ static struct write_only_list {
static struct intel_wa_reg *wa_regs;
static int num_wa_regs;
-static void test_suspend_resume(void)
-{
- igt_info("Suspending the device ...\n");
- igt_system_suspend_autoresume(SUSPEND_STATE_MEM, SUSPEND_TEST_NONE);
-}
-
static bool write_only(const uint32_t addr)
{
int i;
@@ -194,7 +189,13 @@ static void check_workarounds(int fd, enum operation op, unsigned int flags)
break;
case SUSPEND_RESUME:
- test_suspend_resume();
+ igt_system_suspend_autoresume(SUSPEND_STATE_MEM,
+ SUSPEND_TEST_NONE);
+ break;
+
+ case HIBERNATE_RESUME:
+ igt_system_suspend_autoresume(SUSPEND_STATE_DISK,
+ SUSPEND_TEST_NONE);
break;
case SIMPLE_READ:
@@ -222,6 +223,7 @@ igt_main
{ "basic-read", SIMPLE_READ },
{ "reset", GPU_RESET },
{ "suspend-resume", SUSPEND_RESUME },
+ { "hibernate-resume", HIBERNATE_RESUME },
{ }
}, *op;
const struct {
--
2.14.2
More information about the Intel-gfx
mailing list