diff options
author | Sylvain Pineau <sylvain.pineau@canonical.com> | 2019-08-28 12:31:43 +0200 |
---|---|---|
committer | Sylvain Pineau <sylvain.pineau@canonical.com> | 2019-08-28 12:31:43 +0200 |
commit | 56e3a161a616f3773edd6fe21ce439d1fac5935e (patch) | |
tree | 1109a4d9aac09c437ab6512248ec480b81fa54b5 | |
parent | 0393c6e9138844f635829f5695e04c4615f336b3 (diff) |
suspend_advanced_auto: fallback to rtcwake if fwts s3 is not supported
FWTS on arm does not provide the S3 tests. Supported tests: bmc_info, clog, cpu_info, cpufreq, dt_base, dt_sysinfo, klog, maxreadreq, mem_info, mtd_info, olog, oops, power_mgmt, prd_info, reserv_mem, version.
-rw-r--r-- | units/suspend/suspend.pxu | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/units/suspend/suspend.pxu b/units/suspend/suspend.pxu index 0c3a942..35ba417 100644 --- a/units/suspend/suspend.pxu +++ b/units/suspend/suspend.pxu @@ -268,7 +268,14 @@ command: if [[ -v SNAP ]]; then export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$SNAP/usr/lib/fwts" fi - set -o pipefail; checkbox-support-fwts_test -f none -l $PLAINBOX_SESSION_SHARE/suspend_single -s s3 --s3-sleep-delay=30 --s3-device-check --s3-device-check-delay=45 | tee $PLAINBOX_SESSION_SHARE/suspend_single_times.log + # fwts s3 is not available on all architectures (i.e ARM) + if fwts --show-tests-categories | grep -q 's3 '; then + echo "Calling fwts" + set -o pipefail; checkbox-support-fwts_test -f none -l $PLAINBOX_SESSION_SHARE/suspend_single -s s3 --s3-sleep-delay=30 --s3-device-check --s3-device-check-delay=45 | tee $PLAINBOX_SESSION_SHARE/suspend_single_times.log + else + echo "Calling rtcwake" + rtcwake -m mem -s 30 + fi estimated_duration: 90.000 unit: template |