refactor: re-use run config fragments for TC platform variants

Several platforms have multiple variants, yet, they share most of the
software binaries and hence can utilize common run fragments. This
removes the need to maintain run fragments on per-variant basis.

We do this by introducing an environment variable `plat_variant` that
is populated from build parameter `TARGET_PLATFORM`

Signed-off-by: Madhukar Pappireddy <madhukar.pappireddy@arm.com>
Change-Id: I4218942b33dd32440a1ce9f7e78627bbe6710a69
diff --git a/run_config/fvp-linux.tc b/run_config/fvp-linux.tc
new file mode 100644
index 0000000..206a248
--- /dev/null
+++ b/run_config/fvp-linux.tc
@@ -0,0 +1,23 @@
+#!/usr/bin/env bash
+#
+# Copyright (c) 2019-2021 Arm Limited. All rights reserved.
+#
+# SPDX-License-Identifier: BSD-3-Clause
+#
+
+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_romfw.bin" ]; then
+		# Pick the appropriate binary based on target platform variant
+		url="$scp_prebuilts/tc$plat_variant/scp_romfw.bin" fetch_file
+		archive_file "scp_romfw.bin"
+	fi
+
+	# Hold scp terminal_s0
+	uart="0" file="hold_uart.exp" track_expect
+}