recover_duts: Increase amount of ping retries before rebooting

I am trying to implement a suspend stress test that runs
suspend/resume cycles in a very tight loop. As most network adapters
used in the lab are USB-based and therefore need reenumeration after
resume, this means that the device often looses its network connection
for several cycles or regains it just for a few seconds. As recover_duts
currently assumes a very stable network connection, my test often fails
from sudden reboots on an otherwise healthy device.

This test improves recover_duts' network detection mechanism by making
really, *really* sure it is down for good over about a minute before it
tries any recovery attempts. This should not really prevent its main
purpose of recovering wedged devices, but will significantly improve the
stability of tests that deteriorate network availability.

BUG=chromium-os:35901
TEST=Run power_SuspendStress/control.bareDaily on a lab device with this
patch, rejoice as it survives the whole run (autotest may still loose
its connection, though, that's a different problem I need to work on).

Change-Id: Ibe7e5cad9805f84fabdc863cbf456fad62c89470
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/42046
Reviewed-by: Chris Sosa <sosa@chromium.org>
1 file changed