blob: 770e2db92907c3f511fef8afa5f2905002befbc6 [file] [log] [blame]
Divin Raj5eb69482024-10-02 11:36:04 +01001#!/usr/bin/env bash
2#
3# Copyright (c) 2024, Arm Limited. All rights reserved.
4#
5# SPDX-License-Identifier: BSD-3-Clause
6#
7source "$ci_root/run_config/rd1ae_rse_utils.sh"
8source "$ci_root/arm_auto_solutions_utils.sh"
9
10post_tf_build() {
Ziad Elhanafy35771802024-12-02 16:53:42 +000011 # Download and archive rd1ae u-boot.bin file
Divin Raj5eb69482024-10-02 11:36:04 +010012 url="$arm_automotive_solutions/rd1ae/u-boot.bin" saveas="uboot.bin" fetch_file
13 archive_file "uboot.bin"
14
Ziad Elhanafy35771802024-12-02 16:53:42 +000015 # Download and archive rd1ae tee-pager_v2.bin file
16 url="$arm_automotive_solutions/rd1ae/tee-pager_v2.bin" saveas="tee-pager_v2.bin" fetch_file
17 archive_file "tee-pager_v2.bin"
18
19 build_fip BL33="$archive/uboot.bin" BL32="$archive/tee-pager_v2.bin"
Divin Raj5eb69482024-10-02 11:36:04 +010020}
21
22fetch_tf_resource() {
23 # Sign ap_bl2 image with RSE public key
24 sign_host_ap_bl2_image bl2.bin $rd1ae_ap_bl2_flash_load_addr $rd1ae_ap_bl2_flash_size
25
26 # Update fip image with signed ap_bl2
27 bin_name="tb-fw" src="$archive/$signed_bin" fip_update
28
29 # Download all required images to boot rd1ae
30 downlaod_rd1ae_prebuilt
31
32 # Update ap-flash-image with newly created fip image
33 update_ap_flash_image
34}
35
36generate_lava_job_template() {
37 payload_type="linux" gen_yaml_template
38}
39
40generate_lava_job() {
41 local model="rd1ae"
42 uart="1" set_expect_variable "num_cpus" "8"
43
44 # Hold scp terminal_uart_scp
45 uart="2" port="5007" file="hold_uart.exp" track_expect
46 uart="0" port="5009" file="rd1ae-tf.exp" track_expect
47 uart="1" port="5008" file="rd1ae-yocto.exp" set_primary="1" timeout="1200" track_expect
48
49 set_run_env "ports_script" "$ci_root/model/rd1ae-ports.awk"
50 set_run_env "num_uarts" "3"
51
52 model="$model" \
53 model_build="20" \
54 model_flavour="Linux64_GCC-9.3" \
55 model_version="11.27" \
56 gen_model_params
57
58 model="$model" gen_fvp_yaml
59}
60