fix: swap LAVA YAML template generation for broken jobs

This change introduces two new hooks:

- `generate_lava_job_template` is expected to generate the initial LAVA
  job YAML file (`job.yaml`), which may include fields which are not
  yet known
- `generate_lava_job` is used to fill in anything in the LAVA job that
  was not known when the job YAML file was generated

Previously, these were incorporated into other hooks almost
arbitrarily, and in some jobs this meant that they were invoked in the
wrong order. These new hooks allow us to be explicit about the order
that these operations occur.

Change-Id: I07f96b91a7ddb04b599ccca674797d4714296c21
Signed-off-by: Chris Kay <chris.kay@arm.com>
diff --git a/run_config/fvp-aem8a.singlecluster b/run_config/fvp-aem8a.singlecluster
index c7d676f..e7e934f 100755
--- a/run_config/fvp-aem8a.singlecluster
+++ b/run_config/fvp-aem8a.singlecluster
@@ -1,19 +1,19 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-        model="$model" \
-	cluster_0_num_cores="4" \
-	cluster_1_num_cores="0" \
-	cluster_2_num_cores="0" \
-	cluster_3_num_cores="0" \
-	gen_model_params
+	model="$model" \
+		cluster_0_num_cores="4" \
+		cluster_1_num_cores="0" \
+		cluster_2_num_cores="0" \
+		cluster_3_num_cores="0" \
+		gen_model_params
 
-        model="$model" gen_fvp_yaml
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a b/run_config/fvp-aemv8a
index 848171d..ed45616 100644
--- a/run_config/fvp-aemv8a
+++ b/run_config/fvp-aemv8a
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-        model="$model" gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a"
 
-        model="$model" gen_fvp_yaml
+	model="$model" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.64only b/run_config/fvp-aemv8a.64only
index e51d751..4e694d5 100644
--- a/run_config/fvp-aemv8a.64only
+++ b/run_config/fvp-aemv8a.64only
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-	aarch64_only=1 model="$model" gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a"
 
-        model="$model" gen_fvp_yaml
+	model="$model" aarch64_only="1" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.8_3 b/run_config/fvp-aemv8a.8_3
index 56a5cef..d29cf11 100644
--- a/run_config/fvp-aemv8a.8_3
+++ b/run_config/fvp-aemv8a.8_3
@@ -1,14 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a"
-	model="$model"  arch_version="8.3" \
-		gen_model_params
 
+	model="$model" arch_version="8.3" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.8_4 b/run_config/fvp-aemv8a.8_4
index d5068e3..fecd5a6 100644
--- a/run_config/fvp-aemv8a.8_4
+++ b/run_config/fvp-aemv8a.8_4
@@ -1,14 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a"
-	model="$model" arch_version="8.4" \
-		gen_model_params
 
-        model="$model" gen_fvp_yaml
+	model="$model" arch_version="8.4" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.8_5 b/run_config/fvp-aemv8a.8_5
index 68952e5..4669192 100644
--- a/run_config/fvp-aemv8a.8_5
+++ b/run_config/fvp-aemv8a.8_5
@@ -1,15 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a"
-        model="$model" \
-	arch_version="8.5" \
-		gen_model_params
 
-        model="$model" gen_fvp_yaml
+	model="$model" arch_version="8.5" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.8_5+bti b/run_config/fvp-aemv8a.8_5+bti
index 57efcad..0a38bd4 100644
--- a/run_config/fvp-aemv8a.8_5+bti
+++ b/run_config/fvp-aemv8a.8_5+bti
@@ -1,17 +1,17 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020 Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-	model="base-aemv8a" \
-	arch_version="8.5" \
-	has_branch_target_exception="1" \
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	model="$model" \
+		arch_version="8.5" \
+		has_branch_target_exception="1" \
 		gen_model_params
 
-	model="base-aemv8a" \
-	model_bin="FVP_Base_RevC-2xAEMvA" \
-	       gen_fvp_yaml
+	model="$model" model_bin="FVP_Base_RevC-2xAEMvA" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.8_5+mte b/run_config/fvp-aemv8a.8_5+mte
index 4317682..413f248 100644
--- a/run_config/fvp-aemv8a.8_5+mte
+++ b/run_config/fvp-aemv8a.8_5+mte
@@ -1,17 +1,17 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-        model="$model" \
-	arch_version="8.5" \
-	memory_tagging_support_level="3" \
+	model="$model" \
+		arch_version="8.5" \
+		memory_tagging_support_level="3" \
 		gen_model_params
 
-        model="$model" gen_fvp_yaml
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.8_5.bmcov b/run_config/fvp-aemv8a.8_5.bmcov
index a53c91a..4bdf969 100644
--- a/run_config/fvp-aemv8a.8_5.bmcov
+++ b/run_config/fvp-aemv8a.8_5.bmcov
@@ -1,16 +1,18 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a"
-	bmcov_plugin=1 bmcov_plugin_path="${coverage_trace_plugin}" \
-        model="$model" \
-	arch_version="8.5" \
+
+	model="$model" \
+		arch_version="8.5" \
+		bmcov_plugin_path="${coverage_trace_plugin}" \
+		bmcov_plugin="1" \
 		gen_model_params
 
-        model="$model" gen_fvp_yaml
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.8_6 b/run_config/fvp-aemv8a.8_6
index d610f02..38ace12 100644
--- a/run_config/fvp-aemv8a.8_6
+++ b/run_config/fvp-aemv8a.8_6
@@ -1,16 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020 Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-	model="base-aemv8a" \
-	arch_version="8.6" \
-		gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	model="base-aemv8a" \
-	model_bin="FVP_Base_RevC-2xAEMvA" \
-	       gen_fvp_yaml
+	model="$model" arch_version="8.6" gen_model_params
+	model="$model" model_bin="FVP_Base_RevC-2xAEMvA" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.8_7 b/run_config/fvp-aemv8a.8_7
index 1028042..5a8ebdc 100644
--- a/run_config/fvp-aemv8a.8_7
+++ b/run_config/fvp-aemv8a.8_7
@@ -1,14 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2022 Arm Limited. All rights reserved.
+# Copyright (c) 2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a"
-	model="$model"  arch_version="8.7" \
-		gen_model_params
 
+	model="$model" arch_version="8.7" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.NVM_reboot b/run_config/fvp-aemv8a.NVM_reboot
index 21862d3..7d8ca77 100644
--- a/run_config/fvp-aemv8a.NVM_reboot
+++ b/run_config/fvp-aemv8a.NVM_reboot
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -11,28 +11,31 @@
 	rm -f "$archive/flash1"
 	touch "$archive/flash0"
 	touch "$archive/flash1"
+}
+
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	model="$model" \
+		cache_state_modelled="0" \
+		cluster_0_num_cores="1" \
+		cluster_1_num_cores="1" \
+		flashloader0_fwrite="flash0" \
+		flashloader1_fwrite="flash1" \
+		retain_flash="1" \
+		secure_memory="0" \
+		uart0_out="$uart0_log" \
+		uart1_out="$uart1_log" \
+		gen_model_params
+
+	model="$model" gen_fvp_yaml
+
+	uart0_log=$(echo uart-0-$(date "+%H:%M:%S").log)
+	uart1_log=$(echo uart-1-$(date "+%H:%M:%S").log)
+	set_run_env "uart0_file" "$uart0_log"
+	set_run_env "uart1_file" "$uart1_log"
 
 	set_run_env "run_tftf_reboot_tests" "1"
 	# Contents of Non Volatile Memory are written to this file
 	set_run_env "NVM_file" "flash0"
 }
-
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-
-	uart0_log=$(echo uart-0-`date "+%H:%M:%S"`.log)
-	uart1_log=$(echo uart-1-`date "+%H:%M:%S"`.log)
-	set_run_env "uart0_file" "$uart0_log"
-	set_run_env "uart1_file" "$uart1_log"
-
-	model="$model" retain_flash="1" secure_memory="0" \
-	cluster_0_num_cores="1" cluster_1_num_cores="1" \
-	cache_state_modelled="0" \
-	uart0_out="$uart0_log" \
-	uart1_out="$uart1_log" \
-	flashloader0_fwrite="flash0" \
-	flashloader1_fwrite="flash1" \
-		gen_model_params
-
-	model="$model" gen_fvp_yaml
-}
diff --git a/run_config/fvp-aemv8a.aarch32 b/run_config/fvp-aemv8a.aarch32
index 3ec8ae3..ddb63f8 100644
--- a/run_config/fvp-aemv8a.aarch32
+++ b/run_config/fvp-aemv8a.aarch32
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a"
-	aarch32="1" model="$model" gen_model_params
 
+	model="$model" aarch32="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.aarch32+8_4 b/run_config/fvp-aemv8a.aarch32+8_4
index 16906ec..de3fbe4 100644
--- a/run_config/fvp-aemv8a.aarch32+8_4
+++ b/run_config/fvp-aemv8a.aarch32+8_4
@@ -1,14 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020, Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-	aarch32="1" model="$model" arch_version="8.4" \
-		gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a"
 
-        model="$model" gen_fvp_yaml
+	model="$model" aarch32="1" arch_version="8.4" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.aarch32+bl2_el3 b/run_config/fvp-aemv8a.aarch32+bl2_el3
index 648b107..db91b69 100644
--- a/run_config/fvp-aemv8a.aarch32+bl2_el3
+++ b/run_config/fvp-aemv8a.aarch32+bl2_el3
@@ -1,18 +1,20 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020, Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-	bl2_at_el3="1" \
-	aarch32="1" \
-	bl2_addr="0x4022000" \
-		model="$model" gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a"
 
 	uart="0" set_expect_variable "skip_early_boot_msgs" "1"
 
+	model="$model" \
+		aarch32="1" \
+		bl2_addr="0x4022000" \
+		bl2_at_el3="1" \
+		gen_model_params
+
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.aarch32+memprotect b/run_config/fvp-aemv8a.aarch32+memprotect
index dbb819d..c0b13b1 100644
--- a/run_config/fvp-aemv8a.aarch32+memprotect
+++ b/run_config/fvp-aemv8a.aarch32+memprotect
@@ -1,22 +1,23 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020, Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
 	image=${archive}/tmp.bin
-	printf '\1\0\0\0' > "$image"
+	printf '\1\0\0\0' >"$image"
 
-	aarch32="1" \
-	reset_to_spmin="1" \
-	cache_state_modelled="0" \
-	memprotect="$image" \
-	memprotect_addr="0xBFC0000" \
-		model="$model" gen_model_params
+	model="$model" \
+		aarch32="1" \
+		cache_state_modelled="0" \
+		memprotect_addr="0xBFC0000" \
+		memprotect="$image" \
+		reset_to_spmin="1" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.aarch32+regreset b/run_config/fvp-aemv8a.aarch32+regreset
index 9be69e4..a7422c1 100644
--- a/run_config/fvp-aemv8a.aarch32+regreset
+++ b/run_config/fvp-aemv8a.aarch32+regreset
@@ -1,17 +1,18 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020, Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	cluster_0_reg_reset="0xffffffff" \
+	model="$model" \
+		aarch32="1" \
+		cluster_0_reg_reset="0xffffffff" \
 		cluster_1_reg_reset="0xffffffff" \
-		aarch32=1 \
-		model="$model" gen_model_params
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.aarch32.8_3 b/run_config/fvp-aemv8a.aarch32.8_3
index 55ec12c..5531659 100644
--- a/run_config/fvp-aemv8a.aarch32.8_3
+++ b/run_config/fvp-aemv8a.aarch32.8_3
@@ -1,16 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a"
-        model="$model" \
-	arch_version="8.3" \
-	aarch32="1" \
-	gen_model_params
 
-        model="$model" gen_fvp_yaml
+	model="$model" aarch32="1" arch_version="8.3" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.aarch32.8_6 b/run_config/fvp-aemv8a.aarch32.8_6
index 9fef38a..2a9008e 100644
--- a/run_config/fvp-aemv8a.aarch32.8_6
+++ b/run_config/fvp-aemv8a.aarch32.8_6
@@ -1,17 +1,11 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020 Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-	model="base-aemv8a" \
-	arch_version="8.6" \
-	aarch32="1" \
-	gen_model_params
-
-	model="base-aemv8a" \
-	model_bin="FVP_Base_RevC-2xAEMvA" \
-	       gen_fvp_yaml
+generate_lava_job() {
+	model="base-aemv8a" aarch32="1" arch_version="8.6" gen_model_params
+	model="base-aemv8a" model_bin="FVP_Base_RevC-2xAEMvA" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.aarch32.NVM_reboot b/run_config/fvp-aemv8a.aarch32.NVM_reboot
index 319fdaa..3303bc6 100644
--- a/run_config/fvp-aemv8a.aarch32.NVM_reboot
+++ b/run_config/fvp-aemv8a.aarch32.NVM_reboot
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -11,28 +11,31 @@
 	rm -f "$archive/flash1"
 	touch "$archive/flash0"
 	touch "$archive/flash1"
+}
+
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	model="$model" \
+		aarch32="1" \
+		cluster_0_num_cores="1" \
+		cluster_1_num_cores="1" \
+		flashloader0_fwrite="flash0" \
+		flashloader1_fwrite="flash1" \
+		retain_flash="1" \
+		secure_memory="0" \
+		uart0_out="$uart0_log" \
+		uart1_out="$uart1_log" \
+		gen_model_params
+
+	model="$model" gen_fvp_yaml
+
+	uart0_log=$(echo uart-0-$(date "+%H:%M:%S").log)
+	uart1_log=$(echo uart-1-$(date "+%H:%M:%S").log)
+	set_run_env "uart0_file" "$uart0_log"
+	set_run_env "uart1_file" "$uart1_log"
 
 	set_run_env "run_tftf_reboot_tests" "1"
 	# Contents of Non Volatile Memory are written to this file
 	set_run_env "NVM_file" "flash0"
 }
-
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-
-	uart0_log=$(echo uart-0-`date "+%H:%M:%S"`.log)
-	uart1_log=$(echo uart-1-`date "+%H:%M:%S"`.log)
-	set_run_env "uart0_file" "$uart0_log"
-	set_run_env "uart1_file" "$uart1_log"
-
-	aarch32="1" model="$model" retain_flash="1" \
-	cluster_0_num_cores="1" cluster_1_num_cores="1" \
-	secure_memory="0" \
-	uart0_out="$uart0_log" \
-	uart1_out="$uart1_log" \
-	flashloader0_fwrite="flash0" \
-	flashloader1_fwrite="flash1" \
-		gen_model_params
-
-	model="$model" gen_fvp_yaml
-}
diff --git a/run_config/fvp-aemv8a.aarch32.gicv2 b/run_config/fvp-aemv8a.aarch32.gicv2
index ddddcab..71743cf 100644
--- a/run_config/fvp-aemv8a.aarch32.gicv2
+++ b/run_config/fvp-aemv8a.aarch32.gicv2
@@ -1,23 +1,29 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a"
 
