several changes on fvp yaml generation

The CR-01, starting at [1], has been fully tested and it uncovered
several issues on the fvp yaml generation code section which this
commit addresses.

[1] https://review.trustedfirmware.org/c/ci/tf-a-job-configs/+/6217

Signed-off-by: Leonardo Sandoval <leonardo.sandoval@linaro.org>
Change-Id: I46af7eeeee7cff8434bfb417527e8e8c32a09ab9
diff --git a/fvp_utils.sh b/fvp_utils.sh
index 719d0d8..1e31c0b 100644
--- a/fvp_utils.sh
+++ b/fvp_utils.sh
@@ -270,9 +270,10 @@
     image="$(fvp_gen_bin_url kernel.bin)"
     ramdisk="$(fvp_gen_bin_url initrd.bin)"
 
-    # tftf's ns_bl[1|2]u.bin artefacts
+    # tftf's ns_bl[1|2]u.bin and el3_payload artefacts
     ns_bl1u="$(fvp_gen_bin_url ns_bl1u.bin)"
     ns_bl2u="$(fvp_gen_bin_url ns_bl2u.bin)"
+    el3_payload="$(fvp_gen_bin_url el3_payload.bin)"
 
     docker_registry="${docker_registry:-}"
     docker_registry="$(docker_registry_append)"
@@ -290,6 +291,7 @@
         -e "s|\${ACTIONS_DEPLOY_IMAGES_RAMDISK}|${ramdisk}|" \
         -e "s|\${ACTIONS_DEPLOY_IMAGES_NS_BL1U}|${ns_bl1u}|" \
         -e "s|\${ACTIONS_DEPLOY_IMAGES_NS_BL2U}|${ns_bl2u}|" \
+        -e "s|\${ACTIONS_DEPLOY_IMAGES_EL3_PAYLOAD}|${el3_payload}|" \
         -e "s|\${BOOT_DOCKER_NAME}|${docker_name}|" \
         -e "s|\${BOOT_IMAGE_DIR}|${model_dir}|" \
         -e "s|\${BOOT_IMAGE_BIN}|${model_bin}|" \
@@ -300,6 +302,9 @@
     # LAVA expects 'macro' names for binaries, so replace them
     sed -e "s|bl1.bin|{BL1}|" \
 	-e "s|fip.bin|{FIP}|" \
+	-e "s|ns_bl1u.bin|{NS_BL1U}|" \
+	-e "s|ns_bl2u.bin|{NS_BL2U}|" \
+	-e "s|el3_payload.bin|{EL3_PAYLOAD}|" \
 	-e "s|kernel.bin|{IMAGE}|" \
 	-e "s|initrd.bin|{RAMDISK}|" \
 	< "$archive/model_params" \
diff --git a/script/gen_fvp_linux_yaml.sh b/script/gen_fvp_linux_yaml.sh
index fc35bca..22069b1 100755
--- a/script/gen_fvp_linux_yaml.sh
+++ b/script/gen_fvp_linux_yaml.sh
@@ -11,7 +11,7 @@
 
 cat <<EOF
 device_type: fvp
-job_name: tf-fvp
+job_name: fvp-linux
 
 timeouts:
   connection:
@@ -54,9 +54,9 @@
       local: true
     image: \${BOOT_IMAGE_DIR}/\${BOOT_IMAGE_BIN}
     version_string: \${BOOT_VERSION_STRING}
-    timeout:
-      minutes: 7
     console_string: 'terminal_0: Listening for serial connection on port (?P<PORT>\d+)'
+    timeout:
+      minutes: 30
     arguments:
 \${BOOT_ARGUMENTS}
     prompts:
diff --git a/script/gen_fvp_tftf_yaml.sh b/script/gen_fvp_tftf_yaml.sh
index ff897da..ddf46f3 100755
--- a/script/gen_fvp_tftf_yaml.sh
+++ b/script/gen_fvp_tftf_yaml.sh
@@ -11,7 +11,7 @@
 
 cat <<EOF
 device_type: fvp
-job_name: tf-fvp
+job_name: fvp-tftf
 
 timeouts:
   connection:
@@ -43,6 +43,8 @@
         url: \${ACTIONS_DEPLOY_IMAGES_NS_BL1U}
       ns_bl2u:
         url: \${ACTIONS_DEPLOY_IMAGES_NS_BL2U}
+      el3_payload:
+        url: \${ACTIONS_DEPLOY_IMAGES_EL3_PAYLOAD}
 
 - boot:
     method: fvp
@@ -52,6 +54,14 @@
       local: true
     image: \${BOOT_IMAGE_DIR}/\${BOOT_IMAGE_BIN}
     version_string: \${BOOT_VERSION_STRING}
+    console_string: 'terminal_0: Listening for serial connection on port (?P<PORT>\d+)'
+    timeout:
+      minutes: 30
+
+    arguments:
+\${BOOT_ARGUMENTS}
+
+- test:
     timeout:
       minutes: 30
 
@@ -73,7 +83,4 @@
         Crashed: fail
         Skipped: skip
 
-    arguments:
-\${BOOT_ARGUMENTS}
-
 EOF