sxmo_suspend: rework time accounting to be more similar to upstream
This commit is contained in:
@@ -19,11 +19,11 @@ doas rtl8723cs-wowlan arp --dest-ip 10.78.79.54
|
|||||||
|
|
||||||
echo "calling suspend for duration: $suspend_time"
|
echo "calling suspend for duration: $suspend_time"
|
||||||
|
|
||||||
start=$(date "+%s")
|
start="$(date "+%s")"
|
||||||
rtcwake -m mem -s "$suspend_time" || exit 1
|
rtcwake -m mem -s "$suspend_time" || exit 1
|
||||||
end=$(date "+%s")
|
#We woke up again
|
||||||
duration=$(("$end" - "$start")
|
time_spent="$(( $(date "+%s") - start ))"
|
||||||
echo "suspended for $duration seconds"
|
echo "suspended for $time_spent seconds"
|
||||||
|
|
||||||
sxmo_hook_postwake.sh
|
sxmo_hook_postwake.sh
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user