-	model_version="0.0" \
-	model_build="6557" \
-	model_flavour="Linux64_GCC-6.4" \
-	mpidr_layout="0" \
-	supports_multi_threading="0" \
-	gicv3_gicv2_only="1" cache_state_modelled=0 model="$model" aarch32="1" gen_model_params
+	model="$model" \
+		aarch32="1" \
+		cache_state_modelled="0" \
+		gicv3_gicv2_only="1" \
+		model_build="6557" \
+		model_flavour="Linux64_GCC-6.4" \
+		model_version="0.0" \
+		mpidr_layout="0" \
+		supports_multi_threading="0" \
+		gen_model_params
 
-	#ToDo: switch to aarch32.gicv2 based RevC model once it is available publicly
-	model_version="11.14" \
-	model_build="21" \
-	model_flavour="Linux64_GCC-6.4" \
-	model="base-aemv8a-revb" gen_fvp_yaml
+	# TODO: switch to aarch32.gicv2 based RevC model once it is available
+	# publicly
+	model="base-aemv8a-revb" \
+		model_build="21" \
+		model_flavour="Linux64_GCC-6.4" \
+		model_version="11.14" \
+		gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.aarch32.nocache b/run_config/fvp-aemv8a.aarch32.nocache
index 700b3fa..70af641 100644
--- a/run_config/fvp-aemv8a.aarch32.nocache
+++ b/run_config/fvp-aemv8a.aarch32.nocache
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-	cache_state_modelled="0" aarch32="1" model="$model" gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a"
 
+	model="$model" aarch32="1" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.aarch32.roxlattables.spmin_panic b/run_config/fvp-aemv8a.aarch32.roxlattables.spmin_panic
index 53339b9..73c0567 100644
--- a/run_config/fvp-aemv8a.aarch32.roxlattables.spmin_panic
+++ b/run_config/fvp-aemv8a.aarch32.roxlattables.spmin_panic
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -15,14 +15,12 @@
 	apply_tf_patch "readonly_xlat_tables/sp_min_data_abort_print_panic_message.patch"
 }
 
-post_tf_archive() {
-        local model="base-aemv8a"
-	aarch32="1" model="$model" gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	model="$model" gen_fvp_yaml
-}
-
-fetch_tf_resource() {
 	uart="0" timeout="60" file="timeout_spmin_roxlattables.exp" track_expect
 	uart="1" timeout="60" file="crash_panic.exp" track_expect
+
+	model="$model" aarch32="1" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.amu b/run_config/fvp-aemv8a.amu
index 9721f1d..5b93fe8 100644
--- a/run_config/fvp-aemv8a.amu
+++ b/run_config/fvp-aemv8a.amu
@@ -1,12 +1,17 @@
 #!/usr/bin/env bash
+#
+# Copyright (c) 2022, Arm Limited. All rights reserved.
+#
+# SPDX-License-Identifier: BSD-3-Clause
+#
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
 	model="$model" \
-	arch_version="8.4" \
-	amu_present="1" \
-	cache_state_modelled="0" \
+		amu_present="1" \
+		arch_version="8.4" \
+		cache_state_modelled="0" \
 		gen_model_params
 
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-aemv8a.amu.aarch32 b/run_config/fvp-aemv8a.amu.aarch32
index 3d024e0..83691d2 100644
--- a/run_config/fvp-aemv8a.amu.aarch32
+++ b/run_config/fvp-aemv8a.amu.aarch32
@@ -1,13 +1,18 @@
 #!/usr/bin/env bash
+#
+# Copyright (c) 2022, Arm Limited. All rights reserved.
+#
+# SPDX-License-Identifier: BSD-3-Clause
+#
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
 	model="$model" \
-	arch_version="8.4" \
-	amu_present="1" \
-	aarch32="1" \
-	cache_state_modelled="0" \
+		aarch32="1" \
+		amu_present="1" \
+		arch_version="8.4" \
+		cache_state_modelled="0" \
 		gen_model_params
 
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-aemv8a.amu.bmcov b/run_config/fvp-aemv8a.amu.bmcov
index 6bd7a88..3e93811 100644
--- a/run_config/fvp-aemv8a.amu.bmcov
+++ b/run_config/fvp-aemv8a.amu.bmcov
@@ -1,13 +1,19 @@
 #!/usr/bin/env bash
+#
+# Copyright (c) 2022, Arm Limited. All rights reserved.
+#
+# SPDX-License-Identifier: BSD-3-Clause
+#
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	bmcov_plugin=1 bmcov_plugin_path="${coverage_trace_plugin}" \
 	model="$model" \
-	arch_version="8.4" \
-	amu_present="1" \
-	cache_state_modelled="0" \
+		amu_present="1" \
+		arch_version="8.4" \
+		bmcov_plugin_path="${coverage_trace_plugin}" \
+		bmcov_plugin="1" \
+		cache_state_modelled="0" \
 		gen_model_params
 
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-aemv8a.arch_features b/run_config/fvp-aemv8a.arch_features
index d39dff0..9b12c15 100644
--- a/run_config/fvp-aemv8a.arch_features
+++ b/run_config/fvp-aemv8a.arch_features
@@ -1,19 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2022 Arm Limited. All rights reserved.
+# Copyright (c) 2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a"
 
-	model="$model" \
-	arch_version="8.7" \
-	has_brbe="1" \
-	has_trbe="1" \
-		gen_model_params
-
+	model="$model" arch_version="8.7" has_brbe="1" has_trbe="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
-
diff --git a/run_config/fvp-aemv8a.assymetric b/run_config/fvp-aemv8a.assymetric
index 6c2e9f4..a340551 100644
--- a/run_config/fvp-aemv8a.assymetric
+++ b/run_config/fvp-aemv8a.assymetric
@@ -1,22 +1,24 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	arch_version="8.3" \
-		cluster_0_reg_reset="0xffffffff" \
-		cluster_0_has_el2="0" \
-		cluster_1_reg_reset="0xffffffff" \
-		cluster_1_has_el2="0" \
-		cluster_0_num_cores="2" \
-		cluster_1_num_cores="3" \
-		model="$model" gen_model_params
 	uart="0" set_expect_variable "num_cpus" "5"
 
+	model="$model" \
+		arch_version="8.3" \
+		cluster_0_has_el2="0" \
+		cluster_0_num_cores="2" \
+		cluster_0_reg_reset="0xffffffff" \
+		cluster_1_has_el2="0" \
+		cluster_1_num_cores="3" \
+		cluster_1_reg_reset="0xffffffff" \
+		gen_model_params
+
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.assymetric.bmcov b/run_config/fvp-aemv8a.assymetric.bmcov
index 9352282..de6274e 100644
--- a/run_config/fvp-aemv8a.assymetric.bmcov
+++ b/run_config/fvp-aemv8a.assymetric.bmcov
@@ -1,23 +1,26 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	bmcov_plugin=1 bmcov_plugin_path="${coverage_trace_plugin}" \
-	arch_version="8.3" \
-		cluster_0_reg_reset="0xffffffff" \
-		cluster_0_has_el2="0" \
-		cluster_1_reg_reset="0xffffffff" \
-		cluster_1_has_el2="0" \
-		cluster_0_num_cores="2" \
-		cluster_1_num_cores="3" \
-		model="$model" gen_model_params
 	uart="0" set_expect_variable "num_cpus" "5"
 
+	model="$model" \
+		arch_version="8.3" \
+		bmcov_plugin_path="${coverage_trace_plugin}" \
+		bmcov_plugin="1" \
+		cluster_0_has_el2="0" \
+		cluster_0_num_cores="2" \
+		cluster_0_reg_reset="0xffffffff" \
+		cluster_1_has_el2="0" \
+		cluster_1_num_cores="3" \
+		cluster_1_reg_reset="0xffffffff" \
+		gen_model_params
+
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.bl2_el3 b/run_config/fvp-aemv8a.bl2_el3
index cb56174..57a803e 100644
--- a/run_config/fvp-aemv8a.bl2_el3
+++ b/run_config/fvp-aemv8a.bl2_el3
@@ -1,17 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-	bl2_at_el3="1" \
-	bl2_addr="0x4022000" \
-		model="$model" gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a"
 
 	uart="0" set_expect_variable "skip_early_boot_msgs" "1"
 
+	model="$model" bl2_addr="0x4022000" bl2_at_el3="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.bl2_el3+pie b/run_config/fvp-aemv8a.bl2_el3+pie
index ea43a65..58d88b4 100644
--- a/run_config/fvp-aemv8a.bl2_el3+pie
+++ b/run_config/fvp-aemv8a.bl2_el3+pie
@@ -1,17 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2022 Arm Limited. All rights reserved.
+# Copyright (c) 2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-        bl2_at_el3="1" \
-        bl2_addr="0x4023000" \
-                model="$model" gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a"
 
-        uart="0" set_expect_variable "skip_early_boot_msgs" "1"
+	uart="0" set_expect_variable "skip_early_boot_msgs" "1"
 
-        model="$model" gen_fvp_yaml
+	model="$model" bl2_addr="0x4023000" bl2_at_el3="1" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.bmcov b/run_config/fvp-aemv8a.bmcov
index 15ea0d8..3961923 100644
--- a/run_config/fvp-aemv8a.bmcov
+++ b/run_config/fvp-aemv8a.bmcov
@@ -1,15 +1,17 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	bmcov_plugin=1 bmcov_plugin_path="${coverage_trace_plugin}" \
-        model="$model" gen_model_params
+	model="$model" \
+		bmcov_plugin="1" \
+		bmcov_plugin_path="${coverage_trace_plugin}" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.crash b/run_config/fvp-aemv8a.crash
index 60dcc55..9568454 100644
--- a/run_config/fvp-aemv8a.crash
+++ b/run_config/fvp-aemv8a.crash
@@ -1,27 +1,22 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-
 pre_tf_build() {
-        # Apply fault injection patches
+	# Apply fault injection patches
 	apply_tf_patch "fault_inject/injected-fault-in-absence-of-ras.patch"
-        apply_tf_patch "fault_inject/explicit-events.patch"
+	apply_tf_patch "fault_inject/explicit-events.patch"
 }
 
-post_tf_archive() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	model="$model" fault_inject="1" arch_version="8.4" \
-		gen_model_params
+	uart="0" timeout="60" file="timeout_test.exp" track_expect
+	uart="1" timeout="60" file="crash_test.exp" track_expect
 
+	model="$model" arch_version="8.4" fault_inject="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
-
-fetch_tf_resource() {
-        uart="0"  timeout="60" file="timeout_test.exp" track_expect
-        uart="1"  timeout="60" file="crash_test.exp" track_expect
-}
diff --git a/run_config/fvp-aemv8a.el3payload b/run_config/fvp-aemv8a.el3payload
index c353092..b8af7ac 100644
--- a/run_config/fvp-aemv8a.el3payload
+++ b/run_config/fvp-aemv8a.el3payload
@@ -1,16 +1,17 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	pctl_startup="0.0.*.0,0.1.*.0" \
+	model="$model" \
+		pctl_startup="0.0.*.0,0.1.*.0" \
 		secure_ram_fill="1" \
-		model="$model" gen_model_params
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.fi b/run_config/fvp-aemv8a.fi
index eee8201..17059e8 100644
--- a/run_config/fvp-aemv8a.fi
+++ b/run_config/fvp-aemv8a.fi
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -12,11 +12,9 @@
 	apply_tf_patch "fault_inject/fvp-fault-handlers.patch"
 }
 
-post_tf_archive() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	model="$model" fault_inject="1" arch_version="8.4" \
-		gen_model_params
-
+	model="$model" arch_version="8.4" fault_inject="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.gicv3_spi b/run_config/fvp-aemv8a.gicv3_spi
index 4e693dd..60ab2f7 100644
--- a/run_config/fvp-aemv8a.gicv3_spi
+++ b/run_config/fvp-aemv8a.gicv3_spi
@@ -1,16 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	model="$model" \
-	gicv3_spi_count="988" \
-	gen_model_params
-
+	model="$model" gicv3_spi_count="988" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.gicv4 b/run_config/fvp-aemv8a.gicv4
index 1c54833..d7ce192 100644
--- a/run_config/fvp-aemv8a.gicv4
+++ b/run_config/fvp-aemv8a.gicv4
@@ -1,23 +1,23 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
 	model="$model" \
-	gicd_are_fixed_one="1" \
-	gicd_ext_ppi_count="64" \
-	gicd_ext_spi_count="1024" \
-	gicd_its_count="1" \
-	gicd_virtual_lpi="1" \
-	gicv3_ext_interrupt_range="1" \
-	gicv3_spi_count="988" \
-	has_gicv4_1="0" \
-	gen_model_params
+		gicd_are_fixed_one="1" \
+		gicd_ext_ppi_count="64" \
+		gicd_ext_spi_count="1024" \
+		gicd_its_count="1" \
+		gicd_virtual_lpi="1" \
+		gicv3_ext_interrupt_range="1" \
+		gicv3_spi_count="988" \
+		has_gicv4_1="0" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.gpt b/run_config/fvp-aemv8a.gpt
index 2aa7678..400537b 100644
--- a/run_config/fvp-aemv8a.gpt
+++ b/run_config/fvp-aemv8a.gpt
@@ -1,16 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-        fip_as_gpt="1" \
-        supports_crc32="1" \
-        model="$model" gen_model_params
-
-        model="$model" gen_fvp_yaml
+	model="$model" fip_as_gpt="1" supports_crc32="1" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.invalid_nvcounter b/run_config/fvp-aemv8a.invalid_nvcounter
index be925f8..1118994 100644
--- a/run_config/fvp-aemv8a.invalid_nvcounter
+++ b/run_config/fvp-aemv8a.invalid_nvcounter
@@ -1,17 +1,17 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
 	# The Trusted non-volatile counter is invalid. Authentication of BL2
 	# image is expected to fail.
 	uart="0" file="trusted-firmware-load-error.exp" track_expect
-	model="$model" nvcounter_diag="4" gen_model_params
 
