diff options
author | Khouloud Touil <ktouil@baylibre.com> | 2019-05-09 10:08:07 +0200 |
---|---|---|
committer | Khouloud Touil <ktouil@baylibre.com> | 2019-05-09 10:08:07 +0200 |
commit | 792d809796c7619aab642ba171b377e9a43cf235 (patch) | |
tree | 30217b28f3f1e3b541fa4c1dcac16ad2cea28d38 /jjb | |
parent | 05b8d0ff99a4e7e2b9aa2b5f78a61b31cca6fabc (diff) |
Avoid an extra 1min wait for the Idle,Good board
As we have to wait 60s for each retry, this patch avoid to keep the
Idle,Good boards waitong an extra 60s.
Change-Id: I34dd47362da5e2de14103cc374c9b6f4cd830aa7
Signed-off-by: Khouloud Touil <ktouil@baylibre.com>
Diffstat (limited to 'jjb')
-rw-r--r-- | jjb/common/include-agl-lava-labs-prepare.sh | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/jjb/common/include-agl-lava-labs-prepare.sh b/jjb/common/include-agl-lava-labs-prepare.sh index ab60a739..bfa213c4 100644 --- a/jjb/common/include-agl-lava-labs-prepare.sh +++ b/jjb/common/include-agl-lava-labs-prepare.sh @@ -103,14 +103,13 @@ for lab in "${!labs[@]}"; do for i in `seq 1 $retries` do # device is only available if "idle" or "running" - sleep 60s # Look if the status of the board has changed from reserved in the lab echo -n "Checking for $lava_device at $full_url... " lavacli_line=$(lavacli -i $lab devices list | grep $lava_device | grep Good | head -1) lavacli_line=$(echo "$lavacli_line" | tr -d '[:space:]') if [ -z "$lavacli_line" ]; then echo "not found." - continue + break fi IFS=':' arr=($lavacli_line) @@ -119,15 +118,14 @@ for lab in "${!labs[@]}"; do if [ x"$device_status" = x"Reserved,Good" ]; then echo "Device still reserved, retries left: $retries ." - continue elif [ x"$device_status" = x"Idle,Good" ]; then # IDLE AND GOOD means we can grab it device_available=1 break elif [ x"$device_status" = x"Running,Good" ]; then echo "Device still running (other job), retries left: $retries ." - continue fi + sleep 60s done if [ $device_available = 0 ]; then |