From 5533f22c354af2efd137a2f711d2e1ec86d70cb2 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Wed, 2 Mar 2016 13:57:35 +0000 Subject: [PATCH] lib: Show the command that fails when suspending Include the system("") in the debug output for the assertion failure. Signed-off-by: Chris Wilson --- lib/igt_aux.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/igt_aux.c b/lib/igt_aux.c index 7d35666e..affde6e9 100644 --- a/lib/igt_aux.c +++ b/lib/igt_aux.c @@ -364,8 +364,6 @@ void igt_cleanup_aperture_trashers(void) */ void igt_system_suspend_autoresume(void) { - int ret; - /* FIXME: Simulation doesn't like suspend/resume, and not even a lighter * approach using /sys/power/pm_test to just test our driver's callbacks * seems to fare better. We need to investigate what's going on. */ @@ -374,8 +372,7 @@ void igt_system_suspend_autoresume(void) /* skip if system doesn't support suspend-to-mem */ igt_skip_on(system("rtcwake -n -s 30 -m mem") != 0); - ret = system("rtcwake -s 30 -m mem"); - igt_assert_f(ret == 0, + igt_assert_f(system("rtcwake -s 30 -m mem") == 0, "This failure means that something is wrong with the " "rtcwake tool or how your distro is set up. This is not " "a i915.ko or i-g-t bug.\n");