// SPDX-License-Identifier: GPL-2.0-only
/*
 * Copyright (C) 2024 Texas Instruments Incorporated - https://www.ti.com/
 */

#define SPL_BOARD_DTB "spl/dts/ti/k3-j742s2-evm.dtb"
#define BOARD_DESCRIPTION "k3-j742s2-evm"
#define UBOOT_BOARD_DESCRIPTION "U-Boot for J742S2 board"

#include "k3-j784s4-binman.dtsi"

#if !defined(CONFIG_ARM64)

&binman {
	tiboot3-j742s2-hs-fs {
		insert-template = <&tiboot3_j784s4_hs_fs>;
		filename = "tiboot3-j742s2-hs-fs-evm.bin";
		symlink = "tiboot3.bin";
	};

	tiboot3-j742s2-hs {
		insert-template = <&tiboot3_j784s4_hs>;
		filename = "tiboot3-j742s2-hs-evm.bin";
	};
};

&ti_fs_enc_fs {
	filename = "ti-sysfw/ti-fs-firmware-j742s2-hs-fs-enc.bin";
};

&sysfw_inner_cert_fs {
	filename = "ti-sysfw/ti-fs-firmware-j742s2-hs-fs-cert.bin";
};

&ti_fs_enc {
	filename = "ti-sysfw/ti-fs-firmware-j742s2-hs-enc.bin";
};

&sysfw_inner_cert {
	filename = "ti-sysfw/ti-fs-firmware-j742s2-hs-cert.bin";
};

#else // CONFIG_ARM64

&binman {
	tispl {
		insert-template = <&ti_spl>;

		fit {
			images {
				dm {
					ti-dm {
						filename = "ti-dm/j742s2/ipc_echo_testb_mcu1_0_release_strip.xer5f";
					};
				};
			};
		};
	};

	u-boot {
		insert-template = <&u_boot>;
	};

	tispl-unsigned {
		insert-template = <&ti_spl_unsigned>;

		fit {
			images {
				dm {
					ti-dm {
						filename = "ti-dm/j742s2/ipc_echo_testb_mcu1_0_release_strip.xer5f";
					};
				};
			};
		};
	};

	u-boot-unsigned {
		insert-template = <&u_boot_unsigned>;
	};
};

#endif
