feat(gpt): add ci support to test using backup-gpt

Current GPT test uses the primary GPT header, so corrupt primary GPT
header at second LBA after the MBR. This would force it to use the
backup-gpt header at last LBA.

Also additional changes done to handle backup_gpt header to TF-A
causes BL31 to run out of space so add FVP_TRUSTED_SRAM_SIZE=384
to gpt builds.

Change-Id: I6660a5e3c533f58738272302c8008c88dd82b8a6
Signed-off-by: Govindraj Raja <govindraj.raja@arm.com>
diff --git a/run_config/fvp-tftf.backup_gpt b/run_config/fvp-tftf.backup_gpt
new file mode 100644
index 0000000..a920668
--- /dev/null
+++ b/run_config/fvp-tftf.backup_gpt
@@ -0,0 +1,24 @@
+#!/usr/bin/env bash
+#
+# Copyright (c) 2023, Arm Limited. All rights reserved.
+#
+# SPDX-License-Identifier: BSD-3-Clause
+#
+
+post_tf_build() {
+	build_fip BL33="$archive/tftf.bin"
+}
+
+post_tf_archive() {
+	gen_gpt_bin "$archive/fip.bin"
+
+	# Corrupt primary GPT header to force TF-A to use the backup one
+	corrupt_gpt_bin "$archive/fip_gpt.bin"
+}
+
+generate_lava_job_template() {
+	uart="0" file="backup_gpt.exp" track_expect
+	uart="1" file="hold_uart.exp" track_expect
+
+	payload_type="tftf" gen_yaml_template
+}