diff options
author | Loys Ollivier <lollivier@baylibre.com> | 2017-12-11 11:33:22 +0100 |
---|---|---|
committer | Loys Ollivier <lollivier@baylibre.com> | 2017-12-11 11:33:22 +0100 |
commit | a9fcea01daf49de7099a85691eb4e9fc3b091b7e (patch) | |
tree | 44dfb60125daba87384711d02f02273989b2ac20 | |
parent | 1d1a61d43745afa2e7422de8122b3dfa63977624 (diff) |
jjb/common: clean up device names to standardized ones.
Use the device_name table aliases earlier in the CI process. That way
all the scripts are using the correct device name. Avoiding name
mismatch resulting to CI failure.
Change-Id: Ia6f9f8beb06c43a24605abb24e676eaed68cc67e
Signed-off-by: Loys Ollivier <lollivier@baylibre.com>
-rw-r--r-- | jjb/common/include-agl-lava-labs-prepare.sh | 20 | ||||
-rw-r--r-- | jjb/common/include-agl-run-test-prepare.sh | 19 | ||||
-rw-r--r-- | jjb/common/include-agl-run-test-short-release.sh | 4 | ||||
-rw-r--r-- | jjb/common/include-agl-run-test-short.sh | 4 |
4 files changed, 20 insertions, 27 deletions
diff --git a/jjb/common/include-agl-lava-labs-prepare.sh b/jjb/common/include-agl-lava-labs-prepare.sh index 938dcbe6..56cdaeab 100644 --- a/jjb/common/include-agl-lava-labs-prepare.sh +++ b/jjb/common/include-agl-lava-labs-prepare.sh @@ -17,9 +17,6 @@ labs=( # [baylibre_seattle]="http://lava.ished.com/;$LAB_BAYLIBRE_SEATTLE_USER;$LAB_BAYLIBRE_SEATTLE_TOKEN" ) -echo "## ${MACHINE} ##" -__MACHINE=${MACHINE%-nogfx} - # # Ensure python_keyring is set to plaintext. Required for # non-interactive use @@ -31,23 +28,6 @@ cat <<EOF > ~/.local/share/python_keyring/keyringrc.cfg default-keyring=keyring.backends.file.PlaintextKeyring EOF -declare -A agl_lava_releng_aliases -agl_lava_releng_aliases=( - [raspberrypi3]="raspberrypi3-uboot;raspberrypi3" - [qemux86-64]="qemu;qemux86-64" - [m3ulcb-nogfx]="r8a7796-m3ulcb;m3ulcb" - [porter-nogfx]="renesas-porter;renesas-porter" - [dra7xx-evm]="dra7-evm;dra7xx-evm" -) - -OFS=${IFS} -IFS=';' -arr=(${agl_lava_releng_aliases[$MACHINE]}) -IFS=${OFS} -lava_device=${arr[0]} -releng_device=${arr[1]} -# And agl_device=${MACHINE} - device_available=0 for lab in "${!labs[@]}"; do val=${labs[$lab]} diff --git a/jjb/common/include-agl-run-test-prepare.sh b/jjb/common/include-agl-run-test-prepare.sh index 2c6611d9..20456175 100644 --- a/jjb/common/include-agl-run-test-prepare.sh +++ b/jjb/common/include-agl-run-test-prepare.sh @@ -24,8 +24,25 @@ if [ -e releng-scripts/utils ]; then RELENG=$PWD/releng-scripts fi +declare -A agl_lava_releng_aliases +agl_lava_releng_aliases=( + [raspberrypi3]="raspberrypi3-uboot;raspberrypi3" + [qemux86-64]="qemu;qemux86-64" + [m3ulcb-nogfx]="r8a7796-m3ulcb;m3ulcb" + [porter-nogfx]="renesas-porter;renesas-porter" + [dra7xx-evm]="dra7-evm;dra7xx-evm" +) + +OFS=${IFS} +IFS=';' +arr=(${agl_lava_releng_aliases[$MACHINE]}) +IFS=${OFS} +lava_device=${arr[0]} +releng_device=${arr[1]} +# And agl_device=${MACHINE} + CREATE_ARGS="" -CREATE_ARGS+="--machine ${MACHINE} " +CREATE_ARGS+="--machine ${releng_device} " # If it's a release build if [[ $RELEASE_BRANCH ]] && [[ $RELEASE_VERSION ]]; then diff --git a/jjb/common/include-agl-run-test-short-release.sh b/jjb/common/include-agl-run-test-short-release.sh index 13a122e7..89992f85 100644 --- a/jjb/common/include-agl-run-test-short-release.sh +++ b/jjb/common/include-agl-run-test-short-release.sh @@ -7,10 +7,8 @@ set -x -echo "## ${MACHINE} ##" cd $REPODIR -__MACHINE=${MACHINE%-nogfx} # releng doesn't care echo "# LAVA lab target: ${LAVA_LAB} #" # releng-scripts depends on jinja2 >= 2.9 echo "## Check version of python-jinja2: " @@ -29,7 +27,7 @@ CREATE_ARGS+="--test all" $RELENG/utils/create-jobs.py ${CREATE_ARGS} > testjob.yaml if [ $? != 0 ]; then - echo "ERROR: Machine ${$__MACHINE}: LAVA job creation failed." + echo "ERROR: Machine ${releng_device}: LAVA job creation failed." exit 0 else cat testjob.yaml diff --git a/jjb/common/include-agl-run-test-short.sh b/jjb/common/include-agl-run-test-short.sh index f4fbd5b7..955d67d8 100644 --- a/jjb/common/include-agl-run-test-short.sh +++ b/jjb/common/include-agl-run-test-short.sh @@ -7,10 +7,8 @@ set -x -echo "## ${MACHINE} ##" cd $REPODIR -__MACHINE=${MACHINE%-nogfx} # releng doesn't care echo "# LAVA lab target: ${LAVA_LAB} #" # releng-scripts depends on jinja2 >= 2.9 echo "## Check version of python-jinja2: " @@ -29,7 +27,7 @@ CREATE_ARGS+="--test all" $RELENG/utils/create-jobs.py ${CREATE_ARGS} > testjob.yaml if [ $? != 0 ]; then - echo "ERROR: Machine ${$__MACHINE}: LAVA job creation failed." + echo "ERROR: Machine ${releng_device}: LAVA job creation failed." exit 0 else cat testjob.yaml |