Build: Remove musca_s1 from config due to deprecation

It appears only on Build related configurations as the board
itself is not enabled in LAVA.

Signed-off-by: Antonio de Angelis <antonio.deangelis@arm.com>
Change-Id: I02d9a5c07b1fbfd08692caa97588c6defc353f5e
diff --git a/build_helper/build_helper_config_maps.py b/build_helper/build_helper_config_maps.py
index 573b5b7..bcce37c 100644
--- a/build_helper/build_helper_config_maps.py
+++ b/build_helper/build_helper_config_maps.py
@@ -21,7 +21,6 @@
     "arm/mps3/corstone300/an547"         : "CS300_AN547",
     "arm/mps3/corstone300/an552"         : "CS300_AN552",
     "arm/musca_b1"                       : "MUSCA_B1",
-    "arm/musca_s1"                       : "MUSCA_S1",
     "arm/corstone1000"                   : "corstone1000",
     "arm/mps4/corstone315"               : "corstone315",
     "arm/mps3/corstone310/fvp"           : "corstone310",
diff --git a/build_helper/build_helper_configs.py b/build_helper/build_helper_configs.py
index c310dbd..71b0256 100755
--- a/build_helper/build_helper_configs.py
+++ b/build_helper/build_helper_configs.py
@@ -99,18 +99,55 @@
                                      "-Binary -offset 0xA020000 "
                                      "-fill 0xFF 0xA020000 0xA200000 "
                                      "-o %(ci_build_root_dir)s/"