+	model="$model" nvcounter_diag="4" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.linux.bl33 b/run_config/fvp-aemv8a.linux.bl33
index 8fcbd3f..d4a57d5 100644
--- a/run_config/fvp-aemv8a.linux.bl33
+++ b/run_config/fvp-aemv8a.linux.bl33
@@ -1,19 +1,22 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
+
 post_tf_build() {
 	# Build FIP without any BL33 image (it is preloaded)
 	build_fip
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	kernel_addr="0x80080000" dtb_addr="0x80070000" \
-		model="$model" gen_model_params
+	model="$model" \
+		dtb_addr="0x80070000" \
+		kernel_addr="0x80080000" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.memprotect b/run_config/fvp-aemv8a.memprotect
index e4defd4..aea23f2 100644
--- a/run_config/fvp-aemv8a.memprotect
+++ b/run_config/fvp-aemv8a.memprotect
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -9,19 +9,20 @@
 	get_uboot_bin
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
 	image=${archive}/tmp.bin
-	printf '\1\0\0\0' > "$image"
+	printf '\1\0\0\0' >"$image"
 
-	preload_bl33="1" \
-	preload_bl33_bin="uboot.bin" \
-	reset_to_bl31="1" \
-	cache_state_modelled="0" \
-	memprotect="$image" \
-	memprotect_addr="0xBFC0000" \
-		model="$model" gen_model_params
+	model="$model" \
+		cache_state_modelled="0" \
+		memprotect_addr="0xBFC0000" \
+		memprotect="$image" \
+		preload_bl33_bin="uboot.bin" \
+		preload_bl33="1" \
+		reset_to_bl31="1" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.nocm b/run_config/fvp-aemv8a.nocm
index d7ffda5..184a451 100644
--- a/run_config/fvp-aemv8a.nocm
+++ b/run_config/fvp-aemv8a.nocm
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-	cache_state_modelled="0" model="$model" gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a"
 
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.nvcounter_v1 b/run_config/fvp-aemv8a.nvcounter_v1
index 70b3dfc..20fa09f 100644
--- a/run_config/fvp-aemv8a.nvcounter_v1
+++ b/run_config/fvp-aemv8a.nvcounter_v1
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
 	# Version 1 of the non-volatile counter may be incremented in a
 	# monotonic fashion (unlike version 0, which is fixed).
-	model="$model" nvcounter_version="r1" nvcounter_diag="4" gen_model_params
-
+	model="$model" nvcounter_diag="4" nvcounter_version="r1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.pl33 b/run_config/fvp-aemv8a.pl33
index 6647d93..60ae350 100644
--- a/run_config/fvp-aemv8a.pl33
+++ b/run_config/fvp-aemv8a.pl33
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -10,12 +10,13 @@
 	build_fip
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	preload_bl33="1" \
-	preload_bl33_bin="tftf.bin" \
-		model="$model" gen_model_params
+	model="$model" \
+		preload_bl33_bin="tftf.bin" \
+		preload_bl33="1" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.pl33.bmcov b/run_config/fvp-aemv8a.pl33.bmcov
index f813c7a..a810abf 100644
--- a/run_config/fvp-aemv8a.pl33.bmcov
+++ b/run_config/fvp-aemv8a.pl33.bmcov
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -10,13 +10,15 @@
 	build_fip
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	bmcov_plugin=1 bmcov_plugin_path="${coverage_trace_plugin}" \
-	preload_bl33="1" \
-	preload_bl33_bin="tftf.bin" \
-		model="$model" gen_model_params
+	model="$model" \
+		bmcov_plugin_path="${coverage_trace_plugin}" \
+		bmcov_plugin="1" \
+		preload_bl33_bin="tftf.bin" \
+		preload_bl33="1" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.quad b/run_config/fvp-aemv8a.quad
index 289f347..9db5828 100644
--- a/run_config/fvp-aemv8a.quad
+++ b/run_config/fvp-aemv8a.quad
@@ -1,18 +1,18 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a-quad"
 
-        model="$model" \
-	ccn502_cache_size_in_kbytes="0" \
-	gen_model_params
-
 	uart="0" set_expect_variable "num_cpus" "16"
 
-        model="$model" gen_fvp_yaml
+	model="$model" \
+		ccn502_cache_size_in_kbytes="0" \
+		gen_model_params
+
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.rng_trap.bl31_panic b/run_config/fvp-aemv8a.rng_trap.bl31_panic
index b6dcad2..4b2f29c 100644
--- a/run_config/fvp-aemv8a.rng_trap.bl31_panic
+++ b/run_config/fvp-aemv8a.rng_trap.bl31_panic
@@ -5,22 +5,17 @@
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_tf_archive() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	model="$model" \
+	uart="0" timeout="60" file="timeout.exp" track_expect
+	uart="1" timeout="60" file="crash_rng_trap_unhandled_exception_at_el3.exp" track_expect
+
 	# Due to a bug in the model, the FEAT_RNG_TRAP feature is not available
 	# in models that implement versions lower than 8.8, even though this is
 	# a v8.5 feature. Therefore, version 8.8 will be used while the FVP
 	# team fixes this problem. Once ready, the parameter arch_version will
 	# be changed to 8.5.
-	arch_version="8.8"  \
-	has_rng_trap="1" \
-	gen_model_params
+	model="$model" arch_version="8.8" has_rng_trap="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
-
-fetch_tf_resource() {
-	uart="0" timeout="60" file="timeout.exp" track_expect
-	uart="1" timeout="60" file="crash_rng_trap_unhandled_exception_at_el3.exp" track_expect
-}
diff --git a/run_config/fvp-aemv8a.roxlattables.bl31_panic b/run_config/fvp-aemv8a.roxlattables.bl31_panic
index cc4afa9..7b66ba3 100644
--- a/run_config/fvp-aemv8a.roxlattables.bl31_panic
+++ b/run_config/fvp-aemv8a.roxlattables.bl31_panic
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -13,14 +13,12 @@
 	apply_tf_patch "readonly_xlat_tables/arm_bl31_setup_write_after_readonly.patch"
 }
 
-post_tf_archive() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	uart="0" timeout="60" file="timeout.exp" track_expect
+	uart="1" timeout="60" file="crash_roxlattables_unhandled_exception_at_el3.exp" track_expect
 
 	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
-
-fetch_tf_resource() {
-	uart="0" timeout="60" file="timeout.exp" track_expect
-	uart="1" timeout="60" file="crash_roxlattables_unhandled_exception_at_el3.exp" track_expect
-}
diff --git a/run_config/fvp-aemv8a.roxlattables.tspd_panic b/run_config/fvp-aemv8a.roxlattables.tspd_panic
index 71f5240..5ca3407 100644
--- a/run_config/fvp-aemv8a.roxlattables.tspd_panic
+++ b/run_config/fvp-aemv8a.roxlattables.tspd_panic
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -16,15 +16,13 @@
 	apply_tf_patch "readonly_xlat_tables/tsp_sync_exception_print_panic_message.patch"
 }
 
-post_tf_archive() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	model="$model" gen_model_params
-	model="$model" gen_fvp_yaml
-}
-
-fetch_tf_resource() {
 	uart="0" timeout="60" file="timeout.exp" track_expect
 	uart="1" timeout="60" file="crash_panic.exp" track_expect
 	uart="2" timeout="60" file="readonly_el1_xlat_tables.exp" track_expect
+
+	model="$model" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.rst31 b/run_config/fvp-aemv8a.rst31
index c977772..dcf81d5 100644
--- a/run_config/fvp-aemv8a.rst31
+++ b/run_config/fvp-aemv8a.rst31
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -9,13 +9,14 @@
 	get_uboot_bin
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	preload_bl33="1" \
-	preload_bl33_bin="uboot.bin" \
-	reset_to_bl31="1" \
-		model="$model" gen_model_params
+	model="$model" \
+		preload_bl33_bin="uboot.bin" \
+		preload_bl33="1" \
+		reset_to_bl31="1" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.rstspmin b/run_config/fvp-aemv8a.rstspmin
index 69262d1..3fdc657 100644
--- a/run_config/fvp-aemv8a.rstspmin
+++ b/run_config/fvp-aemv8a.rstspmin
@@ -1,16 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020, Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	reset_to_spmin="1" \
-		aarch32="1" \
-		model="$model" gen_model_params
-
+	model="$model" aarch32="1" reset_to_spmin="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.singlecore b/run_config/fvp-aemv8a.singlecore
index 900b402..b4fdfc1 100644
--- a/run_config/fvp-aemv8a.singlecore
+++ b/run_config/fvp-aemv8a.singlecore
@@ -1,16 +1,19 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	model="$model" cluster_0_num_cores="1" cluster_1_num_cores="0" \
-		gen_model_params
 	uart="0" set_expect_variable "num_cpus" "1"
 
+	model="$model" \
+		cluster_0_num_cores="1" \
+		cluster_1_num_cores="0" \
+		gen_model_params
+
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.singlecore.bmcov b/run_config/fvp-aemv8a.singlecore.bmcov
index 69ced13..85ae259 100644
--- a/run_config/fvp-aemv8a.singlecore.bmcov
+++ b/run_config/fvp-aemv8a.singlecore.bmcov
@@ -1,17 +1,21 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	bmcov_plugin=1 bmcov_plugin_path="${coverage_trace_plugin}" \
-	model="$model" cluster_0_num_cores="1" cluster_1_num_cores="0" \
-		gen_model_params
 	uart="0" set_expect_variable "num_cpus" "1"
 
+	model="$model" \
+		bmcov_plugin_path="${coverage_trace_plugin}" \
+		bmcov_plugin="1" \
+		cluster_0_num_cores="1" \
+		cluster_1_num_cores="0" \
+		gen_model_params
+
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.sve b/run_config/fvp-aemv8a.sve
index d942b62..1811b25 100644
--- a/run_config/fvp-aemv8a.sve
+++ b/run_config/fvp-aemv8a.sve
@@ -1,15 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	sve_plugin=1 \
-		model="$model" gen_model_params
-
+	model="$model" sve_plugin="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.sve.bmcov b/run_config/fvp-aemv8a.sve.bmcov
index 7d2c49a..3aef7fd 100644
--- a/run_config/fvp-aemv8a.sve.bmcov
+++ b/run_config/fvp-aemv8a.sve.bmcov
@@ -1,16 +1,18 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
 
-	bmcov_plugin=1 bmcov_plugin_path="${coverage_trace_plugin}" \
-	sve_plugin=1 \
-		model="$model" gen_model_params
+	model="$model" \
+		bmcov_plugin_path="${coverage_trace_plugin}" \
+		bmcov_plugin="1" \
+		sve_plugin="1" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a.tbb.disable_dyn_auth b/run_config/fvp-aemv8a.tbb.disable_dyn_auth
index f48676e..062cc2b 100644
--- a/run_config/fvp-aemv8a.tbb.disable_dyn_auth
+++ b/run_config/fvp-aemv8a.tbb.disable_dyn_auth
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -11,13 +11,11 @@
 	apply_tf_patch "tbb_dyn_auth/disable_dyn_auth.patch"
 }
 
-post_tf_archive() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	uart="0" file="disable_dyn_auth_tftf.exp" track_expect
 
 	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
-
-fetch_tf_resource() {
-	uart="0" file="disable_dyn_auth_tftf.exp" track_expect
-}
diff --git a/run_config/fvp-aemv8a.ubsan_test b/run_config/fvp-aemv8a.ubsan_test
index f0e151f..4ed1e9f 100644
--- a/run_config/fvp-aemv8a.ubsan_test
+++ b/run_config/fvp-aemv8a.ubsan_test
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -10,14 +10,12 @@
 	apply_tf_patch "ubsan/ubsan_test.patch"
 }
 
-post_tf_archive() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	# Expect trap message on uart 1
+	uart="1" set_primary="1" file="ubsan-test-trap.exp" track_expect
 
 	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
