blob: 409aae66da939db3fafcc5e9239912a5e41f46a9 [file] [log] [blame]
#!/usr/bin/env bash
#
# Copyright (c) 2019-2023, Arm Limited. All rights reserved.
#
# SPDX-License-Identifier: BSD-3-Clause
#
source "$ci_root/run_config/tc_rss_utils.sh"
fetch_tf_resource() {
image="kernel" type="tc-kernel" get_boot_image
image="initrd" type="tc-ramdisk" get_boot_image
# 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
url="$scp_prebuilts/tc$plat_variant/release/tc$plat_variant-bl1.bin" saveas="scp_rom.bin" fetch_file
archive_file "scp_rom.bin"
fi
# RSS is applicable to TC2
if [ $plat_variant -eq 2 ]; then
# Hold RSS terminal_uart_ap
uart="2" file="hold_uart.exp" track_expect
# sign AP bl1
sign_image bl1.bin $ap_bl1_flash_load_addr $ap_bl1_flash_size
# Update FIP with pre-built RSS binaries and signed AP BL1 to create host flash fip image
update_fip
fi
}
generate_lava_job_template() {
# Hold scp terminal_s0
uart="0" port="5002" file="hold_uart.exp" track_expect
uart="1" port="5003" file="linux-rd-busybox.exp" set_primary="1" \
track_expect
set_uart_port "${archive:?}" 2 5000
set_uart_port "${archive:?}" 3 5001
payload_type="linux" gen_yaml_template
}