-                                     "spe/bin/tfm.hex -Intel"),
-                   "arm/musca_s1": ("srec_cat "
-                                    "%(ci_build_root_dir)s/spe/bin/"
-                                    "bl2.bin "
-                                    "-Binary -offset 0xA000000 "
-                                    "-fill 0xFF 0xA000000 0xA020000 "
-                                    "%(ci_build_root_dir)s/nspe/"
-                                    "tfm_s_ns_signed.bin "
-                                    "-Binary -offset 0xA020000 "
-                                    "-fill 0xFF 0xA020000 0xA200000 "
-                                    "-o %(ci_build_root_dir)s/"
-                                    "spe/bin/tfm.hex -Intel"),
+                                     "spe/bin/tfm.hex -Intel;"
+                                     "fi;"),
+                    "arm/rse/tc/tc3": ("if [ -f \"%(ci_build_root_dir)s/spe/bin/rse_bl1_tests.bin\" ]; then "
+                                   "srec_cat "
+                                   "%(ci_build_root_dir)s/spe/bin/bl1_1.bin -Binary -offset 0x0 "
+                                   "%(ci_build_root_dir)s/spe/bin/rse_bl1_tests.bin -Binary -offset 0x10000 "
+                                   "%(ci_build_root_dir)s/spe/bin/rom_dma_ics.bin -Binary -offset 0x1F000 "
+                                   "-o %(ci_build_root_dir)s/spe/bin/rom.bin -Binary;"
+                                   "else "
+                                   "srec_cat "
+                                   "%(ci_build_root_dir)s/spe/bin/bl1_1.bin -Binary -offset 0x0 "
+                                   "%(ci_build_root_dir)s/spe/bin/rom_dma_ics.bin -Binary -offset 0x1F000 "
+                                   "-o %(ci_build_root_dir)s/spe/bin/rom.bin -Binary;"
+                                   "fi;"
+                                   "curl --fail --no-progress-meter --connect-timeout 10 --retry 6 -LS -o fiptool https://downloads.trustedfirmware.org/tf-m/rse/tc/tc3/fiptool;"
+                                   "chmod 755 fiptool;"
+                                   "curl --fail --no-progress-meter --connect-timeout 10 --retry 6 -LS -o fip.bin https://downloads.trustedfirmware.org/tf-m/rse/tc/tc3/fip.bin;"
+                                   "./fiptool update "
+                                   "--align 8192 --rse-bl2 %(ci_build_root_dir)s/spe/bin/bl2_signed.bin "
+                                   "--align 8192 --rse-s %(ci_build_root_dir)s/spe/bin/tfm_s_encrypted.bin "
+                                   "--align 8192 --rse-ns %(ci_build_root_dir)s/nspe/bin/tfm_ns_encrypted.bin "
+                                   "--align 8192 --rse-sic-tables-s %(ci_build_root_dir)s/spe/bin/tfm_s_sic_tables_signed.bin "
+                                   "--align 8192 --rse-sic-tables-ns %(ci_build_root_dir)s/nspe/bin/tfm_ns_sic_tables_signed.bin "
+                                   "--out %(ci_build_root_dir)s/spe/bin/host_flash.bin "
+                                   "fip.bin"),
+                    "arm/rse/tc/tc4": ("if [ -f \"%(ci_build_root_dir)s/spe/bin/rse_bl1_tests.bin\" ]; then "
+                                   "srec_cat "
+                                   "%(ci_build_root_dir)s/spe/bin/bl1_1.bin -Binary -offset 0x0 "
+                                   "%(ci_build_root_dir)s/spe/bin/rse_bl1_tests.bin -Binary -offset 0x18000 "
+                                   "%(ci_build_root_dir)s/spe/bin/rom_dma_ics.bin -Binary -offset 0x1F000 "
+                                   "-o %(ci_build_root_dir)s/spe/bin/rom.bin -Binary;"
+                                   "else "
+                                   "srec_cat "
+                                   "%(ci_build_root_dir)s/spe/bin/bl1_1.bin -Binary -offset 0x0 "
+                                   "%(ci_build_root_dir)s/spe/bin/rom_dma_ics.bin -Binary -offset 0x1F000 "
+                                   "-o %(ci_build_root_dir)s/spe/bin/rom.bin -Binary;"
+                                   "fi;"
+                                   # fiptool in tc3 directory also compatible with tc4 fip.bin
+                                   "curl --fail --no-progress-meter --connect-timeout 10 --retry 6 -LS -o fiptool https://downloads.trustedfirmware.org/tf-m/rse/tc/tc3/fiptool;"
+                                   "chmod 755 fiptool;"
+                                   "curl --fail --no-progress-meter --connect-timeout 10 --retry 6 -LS -o fip.bin https://downloads.trustedfirmware.org/tf-m/rse/tc/tc4/4806a3a08/fip.bin;"
+                                   "./fiptool update "
+                                   "--align 8192 --rse-bl2 %(ci_build_root_dir)s/spe/bin/bl2_signed.bin "
+                                   "--align 8192 --rse-s %(ci_build_root_dir)s/spe/bin/tfm_s_encrypted.bin "
+                                   "--align 8192 --rse-ns %(ci_build_root_dir)s/nspe/bin/tfm_ns_encrypted.bin "
+                                   "--align 8192 --rse-sic-tables-s %(ci_build_root_dir)s/spe/bin/tfm_s_sic_tables_signed.bin "
+                                   "--align 8192 --rse-sic-tables-ns %(ci_build_root_dir)s/nspe/bin/tfm_ns_sic_tables_signed.bin "
+                                   "--out %(ci_build_root_dir)s/spe/bin/host_flash.bin "
+                                   "fip.bin"),
                    "stm/stm32l562e_dk": ("echo 'STM32L562E-DK board post process';"
                                           "%(ci_build_root_dir)s/spe/api_ns/postbuild.sh;"
                                           "pushd %(ci_build_root_dir)s/spe/api_ns;"
@@ -195,37 +232,35 @@
                            "%(ci_build_root_dir)s/nspe/"
                            "tfm_ns.bin"],
                            "arm/musca_b1": [
-                           "%(ci_build_root_dir)s/tfm.hex",
-                           "%(ci_build_root_dir)s/spe/bin/"
-                           "bl2.bin",
-                           "%(ci_build_root_dir)s/spe/bin/"
-                           "tfm_sign.bin"],
-                           "arm/musca_s1": [
-                           "%(ci_build_root_dir)s/tfm.hex",
-                           "%(ci_build_root_dir)s/spe/bin/"
-                           "bl2.bin",
-                           "%(ci_build_root_dir)s/spe/bin/"
-                           "tfm_sign.bin"]
+                               "%(ci_build_root_dir)s/tfm.hex",
+                               "%(ci_build_root_dir)s/spe/bin/"
+                               "bl2.bin",
+                               "%(ci_build_root_dir)s/spe/bin/"
+                               "tfm_sign.bin"],
+                           "arm/rse/tc/tc3": [
+                               "%(ci_build_root_dir)s/spe/bin/rom.bin",
+                               "%(ci_build_root_dir)s/spe/bin/provisioning/combined_provisioning_message.bin",
+                               "%(ci_build_root_dir)s/spe/bin/host_flash.bin"],
+                           "arm/rse/tc/tc4": [
+                               "%(ci_build_root_dir)s/spe/bin/rom.bin",
+                               "%(ci_build_root_dir)s/spe/bin/provisioning/combined_provisioning_message.bin",
+                               "%(ci_build_root_dir)s/spe/bin/host_flash.bin"]
                            }
 }
 
 # List of all build configs that are impossible under all circumstances
 _common_tfm_invalid_configs = [
-    # LR_CODE size exceeds limit on MUSCA_B1 & MUSCA_S1 with regression tests in Debug mode built with ARMCLANG
+    # LR_CODE size exceeds limit on MUSCA_B1 with regression tests in Debug mode built with ARMCLANG
     ("arm/musca_b1", "ARMCLANG_6_21", "*", "RegBL2, RegS, RegNS", "OFF", "Debug", "*", "", "*"),
-    ("arm/musca_s1", "ARMCLANG_6_21", "*", "RegBL2, RegS, RegNS", "OFF", "Debug", "*", "", "*"),
     # Load range overlap on Musca for IPC Debug type: T895
     ("arm/musca_b1", "ARMCLANG_6_21", "*", "*", "IPC", "Debug", "*", "*", "*"),
-    ("arm/musca_s1", "ARMCLANG_6_21", "*", "*", "IPC", "Debug", "*", "*", "*"),
     # FF does not support L3
     ("*", "*", "3", "*", "IPC", "*", "*", "*", "*"),
     # Musca requires BL2
     ("arm/musca_b1", "*", "*", "*", "*", "*", False, "*", "*"),
-    ("arm/musca_s1", "*", "*", "*", "*", "*", False, "*", "*"),
     # Only AN521 and MUSCA_B1 support Isolation Level 3
     ("arm/mps2/an519", "*", "3", "*", "*", "*", "*", "*", "*"),
     ("arm/mps3/an524", "*", "3", "*", "*", "*", "*", "*", "*"),
-    ("arm/musca_s1", "*", "3", "*", "*", "*", "*", "*", "*"),
     ]
 
 # Configure build manager to build several combinations
