From 9499515d852824400d80bd699b9e41d53028439e Mon Sep 17 00:00:00 2001 From: Max Krummenacher Date: Thu, 27 Apr 2023 10:16:49 +0200 Subject: image_type_tezi: rename vars related to tpl The variables TPL_BINARY and OFFSET_TPL_PAYLOAD are not choosen wisely as they are not used to specify a TPL (Tertiary Program Loader). They were introduced and used for the Verdin AM62 machine. The tiboot3 binary is not a TPL (Tertiary Program Loader) but actually contains the binaries first booted by the boot ROM. Rename TPL_BINARY and OFFSET_TPL_PAYLOAD to FIRMWARE_BINARY and OFFSET_FW_PAYLOAD respectively. Related-to: ELB-5244 Signed-off-by: Max Krummenacher (cherry picked from commit dd6ea5f3ad1ac334c3d6f5978be6f597a3c86170) --- classes/image_type_tezi.bbclass | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) (limited to 'classes') diff --git a/classes/image_type_tezi.bbclass b/classes/image_type_tezi.bbclass index a973f7a..877045b 100644 --- a/classes/image_type_tezi.bbclass +++ b/classes/image_type_tezi.bbclass @@ -140,24 +140,24 @@ def rootfs_tezi_emmc(d, use_bootfiles): emmcdevboot0 = d.getVar('EMMCDEVBOOT0') imagename = d.getVar('IMAGE_LINK_NAME') offset_bootrom = d.getVar('OFFSET_BOOTROM_PAYLOAD') - offset_tpl = d.getVar('OFFSET_TPL_PAYLOAD') + offset_fw = d.getVar('OFFSET_FW_PAYLOAD') offset_spl = d.getVar('OFFSET_SPL_PAYLOAD') bootpart_rawfiles = [] filesystem_partitions = [] offset_payload = offset_bootrom - if offset_tpl: - # TPL_BINARY contain product_id <-> filename mapping - tplmapping = d.getVarFlags('TPL_BINARY') - for f, v in tplmapping.items(): + if offset_fw: + # FIRMWARE_BINARY contain product_id <-> filename mapping + fwmapping = d.getVarFlags('FIRMWARE_BINARY') + for f, v in fwmapping.items(): bootpart_rawfiles.append( { "filename": v, "dd_options": "seek=" + offset_payload, "product_ids": f }) - offset_payload = offset_tpl + offset_payload = offset_fw if offset_spl: bootpart_rawfiles.append( { @@ -342,15 +342,15 @@ def rootfs_tezi_json(d, flash_type, flash_data, json_file, uenv_file): json.dump(data, outfile, indent=4) bb.note("Toradex Easy Installer metadata file {0} written.".format(json_file)) -def tpl_binaries(d): - tplmapping = d.getVarFlags('TPL_BINARY') +def fw_binaries(d): + fwmapping = d.getVarFlags('FIRMWARE_BINARY') - if tplmapping is not None: - tpl_bins = [] - for key, val in tplmapping.items(): - if val not in tpl_bins: - tpl_bins.append(val) - return " " + " ".join(tpl_bins) + if fwmapping is not None: + fw_bins = [] + for key, val in fwmapping.items(): + if val not in fw_bins: + fw_bins.append(val) + return " " + " ".join(fw_bins) else: return "" @@ -372,7 +372,7 @@ python rootfs_tezi_run_json() { uenv_file = d.getVar('UBOOT_ENV_TEZI_EMMC') uboot_file = d.getVar('UBOOT_BINARY_TEZI_EMMC') # TODO: Multi image/raw NAND with SPL currently not supported - uboot_file += tpl_binaries(d); + uboot_file += fw_binaries(d); uboot_file += " " + d.getVar('SPL_BINARY') if d.getVar('OFFSET_SPL_PAYLOAD') else "" artifacts += " " + "%s/%s.%s" % (d.getVar('IMGDEPLOYDIR'), d.getVar('IMAGE_LINK_NAME'), d.getVar('TEZI_BOOT_SUFFIX')) if use_bootfiles else "" else: -- cgit v1.2.3