-
-fetch_tf_resource() {
-	# Expect trap message on uart 1
-	uart="1" set_primary="1" file="ubsan-test-trap.exp" track_expect
-}
diff --git a/run_config/fvp-aemv8a_gic600ae b/run_config/fvp-aemv8a_gic600ae
index 2892271..fdca2d2 100644
--- a/run_config/fvp-aemv8a_gic600ae
+++ b/run_config/fvp-aemv8a_gic600ae
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a-gic600ae"
-        model="$model" gen_model_params
+generate_lava_job() {
+	local model="base-aemv8a-gic600ae"
 
-        model="$model" gen_fvp_yaml
+	model="$model" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a_gic600ae.aarch32 b/run_config/fvp-aemv8a_gic600ae.aarch32
index d3dad22..5b63251 100644
--- a/run_config/fvp-aemv8a_gic600ae.aarch32
+++ b/run_config/fvp-aemv8a_gic600ae.aarch32
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a-gic600ae"
-	aarch32="1" model="$model" gen_model_params
 
+	model="$model" aarch32="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a_revb b/run_config/fvp-aemv8a_revb
index e038bd2..f11f8da 100644
--- a/run_config/fvp-aemv8a_revb
+++ b/run_config/fvp-aemv8a_revb
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemv8a-revb"
 
-        model="$model" gen_model_params
+	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a_revb.aarch32 b/run_config/fvp-aemv8a_revb.aarch32
index b7c8be3..2752b2a 100644
--- a/run_config/fvp-aemv8a_revb.aarch32
+++ b/run_config/fvp-aemv8a_revb.aarch32
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a-revb"
+generate_lava_job() {
+	local model="base-aemv8a-revb"
 
-	aarch32="1" model="$model" gen_model_params
-        model="$model" gen_fvp_yaml
+	model="$model" aarch32="1" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a_revb.asymetric b/run_config/fvp-aemv8a_revb.asymetric
index 85731c1..d941029 100644
--- a/run_config/fvp-aemv8a_revb.asymetric
+++ b/run_config/fvp-aemv8a_revb.asymetric
@@ -1,21 +1,24 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a-revb"
+generate_lava_job() {
+	local model="base-aemv8a-revb"
 
-	arch_version="8.3" \
-		cluster_0_reg_reset="0xffffffff" \
-		cluster_0_has_el2="0" \
-		cluster_1_reg_reset="0xffffffff" \
-		cluster_1_has_el2="0" \
-		cluster_0_num_cores="2" \
-		cluster_1_num_cores="3" \
-		model="$model" gen_model_params
 	uart="0" set_expect_variable "num_cpus" "5"
-        model="$model" gen_fvp_yaml
+
+	model="$model" \
+		arch_version="8.3" \
+		cluster_0_has_el2="0" \
+		cluster_0_num_cores="2" \
+		cluster_0_reg_reset="0xffffffff" \
+		cluster_1_has_el2="0" \
+		cluster_1_num_cores="3" \
+		cluster_1_reg_reset="0xffffffff" \
+		gen_model_params
+
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a_revb.gicv2 b/run_config/fvp-aemv8a_revb.gicv2
index f4cb06a..b10277b 100644
--- a/run_config/fvp-aemv8a_revb.gicv2
+++ b/run_config/fvp-aemv8a_revb.gicv2
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a-revb"
+generate_lava_job() {
+	local model="base-aemv8a-revb"
 
-	gicv3_gicv2_only="1" model="$model" gen_model_params
-        model="$model" gen_fvp_yaml
+	model="$model" gicv3_gicv2_only="1" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8a_revb.latest b/run_config/fvp-aemv8a_revb.latest
index 605d9a1..a4c9775 100644
--- a/run_config/fvp-aemv8a_revb.latest
+++ b/run_config/fvp-aemv8a_revb.latest
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a-latest-revb"
+generate_lava_job() {
+	local model="base-aemv8a-latest-revb"
 
 	model="$model" gen_model_params
-        model="$model" gen_fvp_yaml
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemv8r.linux b/run_config/fvp-aemv8r.linux
index 8e597f0..086d60c 100755
--- a/run_config/fvp-aemv8r.linux
+++ b/run_config/fvp-aemv8r.linux
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -21,24 +21,20 @@
 	build_fip BL33="$archive/uboot.bin"
 }
 
-fetch_tf_resource() {
-	# Expect script for yocto linux boot
-	uart="0" file="fvp-r-yocto.exp" track_expect
-
-	# Generate FVP model YAML template
+generate_lava_job_template() {
 	payload_type="linux" gen_fvp_yaml_template
 }
 
-post_fetch_tf_resource() {
-        local model="baser-aemv8r"
+generate_lava_job() {
+	local model="baser-aemv8r"
 
-        # Generate the model command parameters
+	uart="0" file="fvp-r-yocto.exp" track_expect
+
 	model="$model" \
-	fip_addr=0x40000000 \
-	dtb_addr=0x03000000 \
-	kernel_addr=0x00800000 \
-	gen_model_params
+		dtb_addr="0x03000000" \
+		fip_addr="0x40000000" \
+		kernel_addr="0x00800000" \
+		gen_model_params
 
-	# Generate the FVP yaml file
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemva b/run_config/fvp-aemva
index a452bba..9af9638 100644
--- a/run_config/fvp-aemva
+++ b/run_config/fvp-aemva
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemva"
+generate_lava_job() {
+	local model="base-aemva"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemva.8_6 b/run_config/fvp-aemva.8_6
index c797f09..8392b39 100644
--- a/run_config/fvp-aemva.8_6
+++ b/run_config/fvp-aemva.8_6
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemva"
+generate_lava_job() {
+	local model="base-aemva"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" arch_version="8.6" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
-        model="$model" gen_fvp_yaml
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemva.aarch32 b/run_config/fvp-aemva.aarch32
index f8d4705..caf6051 100644
--- a/run_config/fvp-aemva.aarch32
+++ b/run_config/fvp-aemva.aarch32
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="base-aemva"
+generate_lava_job() {
+	local model="base-aemva"
 
-	aarch32="1" model="$model" gen_model_params
+	model="$model" aarch32="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemva.aarch32.etm_trace_ext b/run_config/fvp-aemva.aarch32.etm_trace_ext
index 3c25591..306cb06 100644
--- a/run_config/fvp-aemva.aarch32.etm_trace_ext
+++ b/run_config/fvp-aemva.aarch32.etm_trace_ext
@@ -1,18 +1,19 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemva"
 
-	aarch32="1" \
-	etm_present="1" \
-	etm_plugin="1" \
-	supports_trace_filter_regs="2" \
-	model="$model" gen_model_params
+	model="$model" \
+		aarch32="1" \
+		etm_plugin="1" \
+		etm_present="1" \
+		supports_trace_filter_regs="2" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemva.ete_trace_ext b/run_config/fvp-aemva.ete_trace_ext
index 5e96207..1ca10b1 100644
--- a/run_config/fvp-aemva.ete_trace_ext
+++ b/run_config/fvp-aemva.ete_trace_ext
@@ -1,21 +1,22 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemva"
 
-	model_version="0.0" \
-	model_build="6684" \
-	model_flavour="Linux64_GCC-6.4" \
-	etm_present="1" \
-	ete_plugin="1" \
-	supports_trace_buffer_control_regs="1" \
-	supports_trace_filter_regs="2" \
-	model="$model" gen_model_params
+	model="$model" \
+		ete_plugin="1" \
+		etm_present="1" \
+		model_build="6684" \
+		model_flavour="Linux64_GCC-6.4" \
+		model_version="0.0" \
+		supports_trace_buffer_control_regs="1" \
+		supports_trace_filter_regs="2" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemva.ete_trace_ext.bl31_panic b/run_config/fvp-aemva.ete_trace_ext.bl31_panic
index 48d2de9..86f1ae5 100644
--- a/run_config/fvp-aemva.ete_trace_ext.bl31_panic
+++ b/run_config/fvp-aemva.ete_trace_ext.bl31_panic
@@ -1,26 +1,25 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemva"
 
-	model_version="0.0" \
-	model_build="6684" \
-	model_flavour="Linux64_GCC-6.4" \
-	etm_present="1" \
-	ete_plugin="1" \
-	supports_trace_buffer_control_regs="1" \
-	supports_trace_filter_regs="2" \
-	model="$model" gen_model_params
+	uart="0" timeout="60" file="timeout_test.exp" track_expect
+	uart="1" timeout="60" file="unhandled_exception_at_el3.exp" track_expect
+
+	model="$model" \
+		ete_plugin="1" \
+		etm_present="1" \
+		model_build="6684" \
+		model_flavour="Linux64_GCC-6.4" \
+		model_version="0.0" \
+		supports_trace_buffer_control_regs="1" \
+		supports_trace_filter_regs="2" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
-
-fetch_tf_resource() {
-	uart="0"  timeout="60" file="timeout_test.exp" track_expect
-	uart="1"  timeout="60" file="unhandled_exception_at_el3.exp" track_expect
-}
diff --git a/run_config/fvp-aemva.etm_trace_ext b/run_config/fvp-aemva.etm_trace_ext
index 64e03c5..8debb5c 100644
--- a/run_config/fvp-aemva.etm_trace_ext
+++ b/run_config/fvp-aemva.etm_trace_ext
@@ -1,18 +1,19 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemva"
 
-	etm_present="1" \
-	etm_plugin="1" \
-	supports_trace_buffer_control_regs="1" \
-	supports_trace_filter_regs="2" \
-	model="$model" gen_model_params
+	model="$model" \
+		etm_plugin="1" \
+		etm_present="1" \
+		supports_trace_buffer_control_regs="1" \
+		supports_trace_filter_regs="2" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-aemva.feat_brbe.bl31_panic b/run_config/fvp-aemva.feat_brbe.bl31_panic
index aa63658..ec35d77 100644
--- a/run_config/fvp-aemva.feat_brbe.bl31_panic
+++ b/run_config/fvp-aemva.feat_brbe.bl31_panic
@@ -1,18 +1,19 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2022 Arm Limited. All rights reserved.
+# Copyright (c) 2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="base-aemva"
-	supports_branch_record_buffer_control_regs="1" \
-	model="$model" gen_model_params
-	model="$model" gen_fvp_yaml
-}
 
-fetch_tf_resource() {
-	uart="0"  timeout="60" file="timeout_test.exp" track_expect
-	uart="1"  timeout="60" file="unhandled_exception_at_el3.exp" track_expect
+	uart="0" timeout="60" file="timeout_test.exp" track_expect
+	uart="1" timeout="60" file="unhandled_exception_at_el3.exp" track_expect
+
+	model="$model" \
+		supports_branch_record_buffer_control_regs="1" \
+		gen_model_params
+
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa32x4 b/run_config/fvp-cortexa32x4
index 42a9a65..05879e0 100644
--- a/run_config/fvp-cortexa32x4
+++ b/run_config/fvp-cortexa32x4
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a32x4"
+generate_lava_job() {
+	local model="cortex-a32x4"
 
-	model="$model" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
 
+	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa32x4.rstspmin b/run_config/fvp-cortexa32x4.rstspmin
index 0455cb0..d2ee099 100644
--- a/run_config/fvp-cortexa32x4.rstspmin
+++ b/run_config/fvp-cortexa32x4.rstspmin
@@ -1,17 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a32x4"
+generate_lava_job() {
+	local model="cortex-a32x4"
 
-	reset_to_spmin="1" \
-	model="$model" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
 
+	model="$model" reset_to_spmin="1" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa35x4 b/run_config/fvp-cortexa35x4
index 09b0bf0..db8504a 100644
--- a/run_config/fvp-cortexa35x4
+++ b/run_config/fvp-cortexa35x4
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="cortex-a35x4"
 
-	model="$model" gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa53x4 b/run_config/fvp-cortexa53x4
index 6c489c8..0b234d8 100644
--- a/run_config/fvp-cortexa53x4
+++ b/run_config/fvp-cortexa53x4
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a53x4"
+generate_lava_job() {
+	local model="cortex-a53x4"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa55x4 b/run_config/fvp-cortexa55x4
index 0e0b333..0f97d7a 100644
--- a/run_config/fvp-cortexa55x4
+++ b/run_config/fvp-cortexa55x4
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a55x4"
+generate_lava_job() {
+	local model="cortex-a55x4"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" cache_state_modelled="0" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa55x4a75x4 b/run_config/fvp-cortexa55x4a75x4
index 6a92e23..9c8a461 100644
--- a/run_config/fvp-cortexa55x4a75x4
+++ b/run_config/fvp-cortexa55x4a75x4
@@ -1,13 +1,13 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a55x4-a75x4"
+generate_lava_job() {
+	local model="cortex-a55x4-a75x4"
 
 	model="$model" cache_state_modelled="0" gen_model_params
-	model="$model"  gen_fvp_yaml
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa55x4a76x2 b/run_config/fvp-cortexa55x4a76x2
index 7195ea6..ef8ba5b 100644
--- a/run_config/fvp-cortexa55x4a76x2
+++ b/run_config/fvp-cortexa55x4a76x2
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a55x4-a76x2"
+generate_lava_job() {
+	local model="cortex-a55x4-a76x2"
+
+	uart="0" set_expect_variable "num_cpus" "6"
 
 	model="$model" cache_state_modelled="0" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "6"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa57x1a53x1 b/run_config/fvp-cortexa57x1a53x1
index 9b847c1..f5893ca 100644
--- a/run_config/fvp-cortexa57x1a53x1
+++ b/run_config/fvp-cortexa57x1a53x1
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a57x1-a53x1"
+generate_lava_job() {
+	local model="cortex-a57x1-a53x1"
+
+	uart="0" set_expect_variable "num_cpus" "2"
 
 	model="$model" gen_model_params
-        uart="0" set_expect_variable "num_cpus" "2"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa57x2a53x4 b/run_config/fvp-cortexa57x2a53x4
index 2fa4659..d412e72 100644
--- a/run_config/fvp-cortexa57x2a53x4
+++ b/run_config/fvp-cortexa57x2a53x4
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a57x2-a53x4"
+generate_lava_job() {
+	local model="cortex-a57x2-a53x4"
+
+	uart="0" set_expect_variable "num_cpus" "6"
 
 	model="$model" gen_model_params
-        uart="0" set_expect_variable "num_cpus" "6"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa57x4 b/run_config/fvp-cortexa57x4
index cd7a369..bcb2706 100644
--- a/run_config/fvp-cortexa57x4
+++ b/run_config/fvp-cortexa57x4
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a57x4"
+generate_lava_job() {
+	local model="cortex-a57x4"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa57x4a53x4 b/run_config/fvp-cortexa57x4a53x4
index 8089e3d..55230c0 100644
--- a/run_config/fvp-cortexa57x4a53x4
+++ b/run_config/fvp-cortexa57x4a53x4
@@ -1,12 +1,12 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a57x4-a53x4"
+generate_lava_job() {
+	local model="cortex-a57x4-a53x4"
 
 	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-cortexa57x4a53x4.rst31 b/run_config/fvp-cortexa57x4a53x4.rst31
index 89db485..f1bfab8 100644
--- a/run_config/fvp-cortexa57x4a53x4.rst31
+++ b/run_config/fvp-cortexa57x4a53x4.rst31
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -9,12 +9,14 @@
 	get_uboot_bin
 }
 
-post_fetch_tf_resource() {
-        local model="cortex-a57x4-a53x4"
+generate_lava_job() {
+	local model="cortex-a57x4-a53x4"
 
-	preload_bl33="1" \
-	preload_bl33_bin="uboot.bin" \
-	reset_to_bl31="1" \
-		model="$model" gen_model_params
+	model="$model" \
+		preload_bl33_bin="uboot.bin" \
+		preload_bl33="1" \
+		reset_to_bl31="1" \
+		gen_model_params
+
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa65aex8 b/run_config/fvp-cortexa65aex8
index ae60da3..8ef8ed1 100644
--- a/run_config/fvp-cortexa65aex8
+++ b/run_config/fvp-cortexa65aex8
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020, Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a65aex8"
+generate_lava_job() {
+	local model="cortex-a65aex8"
 
-	model="$model" \
-	data_instance="cluster0.cpu0.thread0" \
-		gen_model_params
 	uart="0" set_expect_variable "num_cpus" "16"
+
+	model="$model" data_instance="cluster0.cpu0.thread0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa65x4 b/run_config/fvp-cortexa65x4
index 27a5e8c..fa87415 100644
--- a/run_config/fvp-cortexa65x4
+++ b/run_config/fvp-cortexa65x4
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020, Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -8,10 +8,11 @@
 # data_instance must be set to cluster0.cpu0.thread0 because the model does not accept --data
 # parameter on the default cluster0.cpu0 instance.
 
-post_fetch_tf_resource() {
-        local model="cortex-a65x4"
+generate_lava_job() {
+	local model="cortex-a65x4"
+
+	uart="0" set_expect_variable "num_cpus" "8"
 
 	model="$model" data_instance="cluster0.cpu0.thread0" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "8"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa710x4 b/run_config/fvp-cortexa710x4
index 5119c94..1eea3e8 100644
--- a/run_config/fvp-cortexa710x4
+++ b/run_config/fvp-cortexa710x4
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a710"
+generate_lava_job() {
+	local model="cortex-a710"
 
-	model="$model" \
-	cache_state_modelled="0" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa72x4 b/run_config/fvp-cortexa72x4
index 8c59b28..f0bfc68 100644
--- a/run_config/fvp-cortexa72x4
+++ b/run_config/fvp-cortexa72x4
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a72x4"
+generate_lava_job() {
+	local model="cortex-a72x4"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa72x4a53x4 b/run_config/fvp-cortexa72x4a53x4
index f4fee25..391234a 100644
--- a/run_config/fvp-cortexa72x4a53x4
+++ b/run_config/fvp-cortexa72x4a53x4
@@ -1,12 +1,12 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a72x4-a53x4"
+generate_lava_job() {
+	local model="cortex-a72x4-a53x4"
 
 	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-cortexa73x4 b/run_config/fvp-cortexa73x4
index b593237..3013152 100644
--- a/run_config/fvp-cortexa73x4
+++ b/run_config/fvp-cortexa73x4
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a73x4"
+generate_lava_job() {
+	local model="cortex-a73x4"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa73x4a53x4 b/run_config/fvp-cortexa73x4a53x4
index c4148ac..ddbd54e 100644
--- a/run_config/fvp-cortexa73x4a53x4
+++ b/run_config/fvp-cortexa73x4a53x4
@@ -1,12 +1,12 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a73x4-a53x4"
+generate_lava_job() {
+	local model="cortex-a73x4-a53x4"
 
 	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-cortexa75x4 b/run_config/fvp-cortexa75x4
index 9727591..973df37 100644
--- a/run_config/fvp-cortexa75x4
+++ b/run_config/fvp-cortexa75x4
@@ -1,17 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a75x4"
+generate_lava_job() {
+	local model="cortex-a75x4"
 
-	model="$model" \
-	cache_state_modelled="0" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
 
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa76aex4 b/run_config/fvp-cortexa76aex4
index 6e3d35e..89bd07c 100644
--- a/run_config/fvp-cortexa76aex4
+++ b/run_config/fvp-cortexa76aex4
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a76aex4"
+generate_lava_job() {
+	local model="cortex-a76aex4"
 
-        model="$model" \
-        cache_state_modelled="0" \
-        gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
-        model="$model" gen_fvp_yaml
+
+	model="$model" cache_state_modelled="0" gen_model_params
+	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa76x4 b/run_config/fvp-cortexa76x4
index 5813b5b..c421023 100644
--- a/run_config/fvp-cortexa76x4
+++ b/run_config/fvp-cortexa76x4
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a76x4"
+generate_lava_job() {
+	local model="cortex-a76x4"
 
-	model="$model" \
-	cache_state_modelled="0" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa77x4 b/run_config/fvp-cortexa77x4
index 8a2bc7d..c7fd3c9 100644
--- a/run_config/fvp-cortexa77x4
+++ b/run_config/fvp-cortexa77x4
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a77x4"
+generate_lava_job() {
+	local model="cortex-a77x4"
 
-	model="$model" \
-	cache_state_modelled="0" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa78cx4 b/run_config/fvp-cortexa78cx4
index 3bf8b00..0f6aa80 100644
--- a/run_config/fvp-cortexa78cx4
+++ b/run_config/fvp-cortexa78cx4
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2022 Arm Limited. All rights reserved.
+# Copyright (c) 2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="cortex-a78cx4"
+generate_lava_job() {
+	local model="cortex-a78cx4"
 
-	model="$model" \
-	cache_state_modelled="0" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexa78x4 b/run_config/fvp-cortexa78x4
index 5243676..ec4c7fa 100644
--- a/run_config/fvp-cortexa78x4
+++ b/run_config/fvp-cortexa78x4
@@ -1,11 +1,10 @@
 #!/usr/bin/env bash
 
-post_fetch_tf_resource() {
-        local model="cortex-a78x4"
+generate_lava_job() {
+	local model="cortex-a78x4"
 
-	model="$model" \
-	cache_state_modelled="0" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-cortexx2 b/run_config/fvp-cortexx2
index 5a4c504..1dd18fb 100644
--- a/run_config/fvp-cortexx2
+++ b/run_config/fvp-cortexx2
@@ -1,11 +1,10 @@
 #!/usr/bin/env bash
 
-post_fetch_tf_resource() {
-        local model="cortex-x2"
+generate_lava_job() {
+	local model="cortex-x2"
 
-	model="$model" \
-	cache_state_modelled="0" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-foundationv8 b/run_config/fvp-foundationv8
index 2270ed3..4a08a94 100644
--- a/run_config/fvp-foundationv8
+++ b/run_config/fvp-foundationv8
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="foundationv8"
+generate_lava_job() {
+	local model="foundationv8"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-foundationv8.8_0 b/run_config/fvp-foundationv8.8_0
index d9ec82e..c2159cb 100644
--- a/run_config/fvp-foundationv8.8_0
+++ b/run_config/fvp-foundationv8.8_0
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="foundationv8"
+generate_lava_job() {
+	local model="foundationv8"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" arch_version="8.0" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-foundationv8.8_1 b/run_config/fvp-foundationv8.8_1
index caa162d..c75b36a 100644
--- a/run_config/fvp-foundationv8.8_1
+++ b/run_config/fvp-foundationv8.8_1
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="foundationv8"
+generate_lava_job() {
+	local model="foundationv8"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" arch_version="8.1" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-foundationv8.8_2 b/run_config/fvp-foundationv8.8_2
index ae4e58c..768c2e1 100644
--- a/run_config/fvp-foundationv8.8_2
+++ b/run_config/fvp-foundationv8.8_2
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="foundationv8"
+generate_lava_job() {
+	local model="foundationv8"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" arch_version="8.2" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-foundationv8.8_3 b/run_config/fvp-foundationv8.8_3
index 5619568..708a086 100644
--- a/run_config/fvp-foundationv8.8_3
+++ b/run_config/fvp-foundationv8.8_3
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="foundationv8"
+generate_lava_job() {
+	local model="foundationv8"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" arch_version="8.3" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-foundationv8.8_4 b/run_config/fvp-foundationv8.8_4
index 9636499..01b0b59 100644
--- a/run_config/fvp-foundationv8.8_4
+++ b/run_config/fvp-foundationv8.8_4
@@ -1,14 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="foundationv8"
+generate_lava_job() {
+	local model="foundationv8"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" arch_version="8.4" gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-foundationv8.bmcov b/run_config/fvp-foundationv8.bmcov
index 0de8553..aedd6a5 100644
--- a/run_config/fvp-foundationv8.bmcov
+++ b/run_config/fvp-foundationv8.bmcov
@@ -1,15 +1,19 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="foundationv8"
+generate_lava_job() {
+	local model="foundationv8"
 
-	bmcov_plugin=1 bmcov_plugin_path="${coverage_trace_plugin}" \
-        model="$model" gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" \
+		bmcov_plugin_path="${coverage_trace_plugin}" \
+		bmcov_plugin="1" \
+		gen_model_params
+
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-foundationv8.linux.bl33 b/run_config/fvp-foundationv8.linux.bl33
index 7133969..6f8493f 100644
--- a/run_config/fvp-foundationv8.linux.bl33
+++ b/run_config/fvp-foundationv8.linux.bl33
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -10,13 +10,15 @@
 	build_fip
 }
 
-post_fetch_tf_resource() {
-        local model="foundationv8"
-
-	kernel_addr="0x80080000" dtb_addr="0x80070000" \
-		model="$model" gen_model_params
+generate_lava_job() {
+	local model="foundationv8"
 
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" \
+		dtb_addr="0x80070000" \
+		kernel_addr="0x80080000" \
+		gen_model_params
+
 	model="model" gen_fvp_yaml
 }
-
diff --git a/run_config/fvp-linux b/run_config/fvp-linux
index 25c7f8d..b77573e 100644
--- a/run_config/fvp-linux
+++ b/run_config/fvp-linux
@@ -8,6 +8,9 @@
 fetch_tf_resource() {
 	kernel_type="fvp-busybox-uboot" get_kernel
 	initrd_type="default" get_initrd
+}
+
+generate_lava_job_template() {
 	uart="0" file="linux-rd-busybox.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
diff --git a/run_config/fvp-linux.bl33 b/run_config/fvp-linux.bl33
index a8dfe51..b357fcf 100644
--- a/run_config/fvp-linux.bl33
+++ b/run_config/fvp-linux.bl33
@@ -1,12 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
 fetch_tf_resource() {
 	kernel_type="fvp-busybox-uboot" get_kernel
+}
+
+generate_lava_job_template() {
 	uart="0" file="linux-bl33.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
diff --git a/run_config/fvp-linux.morello b/run_config/fvp-linux.morello
index be3cf6d..1efbcb7 100644
--- a/run_config/fvp-linux.morello
+++ b/run_config/fvp-linux.morello
@@ -1,16 +1,17 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
 fetch_tf_resource() {
-	uart="1" set_primary="1" file="linux-rd-busybox.exp" track_expect
-
 	url="$morello_prebuilts/busybox.img" saveas="busybox.bin" fetch_file
-
 	archive_file "busybox.bin"
+}
+
+generate_lava_job_template() {
+	uart="1" set_primary="1" file="linux-rd-busybox.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-linux.quad b/run_config/fvp-linux.quad
index f4aef95..1684589 100644
--- a/run_config/fvp-linux.quad
+++ b/run_config/fvp-linux.quad
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -8,6 +8,9 @@
 fetch_tf_resource() {
 	kernel_type="fvp-quad-busybox-uboot" get_kernel
 	initrd_type="default" get_initrd
+}
+
+generate_lava_job_template() {
 	uart="0" file="linux-rd-busybox.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
diff --git a/run_config/fvp-linux.rootfs b/run_config/fvp-linux.rootfs
index b1bc531..4743ed9 100644
--- a/run_config/fvp-linux.rootfs
+++ b/run_config/fvp-linux.rootfs
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -9,6 +9,9 @@
 	kernel_type="fvp-oe-uboot" get_kernel
 	initrd_type="dummy-ramdisk" get_initrd
 	get_rootfs
+}
+
+generate_lava_job_template() {
 	uart="0" timeout="1800" file="linux-oe.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
diff --git a/run_config/fvp-linux.rootfs+ftpm b/run_config/fvp-linux.rootfs+ftpm
index 530079b..7429946 100644
--- a/run_config/fvp-linux.rootfs+ftpm
+++ b/run_config/fvp-linux.rootfs+ftpm
@@ -1,22 +1,25 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_tf_build() {
-        # Get the images for the test.
-        edk_url="$tfa_downloads/ftpm/FVP_AARCH64_EFI.fd"
-        rootfs_url="$tfa_downloads/ftpm/boot-fat.uefi.img" get_rootfs
-        url="$edk_url" saveas="edk2.bin" fetch_file
-        archive_file "edk2.bin"
+fetch_tf_resource() {
+	# Get the images for the test.
+	edk_url="$tfa_downloads/ftpm/FVP_AARCH64_EFI.fd"
+	rootfs_url="$tfa_downloads/ftpm/boot-fat.uefi.img" get_rootfs
+	url="$edk_url" saveas="edk2.bin" fetch_file
+	archive_file "edk2.bin"
+}
 
-        # Configure the uarts for tracking.
-        uart="0" timeout="600" file="linux-tpm.exp" track_expect
-        uart="1" timeout="600" file="tpm-logs.exp" track_expect
-        set_run_env "ports_script" "$ci_root/model/ftpm-ports.awk"
-        set_run_env "num_uarts" "2"
+generate_lava_job_template() {
+	# Configure the uarts for tracking.
+	uart="0" timeout="600" file="linux-tpm.exp" track_expect
+	uart="1" timeout="600" file="tpm-logs.exp" track_expect
+
+	set_run_env "ports_script" "$ci_root/model/ftpm-ports.awk"
+	set_run_env "num_uarts" "2"
 
 	payload_type="linux" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-linux.rootfs+ftpm_384 b/run_config/fvp-linux.rootfs+ftpm_384
index 69b45a7..3cb76f6 100644
--- a/run_config/fvp-linux.rootfs+ftpm_384
+++ b/run_config/fvp-linux.rootfs+ftpm_384
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021, Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -8,18 +8,20 @@
 # to run
 #
 
-post_tf_build() {
-        # Get the images for the test.
-        edk_url="$tfa_downloads/ftpm/FVP_AARCH64_EFI.fd"
-        rootfs_url="$tfa_downloads/ftpm/boot-fat.uefi.img" get_rootfs
-        url="$edk_url" saveas="edk2.bin" fetch_file
-        archive_file "edk2.bin"
+fetch_tf_resource() {
+	# Get the images for the test.
+	edk_url="$tfa_downloads/ftpm/FVP_AARCH64_EFI.fd"
+	rootfs_url="$tfa_downloads/ftpm/boot-fat.uefi.img" get_rootfs
+	url="$edk_url" saveas="edk2.bin" fetch_file
+	archive_file "edk2.bin"
+}
 
-        # Configure the uarts for tracking.
-        uart="0" timeout="600" file="linux-tpm-384.exp" track_expect
-        uart="1" timeout="600" file="tpm-logs.exp" track_expect
-        set_run_env "ports_script" "$ci_root/model/ftpm-ports.awk"
-        set_run_env "num_uarts" "2"
+generate_lava_job_template() {
+	uart="0" timeout="600" file="linux-tpm-384.exp" track_expect
+	uart="1" timeout="600" file="tpm-logs.exp" track_expect
 
-        payload_type="linux" gen_fvp_yaml_template
+	set_run_env "ports_script" "$ci_root/model/ftpm-ports.awk"
+	set_run_env "num_uarts" "2"
+
+	payload_type="linux" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-linux.rootfs+rst31 b/run_config/fvp-linux.rootfs+rst31
index 731a21e..f08b3fd 100644
--- a/run_config/fvp-linux.rootfs+rst31
+++ b/run_config/fvp-linux.rootfs+rst31
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -9,6 +9,9 @@
 	kernel_type="fvp-oe-uboot" get_kernel
 	initrd_type="dummy-ramdisk" get_initrd
 	get_rootfs
+}
+
+generate_lava_job_template() {
 	uart="0" timeout="1800" file="linux-oe-rst-bl31.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
diff --git a/run_config/fvp-linux.rst31 b/run_config/fvp-linux.rst31
index 21a52bf..21b49c0 100644
--- a/run_config/fvp-linux.rst31
+++ b/run_config/fvp-linux.rst31
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -8,8 +8,11 @@
 fetch_tf_resource() {
 	kernel_type="fvp-busybox-uboot" get_kernel
 	initrd_type="default" get_initrd
-	uart="0" file="linux-rd-busybox.exp" track_expect
+}
+
+generate_lava_job_template() {
 	uart="0" set_expect_variable "skip_early_boot_msgs" "1"
+	uart="0" file="linux-rd-busybox.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-linux.sgi b/run_config/fvp-linux.sgi
index 78986e8..cdc1104 100644
--- a/run_config/fvp-linux.sgi
+++ b/run_config/fvp-linux.sgi
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -8,15 +8,17 @@
 fetch_tf_resource() {
 	kernel_type="fvp-sgi-busybox" get_kernel
 	initrd_type="fvp-sgi-ramdisk" get_initrd
-	uart="1" timeout="1800" set_primary="1" file="linux-busybox-sgi.exp" track_expect
-	uart="0" file="trusted-firmware-sgi.exp" track_expect
-
 
 	url="$sgi_prebuilts/grub-busybox.img" saveas="busybox.bin" fetch_file
 	url="$sgi_prebuilts/ramdisk-busybox.img" saveas="ramdisk.bin" fetch_file
 
 	archive_file "busybox.bin"
 	archive_file "ramdisk.bin"
+}
+
+generate_lava_job_template() {
+	uart="0" file="trusted-firmware-sgi.exp" track_expect
+	uart="1" timeout="1800" set_primary="1" file="linux-busybox-sgi.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-linux.stress b/run_config/fvp-linux.stress
index 3efcf7f..33ccc06 100644
--- a/run_config/fvp-linux.stress
+++ b/run_config/fvp-linux.stress
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -8,10 +8,12 @@
 fetch_tf_resource() {
 	kernel_type="fvp-oe-uboot" get_kernel
 	initrd_type="dummy-ramdisk" get_initrd
-	# No expect tracking as this is an interactive test (test_run=1)
 
 	tmp_dir="$(mktempdir)"
 	ln -s "${img_file:?}" "$archive/rootfs.bin"
+}
 
+generate_lava_job_template() {
+	# No expect tracking as this is an interactive test (test_run=1)
 	payload_type="linux" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-linux.tc b/run_config/fvp-linux.tc
index af6aae1..b309a32 100644
--- a/run_config/fvp-linux.tc
+++ b/run_config/fvp-linux.tc
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -8,9 +8,7 @@
 fetch_tf_resource() {
 	kernel_type="fvp-tc-kernel" get_kernel
 	initrd_type="fvp-tc-ramdisk" get_initrd
-	uart="1" set_primary="1" file="linux-rd-busybox.exp" track_expect
 
-	payload_type="linux" gen_fvp_yaml_template
 	# Use SCP binary from SCP build if it exists, or fetch pre-built ones.
 	if [ ! -f "$archive/scp_rom.bin" ]; then
 		# Pick the appropriate binary based on target platform variant
@@ -18,8 +16,6 @@
 		archive_file "scp_rom.bin"
 	fi
 
-	# Hold scp terminal_s0
-	uart="0" file="hold_uart.exp" track_expect
 
 	# RSS is applicable to TC2
 	if [ $plat_variant -eq 2 ]; then
@@ -111,3 +107,11 @@
 	    inject_bl1
 	fi
 }
+
+generate_lava_job_template() {
+	# Hold scp terminal_s0
+	uart="0" file="hold_uart.exp" track_expect
+	uart="1" set_primary="1" file="linux-rd-busybox.exp" track_expect
+
+	payload_type="linux" gen_fvp_yaml_template
+}
diff --git a/run_config/fvp-linux.uefi.busybox b/run_config/fvp-linux.uefi.busybox
index 4e63c3e..37fb814 100644
--- a/run_config/fvp-linux.uefi.busybox
+++ b/run_config/fvp-linux.uefi.busybox
@@ -1,16 +1,18 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
 fetch_tf_resource() {
-	uart="0" file="linux-rd-busybox.exp" track_expect
-
 	busybox_prebuilt=$css_downloads/sgi/sgi575
 	url="$busybox_prebuilt/grub-busybox.img" saveas="rootfs.bin" fetch_file
 	archive_file "rootfs.bin"
+}
+
+generate_lava_job_template() {
+	uart="0" file="linux-rd-busybox.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-linux32 b/run_config/fvp-linux32
index 8d875db..fef94bb 100644
--- a/run_config/fvp-linux32
+++ b/run_config/fvp-linux32
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -8,6 +8,9 @@
 fetch_tf_resource() {
 	kernel_type="fvp-aarch32-zimage" get_kernel
 	initrd_type="aarch32-ramdisk" get_initrd
+}
+
+generate_lava_job_template() {
 	uart="0" file="linux-rd-busybox-aarch32.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
diff --git a/run_config/fvp-linux32.rstspmin b/run_config/fvp-linux32.rstspmin
index 36ecb1c..736ce8d 100644
--- a/run_config/fvp-linux32.rstspmin
+++ b/run_config/fvp-linux32.rstspmin
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020, Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -8,8 +8,11 @@
 fetch_tf_resource() {
 	kernel_type="fvp-aarch32-zimage" get_kernel
 	initrd_type="aarch32-ramdisk" get_initrd
-	uart="0" file="linux-rd-busybox-aarch32.exp" track_expect
+}
+
+generate_lava_job_template() {
 	uart="0" set_expect_variable "skip_early_boot_msgs" "1"
+	uart="0" file="linux-rd-busybox-aarch32.exp" track_expect
 
 	payload_type="linux" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-linux32.stress b/run_config/fvp-linux32.stress
index 8617a6b..348f050 100644
--- a/run_config/fvp-linux32.stress
+++ b/run_config/fvp-linux32.stress
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -8,10 +8,12 @@
 fetch_tf_resource() {
 	kernel_type="fvp-oe-uboot32" get_kernel
 	initrd_type="dummy-ramdisk32" get_initrd
-	# No expect tracking as this is an interactive test (test_run=1)
 
 	tmp_dir="$(mktempdir)"
 	ln -s "${img_file:?}" "$archive/rootfs.bin"
+}
 
+generate_lava_job_template() {
+	# No expect tracking as this is an interactive test (test_run=1)
 	payload_type="linux" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-morello b/run_config/fvp-morello
index 1c8ad96..452d811 100644
--- a/run_config/fvp-morello
+++ b/run_config/fvp-morello
@@ -1,27 +1,27 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
-fetch_tf_resource() {
-	# Hold terminal_uart_aon (SCP terminal)
-	uart="2" file="hold_uart.exp" track_expect
-}
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="morello"
 
-	model="morello" \
-	model_version="0.11" \
-	model_build="33" \
-	model_flavour="Linux64_GCC-6.4" \
-	gen_model_params
+	uart="1" set_expect_variable "skip_early_boot_msgs" "1"
+	uart="1" set_expect_variable "num_cpus" "4"
+
+	# Hold terminal_uart_aon (SCP terminal)
+	uart="2" file="hold_uart.exp" track_expect
+
 	set_run_env "ports_script" "$ci_root/model/morello-ports.awk"
 	set_run_env "num_uarts" "3"
 
-	uart="1" set_expect_variable ""skip_early_boot_msgs"" "1"
-	uart="1" set_expect_variable "num_cpus" "4"
+	model="morello" \
+		model_build="33" \
+		model_flavour="Linux64_GCC-6.4" \
+		model_version="0.11" \
+		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-neoverse_e1x1 b/run_config/fvp-neoverse_e1x1
index ab317b9..5e9331c 100644
--- a/run_config/fvp-neoverse_e1x1
+++ b/run_config/fvp-neoverse_e1x1
@@ -1,17 +1,19 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="neoverse_e1x1"
+generate_lava_job() {
+	local model="neoverse_e1x1"
+
+	uart="0" set_expect_variable "num_cpus" "2"
 
 	model="$model" \
-	cache_state_modelled="1" \
-	data_instance="cluster0.cpu0.thread0" \
+		cache_state_modelled="1" \
+		data_instance="cluster0.cpu0.thread0" \
 		gen_model_params
-	uart="0" set_expect_variable "num_cpus" "2"
+
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-neoverse_e1x2 b/run_config/fvp-neoverse_e1x2
index 580873f..ab09004 100644
--- a/run_config/fvp-neoverse_e1x2
+++ b/run_config/fvp-neoverse_e1x2
@@ -1,17 +1,19 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="neoverse_e1x2"
+generate_lava_job() {
+	local model="neoverse_e1x2"
+
+	uart="0" set_expect_variable "num_cpus" "4"
 
 	model="$model" \
-	cache_state_modelled="1" \
-	data_instance="cluster0.cpu0.thread0" \
+		cache_state_modelled="1" \
+		data_instance="cluster0.cpu0.thread0" \
 		gen_model_params
-	uart="0" set_expect_variable "num_cpus" "4"
+
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-neoverse_e1x4 b/run_config/fvp-neoverse_e1x4
index d8b725d..f647dd5 100644
--- a/run_config/fvp-neoverse_e1x4
+++ b/run_config/fvp-neoverse_e1x4
@@ -1,17 +1,19 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="neoverse_e1x4"
+generate_lava_job() {
+	local model="neoverse_e1x4"
+
+	uart="0" set_expect_variable "num_cpus" "8"
 
 	model="$model" \
-	cache_state_modelled="1" \
-	data_instance="cluster0.cpu0.thread0" \
+		cache_state_modelled="1" \
+		data_instance="cluster0.cpu0.thread0" \
 		gen_model_params
-	uart="0" set_expect_variable "num_cpus" "8"
+
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-neoverse_n1x4 b/run_config/fvp-neoverse_n1x4
index cc848ae..16c5fd9 100644
--- a/run_config/fvp-neoverse_n1x4
+++ b/run_config/fvp-neoverse_n1x4
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="neoverse_n1"
+generate_lava_job() {
+	local model="neoverse_n1"
 
-	model="$model" \
-	cache_state_modelled="0" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-neoverse_n2x4 b/run_config/fvp-neoverse_n2x4
index a435b07..09817e0 100644
--- a/run_config/fvp-neoverse_n2x4
+++ b/run_config/fvp-neoverse_n2x4
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="neoverse_n2"
+generate_lava_job() {
+	local model="neoverse_n2"
 
-	model="$model" \
-	cache_state_modelled="0" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-neoversev1x4 b/run_config/fvp-neoversev1x4
index 37c5b5a..aed7b6b 100644
--- a/run_config/fvp-neoversev1x4
+++ b/run_config/fvp-neoversev1x4
@@ -1,16 +1,15 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="neoverse-v1x4"
+generate_lava_job() {
+	local model="neoverse-v1x4"
 
-	model="$model" \
-	cache_state_modelled="0" \
-	gen_model_params
 	uart="0" set_expect_variable "num_cpus" "4"
+
+	model="$model" cache_state_modelled="0" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-rde1edge b/run_config/fvp-rde1edge
index 9cb8f34..716d907 100644
--- a/run_config/fvp-rde1edge
+++ b/run_config/fvp-rde1edge
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -10,19 +10,19 @@
 	url="$sgi_prebuilts/scp-ram.bin" fetch_file
 	url="$sgi_prebuilts/scp-rom.bin" fetch_file
 
-
 	archive_file "mcp-rom.bin"
 	archive_file "scp-ram.bin"
 	archive_file "scp-rom.bin"
 }
 
-post_fetch_tf_resource() {
-        local model="css-rde1edge"
+generate_lava_job() {
+	local model="css-rde1edge"
 
-	model="css-rde1edge" \
-	gen_model_params
+	uart="0" set_expect_variable "num_cpus" "32"
+
 	set_run_env "ports_script" "$ci_root/model/css-sgi575-ports.awk"
 	set_run_env "num_uarts" "2"
-	uart="0" set_expect_variable "num_cpus" "32"
+
+	model="css-rde1edge" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-rdn1edge b/run_config/fvp-rdn1edge
index 339c5f3..d7ee90c 100644
--- a/run_config/fvp-rdn1edge
+++ b/run_config/fvp-rdn1edge
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -23,16 +23,17 @@
 		url="$scp_mcp_prebuilts/rdn1e1-bl1.bin" saveas="scp_rom.bin" fetch_file
 		archive_file "scp_rom.bin"
 	fi
+}
+
+generate_lava_job() {
+	local model="css-rdn1edge"
 
 	# Hold terminal_uart_aon
 	uart="2" file="hold_uart.exp" track_expect
-}
 
-post_fetch_tf_resource() {
-        local model="css-rdn1edge"
-
-	model="css-rdn1edge" gen_model_params
 	set_run_env "ports_script" "$ci_root/model/css-sgi575-ports.awk"
 	set_run_env "num_uarts" "3"
+
+	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-rdn1edgex2 b/run_config/fvp-rdn1edgex2
index 74f2d10..1d5653f 100644
--- a/run_config/fvp-rdn1edgex2
+++ b/run_config/fvp-rdn1edgex2
@@ -19,12 +19,6 @@
 		url="$scp_mcp_prebuilts/rdn1e1-bl1.bin" saveas="scp_rom.bin" fetch_file
 		archive_file "scp_rom.bin"
 	fi
-
-	# Hold scp terminal_uart_aon on css0
-	uart="2" file="hold_uart.exp" track_expect
-
-	# Hold scp terminal_uart_aon on css1
-	uart="3" file="hold_uart.exp" track_expect
 }
 
 pre_tf_build() {
@@ -37,12 +31,20 @@
 	apply_tf_patch "css_rd_multichip_fvp/spinlock-send-explicit-event-after-store-release.patch"
 }
 
-post_fetch_tf_resource() {
-        local model="css-rdn1edgex2"
+generate_lava_job() {
+	local model="css-rdn1edgex2"
 
-	model="$model" gen_model_params
+	uart="1" set_expect_variable "num_cpus" "16"
+
+	# Hold scp terminal_uart_aon on css0
+	uart="2" file="hold_uart.exp" track_expect
+
+	# Hold scp terminal_uart_aon on css1
+	uart="3" file="hold_uart.exp" track_expect
+
 	set_run_env "ports_script" "$ci_root/model/css-rdinfra-ports.awk"
 	set_run_env "num_uarts" "4"
-	uart="1" set_expect_variable "num_cpus" "16"
+
+	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-rdv1 b/run_config/fvp-rdv1
index 915e7f4..c462303 100644
--- a/run_config/fvp-rdv1
+++ b/run_config/fvp-rdv1
@@ -23,17 +23,19 @@
 		url="$scp_mcp_prebuilts/rdv1-bl1.bin" saveas="scp_rom.bin" fetch_file
 		archive_file "scp_rom.bin"
 	fi
+}
+
+generate_lava_job() {
+	local model="css-rdv1"
+
+	uart="1" set_expect_variable "num_cpus" "16"
 
 	# Hold terminal_uart_aon
 	uart="2" file="hold_uart.exp" track_expect
-}
 
-post_fetch_tf_resource() {
-        local model="css-rdv1"
-
-	model="$model" gen_model_params
 	set_run_env "ports_script" "$ci_root/model/css-sgi575-ports.awk"
 	set_run_env "num_uarts" "3"
-	uart="1" set_expect_variable "num_cpus" "16"
+
+	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-sgi575 b/run_config/fvp-sgi575
index 8e04044..d308bf9 100644
--- a/run_config/fvp-sgi575
+++ b/run_config/fvp-sgi575
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -23,16 +23,17 @@
 		url="$scp_mcp_prebuilts/sgi575-bl1.bin" saveas="scp_rom.bin" fetch_file
 		archive_file "scp_rom.bin"
 	fi
+}
+
+generate_lava_job() {
+	local model="css-sgi575"
 
 	# Hold terminal_uart_aon
 	uart="2" file="hold_uart.exp" track_expect
-}
 
-post_fetch_tf_resource() {
-        local model="css-sgi575"
-
-	model="$model" gen_model_params
 	set_run_env "ports_script" "$ci_root/model/css-sgi575-ports.awk"
 	set_run_env "num_uarts" "3"
+
+	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-spm b/run_config/fvp-spm
index 53d735e..7f64b66 100644
--- a/run_config/fvp-spm
+++ b/run_config/fvp-spm
@@ -9,17 +9,15 @@
 	build_fip BL33="$archive/tftf.bin" BL32="$archive/secure_hafnium.bin"
 }
 
-fetch_tf_resource() {
-	# Expect scripts
-	uart="0" file="tftf.exp" track_expect
-	uart="2" file="spm-uart2.exp" track_expect
-
+generate_lava_job_template() {
 	payload_type="tftf" gen_fvp_yaml_template
-
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	uart="0" file="tftf.exp" track_expect
+	uart="2" file="spm-uart2.exp" track_expect
 
 	# SPM(reference implementation of S-EL2 firmware) has SMMUv3 driver
 	# enabled to help with stage-2 translation and virtualization of
@@ -27,10 +25,10 @@
 	# by configuring the appropriate parameters of the SMMUv3 AEM.
 
 	model="$model" \
-	arch_version="8.5" \
-	has_smmuv3_params="1" \
-	has_branch_target_exception="1" \
-	memory_tagging_support_level="2" \
+		arch_version="8.5" \
+		has_branch_target_exception="1" \
+		has_smmuv3_params="1" \
+		memory_tagging_support_level="2" \
 		gen_model_params
 
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-spm+romlib b/run_config/fvp-spm+romlib
index 22a62f6..b812936 100644
--- a/run_config/fvp-spm+romlib
+++ b/run_config/fvp-spm+romlib
@@ -10,17 +10,19 @@
 	build_fip BL33="$archive/tftf.bin" BL32="$archive/secure_hafnium.bin"
 }
 
-fetch_tf_resource() {
-	# Expect scripts
-	uart="0" file="tftf.exp" track_expect
-	uart="2" file="spm-uart2.exp" track_expect
-
-	payload_type="tftf" gen_fvp_yaml_template
-
+post_tf_archive() {
+	fvp_romlib_cleanup
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job_template() {
+	payload_type="tftf" gen_fvp_yaml_template
+}
+
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	uart="0" file="tftf.exp" track_expect
+	uart="2" file="spm-uart2.exp" track_expect
 
 	# SPM(reference implementation of S-EL2 firmware) has SMMUv3 driver
 	# enabled to help with stage-2 translation and virtualization of
@@ -28,15 +30,11 @@
 	# by configuring the appropriate parameters of the SMMUv3 AEM.
 
 	model="$model" \
-	arch_version="8.5" \
-	has_smmuv3_params="1" \
-	has_branch_target_exception="1" \
-	memory_tagging_support_level="2" \
+		arch_version="8.5" \
+		has_branch_target_exception="1" \
+		has_smmuv3_params="1" \
+		memory_tagging_support_level="2" \
 		gen_model_params
 
 	model="$model" gen_fvp_yaml
 }
-
-post_tf_archive() {
-	fvp_romlib_cleanup
-}
diff --git a/run_config/fvp-spm.48bit_pa b/run_config/fvp-spm.48bit_pa
index cacbaa3..2685157 100644
--- a/run_config/fvp-spm.48bit_pa
+++ b/run_config/fvp-spm.48bit_pa
@@ -9,16 +9,15 @@
 	build_fip BL33="$archive/tftf.bin" BL32="$archive/secure_hafnium.bin"
 }
 
-fetch_tf_resource() {
-	# Expect scripts
-	uart="0" file="tftf.exp" track_expect
-	uart="2" file="spm-uart2.exp" track_expect
-
+generate_lava_job_template() {
 	payload_type="tftf" gen_fvp_yaml_template
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	uart="0" file="tftf.exp" track_expect
+	uart="2" file="spm-uart2.exp" track_expect
 
 	# SPM(reference implementation of S-EL2 firmware) has SMMUv3 driver
 	# enabled to help with stage-2 translation and virtualization of
@@ -26,11 +25,11 @@
 	# by configuring the appropriate parameters of the SMMUv3 AEM.
 
 	model="$model" \
-	arch_version="8.5" \
-	has_smmuv3_params="1" \
-	has_branch_target_exception="1" \
-	memory_tagging_support_level="2" \
-	pa_size="48" \
+		arch_version="8.5" \
+		has_branch_target_exception="1" \
+		has_smmuv3_params="1" \
+		memory_tagging_support_level="2" \
+		pa_size="48" \
 		gen_model_params
 
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-spm.edk2 b/run_config/fvp-spm.edk2
index f2a9e6c..488e157 100644
--- a/run_config/fvp-spm.edk2
+++ b/run_config/fvp-spm.edk2
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2021 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -16,8 +16,7 @@
 	build_fip BL33="$archive/FVP_AARCH64_EFI.fd" BL32="$archive/STANDALONESMM.fd"
 }
 
-fetch_tf_resource() {
-	# Expect scripts
+generate_lava_job_template() {
 	uart="0" file="spm-edk2-uart0.exp" track_expect
 	uart="2" file="spm-edk2-uart2.exp" track_expect
 
diff --git a/run_config/fvp-spm.linux b/run_config/fvp-spm.linux
index 6910d4f..b79e48a 100644
--- a/run_config/fvp-spm.linux
+++ b/run_config/fvp-spm.linux
@@ -20,24 +20,25 @@
 fetch_tf_resource() {
 	url="$tfa_downloads/spm/07-29-2021/initrd.img" saveas="initrd.bin" fetch_file
 	archive_file "initrd.bin"
+}
 
-	# Expect scripts
-	uart="0" file="spm-linux-uart0.exp" track_expect
-	uart="2" file="spm-uart2.exp" track_expect
-
+generate_lava_job_template() {
 	payload_type="linux" gen_fvp_yaml_template
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	uart="0" file="spm-linux-uart0.exp" track_expect
+	uart="2" file="spm-uart2.exp" track_expect
 
 	model="$model" \
-	arch_version="8.5" \
-	has_branch_target_exception="1" \
-	kernel_addr=0x88000000 \
-	kernel_bin="$archive/hafnium.bin" \
-	has_smmuv3_params="1" \
-	memory_tagging_support_level="2" \
+		arch_version="8.5" \
+		has_branch_target_exception="1" \
+		has_smmuv3_params="1" \
+		kernel_addr="0x88000000" \
+		kernel_bin="$archive/hafnium.bin" \
+		memory_tagging_support_level="2" \
 		gen_model_params
 
 	model="$model" model_dtb="manifest.dtb" gen_fvp_yaml
diff --git a/run_config/fvp-spm.optee b/run_config/fvp-spm.optee
index 328800f..654ac5e 100644
--- a/run_config/fvp-spm.optee
+++ b/run_config/fvp-spm.optee
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020-2021, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -13,16 +13,15 @@
 	build_fip BL33="$archive/tftf.bin" BL32="$archive/spmc_sel1_optee_sel1.bin"
 }
 
-fetch_tf_resource() {
-	# Expect scripts
-	uart="0" file="tftf.exp" track_expect
-	uart="1" file="hold_uart.exp" track_expect
-
+generate_lava_job_template() {
 	payload_type="tftf" gen_fvp_yaml_template
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	uart="0" file="tftf.exp" track_expect
+	uart="1" file="hold_uart.exp" track_expect
 
 	model="$model" has_smmuv3_params="1" gen_model_params
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-spm.optee.sp b/run_config/fvp-spm.optee.sp
index 8078b68..4fff0ab 100644
--- a/run_config/fvp-spm.optee.sp
+++ b/run_config/fvp-spm.optee.sp
@@ -11,34 +11,33 @@
 	archive_file "spmc_sel2_optee_sel1.bin"
 	cp "${archive}/spmc_sel2_optee_sel1.bin" "${tf_root}/build/fvp/${bin_mode}"
 
-cat <<EOF > "${tf_root}/build/fvp/${bin_mode}/optee_sp_layout.json"
-{
-	"op-tee" : {
-		"image": "spmc_sel2_optee_sel1.bin",
-		"pm": "${tf_root}/plat/arm/board/fvp/fdts/optee_sp_manifest.dts"
-	}
-}
-EOF
+	cat <<-EOF >"${tf_root}/build/fvp/${bin_mode}/optee_sp_layout.json"
+		{
+			"op-tee" : {
+				"image": "spmc_sel2_optee_sel1.bin",
+				"pm": "${tf_root}/plat/arm/board/fvp/fdts/optee_sp_manifest.dts"
+			}
+		}
+	EOF
 
 	build_fip BL33="$archive/tftf.bin" BL32="$archive/secure_hafnium.bin"
 }
 
-fetch_tf_resource() {
-	# Expect scripts
-	uart="0" file="tftf.exp" track_expect
-	uart="1" file="spm-optee-sp-uart1.exp" track_expect
-
+generate_lava_job_template() {
 	payload_type="tftf" gen_fvp_yaml_template
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	uart="0" file="tftf.exp" track_expect
+	uart="1" file="spm-optee-sp-uart1.exp" track_expect
 
 	model="$model" \
-	arch_version="8.5" \
-	has_smmuv3_params="1" \
-	has_branch_target_exception="1" \
-	memory_tagging_support_level="2" \
+		arch_version="8.5" \
+		has_branch_target_exception="1" \
+		has_smmuv3_params="1" \
+		memory_tagging_support_level="2" \
 		gen_model_params
 
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-spm.rstbl31 b/run_config/fvp-spm.rstbl31
index 64130f1..674c765 100644
--- a/run_config/fvp-spm.rstbl31
+++ b/run_config/fvp-spm.rstbl31
@@ -17,7 +17,7 @@
 	# but dummy BL33 and BL32.
 	#
 	local dummy_file="$(mktempfile)"
-	echo "hello world" > "$dummy_file"
+	echo "hello world" >"$dummy_file"
 
 	build_fip BL33="$dummy_file" BL32="$dummy_file"
 
@@ -40,31 +40,32 @@
 
 	archive_file "initrd.bin"
 	archive_file "dtb.bin"
+}
 
-	# Expect scripts
-	uart="0" file="spm-linux-uart0.exp" track_expect
-	uart="2" file="spm-uart2.exp" track_expect
-
+generate_lava_job_template() {
 	payload_type="linux" gen_fvp_yaml_template
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	uart="0" file="spm-linux-uart0.exp" track_expect
+	uart="2" file="spm-uart2.exp" track_expect
 
 	model="$model" \
-	arch_version="8.5" \
-	has_branch_target_exception="1" \
-	reset_to_bl31="1" \
-	kernel_addr=0x88000000 \
-	kernel_bin="$archive/hafnium.bin" \
-	spmc_manifest="fvp_spmc_manifest.dtb" \
-	spm_bin="$archive/secure_hafnium.bin" \
-	sp1_pkg="cactus-primary.pkg" \
-	sp2_pkg="cactus-secondary.pkg" \
-	sp3_pkg="cactus-tertiary.pkg" \
-	sp4_pkg="ivy.pkg" \
-	has_smmuv3_params="1" \
-	memory_tagging_support_level="2" \
+		arch_version="8.5" \
+		has_branch_target_exception="1" \
+		has_smmuv3_params="1" \
+		kernel_addr="0x88000000" \
+		kernel_bin="$archive/hafnium.bin" \
+		memory_tagging_support_level="2" \
+		reset_to_bl31="1" \
+		sp1_pkg="cactus-primary.pkg" \
+		sp2_pkg="cactus-secondary.pkg" \
+		sp3_pkg="cactus-tertiary.pkg" \
+		sp4_pkg="ivy.pkg" \
+		spm_bin="$archive/secure_hafnium.bin" \
+		spmc_manifest="fvp_spmc_manifest.dtb" \
 		gen_model_params
 
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-spm.sve+amu b/run_config/fvp-spm.sve+amu
index bdfc61b..d51e80f 100644
--- a/run_config/fvp-spm.sve+amu
+++ b/run_config/fvp-spm.sve+amu
@@ -9,17 +9,15 @@
 	build_fip BL33="$archive/tftf.bin" BL32="$archive/secure_hafnium.bin"
 }
 
-fetch_tf_resource() {
-	# Expect scripts
-	uart="0" file="tftf.exp" track_expect
-	uart="2" file="spm-uart2.exp" track_expect
-
+generate_lava_job_template() {
 	payload_type="tftf" gen_fvp_yaml_template
-
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
+generate_lava_job() {
+	local model="base-aemv8a"
+
+	uart="0" file="tftf.exp" track_expect
+	uart="2" file="spm-uart2.exp" track_expect
 
 	# SPM(reference implementation of S-EL2 firmware) has SMMUv3 driver
 	# enabled to help with stage-2 translation and virtualization of
@@ -27,12 +25,12 @@
 	# by confuguring the appropriate parameters of the SMMUv3 AEM.
 
 	model="$model" \
-	amu_present="1" \
-	sve_plugin=1 \
-	arch_version="8.5" \
-	has_smmuv3_params="1" \
-	has_branch_target_exception="1" \
-	memory_tagging_support_level="2" \
+		amu_present="1" \
+		arch_version="8.5" \
+		has_branch_target_exception="1" \
+		has_smmuv3_params="1" \
+		memory_tagging_support_level="2" \
+		sve_plugin="1" \
 		gen_model_params
 
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-tc0 b/run_config/fvp-tc0
index 5932f25..b2c0d5b 100644
--- a/run_config/fvp-tc0
+++ b/run_config/fvp-tc0
@@ -1,16 +1,18 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2021, Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="tc0"
+generate_lava_job() {
+	local model="tc0"
 
-	model="$model" gen_model_params
+	uart="1" set_expect_variable "num_cpus" "8"
+
 	set_run_env "ports_script" "$ci_root/model/tc-ports.awk"
 	set_run_env "num_uarts" "2"
-	uart="1" set_expect_variable "num_cpus" "8"
+
+	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-tc0.spm.tftf b/run_config/fvp-tc0.spm.tftf
index 7fa1b06..59b37c2 100644
--- a/run_config/fvp-tc0.spm.tftf
+++ b/run_config/fvp-tc0.spm.tftf
@@ -15,12 +15,6 @@
 }
 
 fetch_tf_resource() {
-	# Expect scripts
-	uart="0" set_payload_uart="1" file="tftf-non-primary.exp" track_expect
-	uart="1" set_primary="1" file="spm-cactus-sp-uart1.exp" track_expect
-
-	payload_type="tftf" gen_fvp_yaml_template
-
 	# Use SCP binary from SCP build if it exists, or fetch pre-built ones.
 	if [ ! -f "$archive/scp_rom.bin" ]; then
 		# Pick the appropriate binary based on target platform variant
@@ -29,15 +23,21 @@
 	fi
 }
 
-post_fetch_tf_resource() {
-        local model="tc0"
+generate_lava_job_template() {
+	payload_type="tftf" gen_fvp_yaml_template
+}
 
-	model="$model" \
-	memory_tagging_support_level="2" \
-		gen_model_params
+generate_lava_job() {
+	local model="tc0"
+
+	uart="0" set_payload_uart="1" file="tftf-non-primary.exp" track_expect
+
+	uart="1" set_expect_variable "num_cpus" "8"
+	uart="1" set_primary="1" file="spm-cactus-sp-uart1.exp" track_expect
 
 	set_run_env "ports_script" "$ci_root/model/tc-ports.awk"
 	set_run_env "num_uarts" "2"
-	uart="1" set_expect_variable "num_cpus" "8"
+
+	model="$model" memory_tagging_support_level="2" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-tc1 b/run_config/fvp-tc1
index 8f96eb6..f945795 100644
--- a/run_config/fvp-tc1
+++ b/run_config/fvp-tc1
@@ -1,16 +1,18 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021, Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
-        local model="tc1"
+generate_lava_job() {
+	local model="tc1"
 
-	model="$model" gen_model_params
+	uart="1" set_expect_variable "num_cpus" "8"
+
 	set_run_env "ports_script" "$ci_root/model/tc-ports.awk"
 	set_run_env "num_uarts" "2"
-	uart="1" set_expect_variable "num_cpus" "8"
+
+	model="$model" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-tc2 b/run_config/fvp-tc2
index 4a8a81b..297ad0f 100644
--- a/run_config/fvp-tc2
+++ b/run_config/fvp-tc2
@@ -5,15 +5,14 @@
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-post_fetch_tf_resource() {
+generate_lava_job() {
 	local model="tc2"
 
-	model="tc2" \
-	model_version="11.18" \
-	model_build="17" \
-	gen_model_params
+	uart="1" set_expect_variable "num_cpus" "8"
+
 	set_run_env "ports_script" "$ci_root/model/tc-ports.awk"
 	set_run_env "num_uarts" "3"
-	uart="1" set_expect_variable "num_cpus" "8"
+
+	model="$model" model_build="17" model_version="11.18" gen_model_params
 	model="$model" gen_fvp_yaml
 }
diff --git a/run_config/fvp-tftf b/run_config/fvp-tftf
index 17bd076..9ab8584 100644
--- a/run_config/fvp-tftf
+++ b/run_config/fvp-tftf
@@ -1,11 +1,11 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2022 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-fetch_tf_resource() {
+generate_lava_job_template() {
 	uart="0" timeout="1200" file="tftf.exp" track_expect
 	uart="1" file="hold_uart.exp" track_expect
 
diff --git a/run_config/fvp-tftf.aarch32 b/run_config/fvp-tftf.aarch32
index 56baa06..66f5699 100644
--- a/run_config/fvp-tftf.aarch32
+++ b/run_config/fvp-tftf.aarch32
@@ -1,11 +1,11 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-fetch_tf_resource() {
+generate_lava_job_template() {
 	uart="0" timeout="800" file="tftf-aarch32.exp" track_expect
 	uart="1" file="hold_uart.exp" track_expect
 
diff --git a/run_config/fvp-tftf.aarch32+fwu b/run_config/fvp-tftf.aarch32+fwu
index 891985a..d5be9db 100644
--- a/run_config/fvp-tftf.aarch32+fwu
+++ b/run_config/fvp-tftf.aarch32+fwu
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2020, Arm Limited. All rights reserved.
+# Copyright (c) 2020-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -10,7 +10,6 @@
 	targets="tftf ns_bl1u ns_bl2u" set_tftf_build_targets
 }
 
-
 # Perform FWU steps after all build products have been archived.
 post_tf_build() {
 	fip_targets="fip fwu_fip" build_fip \
@@ -23,7 +22,7 @@
 	cp "$archive/fip.bin" "$archive/backup_fip.bin"
 }
 
-fetch_tf_resource() {
+generate_lava_job_template() {
 	uart="0" timeout="900" file="tftf-aarch32.exp" track_expect
 
 	payload_type="tftf" gen_fvp_yaml_template
diff --git a/run_config/fvp-tftf.cactus_mm b/run_config/fvp-tftf.cactus_mm
index fd0b529..42e7880 100644
--- a/run_config/fvp-tftf.cactus_mm
+++ b/run_config/fvp-tftf.cactus_mm
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -15,11 +15,12 @@
 	mv "$archive/cactus_mm.bin" "$archive/bl32.bin"
 }
 
-fetch_tf_resource() {
-	set_run_env "num_uarts" "3"
+generate_lava_job_template() {
 	uart="0" file="tftf.exp" track_expect
 	uart="1" file="hold_uart.exp" track_expect
 	uart="2" file="hold_uart.exp" track_expect
 
+	set_run_env "num_uarts" "3"
+
 	payload_type="tftf" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-tftf.fault b/run_config/fvp-tftf.fault
index d18ad08..4301479 100644
--- a/run_config/fvp-tftf.fault
+++ b/run_config/fvp-tftf.fault
@@ -1,11 +1,11 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-fetch_tf_resource() {
+generate_lava_job_template() {
 	# Hold UART0 but expect fault messages in UART1
 	uart="0" file="hold_uart.exp" track_expect
 	uart="1" set_primary="1" file="tftf_fault.exp" track_expect
diff --git a/run_config/fvp-tftf.fwu b/run_config/fvp-tftf.fwu
index 43728d6..502c227 100644
--- a/run_config/fvp-tftf.fwu
+++ b/run_config/fvp-tftf.fwu
@@ -1,6 +1,6 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2019-2020 Arm Limited. All rights reserved.
+# Copyright (c) 2019-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
@@ -10,7 +10,6 @@
 	targets="tftf ns_bl1u ns_bl2u" set_tftf_build_targets
 }
 
-
 # Perform FWU steps after all build products have been archived.
 post_tf_build() {
 	fip_targets="fip fwu_fip" build_fip \
@@ -23,7 +22,7 @@
 	cp "$archive/fip.bin" "$archive/backup_fip.bin"
 }
 
-fetch_tf_resource() {
+generate_lava_job_template() {
 	uart="0" timeout="900" file="tftf.exp" track_expect
 
 	payload_type="tftf" gen_fvp_yaml_template
diff --git a/run_config/fvp-tftf.gpt b/run_config/fvp-tftf.gpt
index 1225062..9b28815 100644
--- a/run_config/fvp-tftf.gpt
+++ b/run_config/fvp-tftf.gpt
@@ -1,21 +1,21 @@
 #!/usr/bin/env bash
 #
-# Copyright (c) 2021 Arm Limited. All rights reserved.
+# Copyright (c) 2021-2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-fetch_tf_resource() {
-        uart="0" file="tftf.exp" track_expect
-        uart="1" file="hold_uart.exp" track_expect
-
-        payload_type="tftf" gen_fvp_yaml_template
-}
-
 post_tf_build() {
-        build_fip BL33="$archive/tftf.bin"
+	build_fip BL33="$archive/tftf.bin"
 }
 
 post_tf_archive() {
-        gen_gpt_bin "$archive/fip.bin"
+	gen_gpt_bin "$archive/fip.bin"
+}
+
+generate_lava_job_template() {
+	uart="0" file="tftf.exp" track_expect
+	uart="1" file="hold_uart.exp" track_expect
+
+	payload_type="tftf" gen_fvp_yaml_template
 }
diff --git a/run_config/fvp-tftf.rme b/run_config/fvp-tftf.rme
index 48e3921..90b8e97 100644
--- a/run_config/fvp-tftf.rme
+++ b/run_config/fvp-tftf.rme
@@ -5,7 +5,13 @@
 # SPDX-License-Identifier: BSD-3-Clause
 #
 
-fetch_tf_resource() {
+generate_lava_job_template() {
+	payload_type="tftf" gen_fvp_yaml_template
+}
+
+generate_lava_job() {
+	local model="base-aemv8a"
+
 	# RME systems go BL1->BL2->BL31 so we must set this variable for expect
 	# scripts to work properly and not hang up waiting for BL1->BL31.
 	uart="0" set_expect_variable "skip_early_boot_msgs" "1"
@@ -18,20 +24,14 @@
 	uart="2" file="hold_uart.exp" track_expect
 	uart="3" file="hold_uart.exp" track_expect
 
-	payload_type="tftf" gen_fvp_yaml_template
-}
-
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-
 	model="$model" \
-	arch_version="8.6" \
-	has_branch_target_exception="1" \
-	restriction_on_speculative_execution="2" \
-	amu_present="1" \
-	has_rme="1" \
-	has_smmuv3_params="1" \
-	memory_tagging_support_level="2" \
+		amu_present="1" \
+		arch_version="8.6" \
+		has_branch_target_exception="1" \
+		has_rme="1" \
+		has_smmuv3_params="1" \
+		memory_tagging_support_level="2" \
+		restriction_on_speculative_execution="2" \
 		gen_model_params
 
 	model="$model" gen_fvp_yaml
diff --git a/run_config/fvp-tsp.rootfs b/run_config/fvp-tsp.rootfs
index e09ca7a..ae50d6e 100644
--- a/run_config/fvp-tsp.rootfs
+++ b/run_config/fvp-tsp.rootfs
@@ -1,31 +1,31 @@
+#!/usr/bin/env bash
 #
 # Copyright (c) 2022, Arm Limited. All rights reserved.
 #
 # SPDX-License-Identifier: BSD-3-Clause
- 
-#!/usr/bin/env bash
+#
 
 post_tf_build() {
-        # Fetch EDK2 and pre-built partition files
-        url="$tfa_downloads/spm-el3/06-15-22/normal_world_multi.dts" saveas="normal_world_multi.dts" fetch_file
-        rootfs_url="$tfa_downloads/spm-el3/06-15-22/boot-fat.uefi.img" saveas="boot-fat.uefi.img" get_rootfs
-        url="$tfa_downloads/spm-el3/06-15-22/FVP_AARCH64_EFI.fd" saveas="FVP_AARCH64_EFI.fd" fetch_file
-        archive_file "normal_world_multi.dts"
-        archive_file "FVP_AARCH64_EFI.fd"
-        build_fip BL33="$archive/FVP_AARCH64_EFI.fd" NT_FW_CONFIG="$archive/normal_world_multi.dts"
+	# Fetch EDK2 and pre-built partition files
+	url="$tfa_downloads/spm-el3/06-15-22/normal_world_multi.dts" saveas="normal_world_multi.dts" fetch_file
+	rootfs_url="$tfa_downloads/spm-el3/06-15-22/boot-fat.uefi.img" saveas="boot-fat.uefi.img" get_rootfs
+	url="$tfa_downloads/spm-el3/06-15-22/FVP_AARCH64_EFI.fd" saveas="FVP_AARCH64_EFI.fd" fetch_file
+	archive_file "normal_world_multi.dts"
+	archive_file "FVP_AARCH64_EFI.fd"
+	build_fip BL33="$archive/FVP_AARCH64_EFI.fd" NT_FW_CONFIG="$archive/normal_world_multi.dts"
 }
 
-fetch_tf_resource() {
-        # Expect scripts
-        uart="0" timeout="800" file="ffa_test_driver.exp" track_expect
-        uart="2" timeout="800" file="tsp_el3spmc.exp" track_expect
-        uart="1" timeout="800" file="hold_uart.exp" track_expect
-        payload_type="linux" gen_fvp_yaml_template
+generate_lava_job_template() {
+	payload_type="linux" gen_fvp_yaml_template
 }
 
-post_fetch_tf_resource() {
-        local model="base-aemv8a"
-        model="$model"  arch_version="8.4" gen_model_params
-        model="$model" gen_fvp_yaml
-}
+generate_lava_job() {
+	local model="base-aemv8a"
 
+	uart="0" timeout="800" file="ffa_test_driver.exp" track_expect
+	uart="2" timeout="800" file="tsp_el3spmc.exp" track_expect
+	uart="1" timeout="800" file="hold_uart.exp" track_expect
+
+	model="$model" arch_version="8.4" gen_model_params
+	model="$model" gen_fvp_yaml
+}
diff --git a/script/build_package.sh b/script/build_package.sh
index 7a4b3e7..214a875 100755
--- a/script/build_package.sh
+++ b/script/build_package.sh
@@ -1461,6 +1461,10 @@
 		call_hook fetch_tf_resource
 		call_hook post_fetch_tf_resource
 
+		# Generate LAVA job files if necessary
+		call_hook generate_lava_job_template
+		call_hook generate_lava_job
+
 		# Clear any local changes made by applied patches
 		undo_tf_patches