@@ -307,20 +342,8 @@
                     # MUSCA_B1_GCC_1_RegBL2_RegS_RegNS_Minsizerel_BL2
                     ("arm/musca_b1", "GCC_10_3", "1",
                      "RegBL2, RegS, RegNS", "OFF", "Minsizerel", True, "", ""),
-                    # MUSCA_S1_ARMCLANG_2_RegBL2_RegS_RegNS_Release_BL2
-                    ("arm/musca_s1", "ARMCLANG_6_21", "2",
-                     "RegBL2, RegS, RegNS", "OFF", "Release", True, "", ""),
-                    # MUSCA_S1_GCC_1_RegBL2_RegS_RegNS_Debug_BL2
-                    ("arm/musca_s1", "GCC_10_3", "1",
-                     "RegBL2, RegS, RegNS", "OFF", "Debug", True, "", ""),
-                    # MUSCA_S1_GCC_2_RegBL2_RegS_RegNS_Release_BL2
-                    ("arm/musca_s1", "GCC_10_3", "2",
-                     "RegBL2, RegS, RegNS", "OFF", "Release", True, "", ""),
-                    # MUSCA_S1_GCC_1_RegBL2_RegS_RegNS_Debug_BL2
-                    ("arm/musca_s1", "GCC_10_3", "1",
-                     "RegBL2, RegS, RegNS", "OFF", "Debug", True, "", ""),
-                    # MUSCA_S1_GCC_1_RegBL2_RegS_RegNS_Release_BL2_CC_DRIVER_PSA
-                    ("arm/musca_s1", "GCC_10_3", "1",
+                    # MUSCA_B1_GCC_1_RegBL2_RegS_RegNS_Release_BL2_CC_DRIVER_PSA
+                    ("arm/musca_b1", "GCC_13_2", "1",
                      "RegBL2, RegS, RegNS", "OFF", "Release", True, "", "CC_DRIVER_PSA"),
                     # RSE_TC_GCC_2_Release_BL2_PSOFF
                     ("arm/rse/tc", "GCC_10_3", "2",
@@ -364,7 +387,6 @@
                "tfm_platform":      ["arm/mps2/an519",
                                      "arm/mps2/an521",
                                      "arm/mps3/an524",
-                                     "arm/musca_s1",
                                      "arm/musca_b1"],
                 "compiler":         ["GCC_10_3", "ARMCLANG_6_21"],
                 "isolation_level":  ["1", "2", "3"],
@@ -384,9 +406,8 @@
                 "tfm_platform":     ["arm/mps2/an519",
                                      "arm/mps2/an521",
                                      "arm/mps3/an524",
-                                     "arm/musca_b1",
-                                     "arm/musca_s1"],
-                "compiler":         ["GCC_10_3", "ARMCLANG_6_21"],
+                                     "arm/musca_b1"],
+                "compiler":         ["GCC_13_2", "ARMCLANG_6_21"],
                 "isolation_level":  ["1", "2", "3"],
                 "test_regression":  ["OFF", "RegBL2, RegS, RegNS"],
                 "test_psa_api":     ["OFF"],
@@ -475,7 +496,6 @@
 config_ipc_backend = {"seed_params": {
                "tfm_platform":      ["arm/mps2/an519",
                                      "arm/mps2/an521",
-                                     "arm/musca_s1",
                                      "arm/musca_b1"],
                 "compiler":         ["GCC_10_3", "ARMCLANG_6_21"],
                 "isolation_level":  ["1"],
@@ -491,9 +511,8 @@
                 }
 
 config_cc_driver_psa = {"seed_params": {
-               "tfm_platform":      ["arm/musca_b1",
-                                     "arm/musca_s1"],
-                "compiler":         ["GCC_10_3"],
+               "tfm_platform":      ["arm/musca_b1"],
+                "compiler":         ["GCC_13_2"],
                 "isolation_level":  ["1"],
                 "test_regression":  ["RegBL2, RegS, RegNS"],
                 "test_psa_api":     ["OFF"],
@@ -525,9 +544,8 @@
 
 config_psa_api = {"seed_params": {
                 "tfm_platform":     ["arm/mps2/an521",
-                                     "arm/musca_b1",
-                                     "arm/musca_s1"],
-                "compiler":         ["GCC_10_3", "ARMCLANG_6_21"],
+                                     "arm/musca_b1"],
+                "compiler":         ["GCC_13_2", "ARMCLANG_6_21"],
                 "isolation_level":  ["1", "2", "3"],
                 "test_regression":  ["OFF"],
                 "test_psa_api":     ["IPC",
@@ -822,21 +840,6 @@
                 "invalid": _common_tfm_invalid_configs + []
                 }
 
-config_musca_s1 = {"seed_params": {
-                "tfm_platform":     ["arm/musca_s1"],
-                "compiler":         ["GCC_10_3", "ARMCLANG_6_21"],
-                "isolation_level":  ["1", "2"],
-                "test_regression":  ["OFF", "RegBL2, RegS, RegNS"],
-                "test_psa_api":     ["OFF"],
-                "cmake_build_type": ["Debug", "Release"],
-                "with_bl2":         [True],
-                "profile":          [""],
-                "extra_params":     ["", "NSOFF"]
-                },
-                "common_params": _common_tfm_builder_cfg,
-                "invalid": _common_tfm_invalid_configs + []
-                }
-
 config_corstone310 = {"seed_params": {
                 "tfm_platform":     ["arm/mps3/corstone310/fvp"],
                 "compiler":         ["GCC_10_3"],
@@ -1273,7 +1276,6 @@
                     "cs300_an552": config_cs300_an552,
                     "cs300_fvp": config_cs300_fvp,
                     "musca_b1": config_musca_b1,
-                    "musca_s1": config_musca_s1,
                     "corstone310": config_corstone310,
                     "corstone315": config_corstone315,
                     "rse": config_rse,