if ARCH_IMX8

config AHAB_BOOT
	bool "Support i.MX8 AHAB features"
	imply CMD_DEKBLOB
	help
	  This option enables the support for AHAB secure boot.

config IMX_LOAD_HDMI_FIMRWARE_RX
	bool "Enable HDMI rx firmware loading"
	depends on ARCH_IMX8 || VIDEO_IMX_HDP_LOAD
	help
	  This enable the hdmi rx firmware loading. It depends on the "hdprx" command.

config IMX_LOAD_HDMI_FIMRWARE_TX
	bool "Enable HDMI tx firmware loading"
	depends on ARCH_IMX8 || VIDEO_IMX_HDP_LOAD
	help
	  This enable the hdmi tx firmware loading. It depends on the "hdp" command.

config IMX8
	bool
	select HAS_CAAM

config MU_BASE_SPL
	hex "MU base address used in SPL"
	default 0x5d1b0000
	help
	  SPL runs in EL3 mode, it use MU0_A to communicate with SCU.
	  So we could not reuse the one in dts which is for normal U-Boot.

config IMX8QM
	select IMX8
	select SUPPORT_SPL
	select SPL_RECOVER_DATA_SECTION if SPL
	bool

config IMX8QXP
	select IMX8
	select SUPPORT_SPL
	select SPL_RECOVER_DATA_SECTION if SPL
	bool

config IMX8DXL
	select IMX8
	select SUPPORT_SPL
	select SPL_RECOVER_DATA_SECTION if SPL
	bool

config SYS_SOC
	default "imx8"

config BOOTAUX_RESERVED_MEM_BASE
	hex "i.MX auxiliary core dram memory base"
	default 0

config BOOTAUX_RESERVED_MEM_SIZE
	hex "i.MX auxiliary core dram memory size"
	default 0

config PSCI_BOARD_REBOOT
	bool "Enable psci board reboot command"
	depends on ARM_PSCI_FW
	help
	  This is a optional command used to trigger system board reboot on imx8.

config SECURE_HEAP_BASE
	hex "secure heap base addr"
	default 0xe0000000

config SECURE_HEAP_SIZE
	hex "secure heap base size"
	default 0x10000000

config VPU_BOOT_BASE
	hex "vpu boot memory addr"
	default 0x96000000

config VPU_BOOT_SIZE
	hex "vpu boot memory size"
	default 0x2000000


choice
	prompt "i.MX8 board select"
	optional

config TARGET_APALIS_IMX8
	bool "Support Apalis iMX8 module"
	select BOARD_LATE_INIT
	select IMX8QM

config TARGET_COLIBRI_IMX8X
	bool "Support Colibri iMX8X module"
	select BINMAN
	select BOARD_LATE_INIT
	select IMX8QXP

config TARGET_DENEB
	bool "Support i.MX8QXP Capricorn Deneb board"
	select BINMAN
	select BOARD_LATE_INIT
	select FACTORYSET
	select IMX8QXP

config TARGET_GIEDI
	bool "Support i.MX8QXP Capricorn Giedi board"
	select BINMAN
	select BOARD_LATE_INIT
	select FACTORYSET
	select IMX8QXP

config TARGET_IMX8QM_MEK
	bool "Support i.MX8QM MEK board"
	select BOARD_LATE_INIT
	select IMX8QM
	select FSL_CAAM
	select FSL_BLOB
	select ARCH_MISC_INIT
	select SPL_CRYPTO if SPL

config TARGET_IMX8QM_LPDDR4_VAL
	bool "Support i.MX8QM lpddr4 validation board"
	select BOARD_LATE_INIT
	select IMX8QM

config TARGET_IMX8QM_DDR4_VAL
	bool "Support i.MX8QM ddr4 validation board"
	select BOARD_LATE_INIT
	select IMX8QM

config TARGET_CONGA_QMX8
	bool "Support congatec conga-QMX8 board"
	select BINMAN
	select BOARD_LATE_INIT
	select SUPPORT_SPL
	select IMX8QM

config TARGET_IMX8QM_ROM7720_A1
	bool "Support i.MX8QM ROM-7720-A1"
	select BINMAN
	select BOARD_LATE_INIT
	select SUPPORT_SPL
	select IMX8QM

config TARGET_IMX8QXP_MEK
	bool "Support i.MX8QXP MEK board"
	select BOARD_LATE_INIT
	select IMX8QXP
	select FSL_CAAM
	select FSL_BLOB
	select ARCH_MISC_INIT
	select SPL_CRYPTO if SPL

config TARGET_IMX8QM_MEK_A53_ONLY
        bool "Support i.MX8QM MEK board, cluster A53 only"
        select BOARD_LATE_INIT
        select IMX8QM

config TARGET_IMX8QM_MEK_A72_ONLY
        bool "Support i.MX8QM MEK board, cluster A72 only"
        select BOARD_LATE_INIT
        select IMX8QM

config TARGET_IMX8QXP_LPDDR4_VAL
	bool "Support i.MX8QXP lpddr4 validation board"
	select BOARD_LATE_INIT
	select IMX8QXP

config TARGET_IMX8QXP_DDR3_VAL
	bool "Support i.MX8QXP ddr3 validation board"
	select BOARD_LATE_INIT
	select IMX8QXP

config TARGET_IMX8X_17X17_VAL
	bool "Support i.MX8QXP/DX 17x17 validation board"
	select BOARD_LATE_INIT
	select IMX8QXP

config TARGET_IMX8DXL_PHANTOM_MEK
	bool "Support i.MX8DXL PHANTOM MEK board"
	select BOARD_LATE_INIT
	select IMX8QXP
	select FSL_CAAM
	select FSL_BLOB
	select ARCH_MISC_INIT
	select SPL_CRYPTO if SPL

config TARGET_IMX8DX_MEK
	bool "Support i.MX8DX MEK board"
	select BOARD_LATE_INIT
	select SUPPORT_SPL
	select IMX8QXP
	select FSL_CAAM
	select FSL_BLOB
	select ARCH_MISC_INIT
	select SPL_CRYPTO if SPL

config TARGET_IMX8DXL_EVK
	bool "Support i.MX8DXL EVK board"
	select BOARD_LATE_INIT
	select IMX8DXL
	select FSL_CAAM
	select FSL_BLOB
	select ARCH_MISC_INIT
	select SPL_CRYPTO if SPL

config TARGET_IMX8DXL_DDR3_EVK
	bool "Support i.MX8DXL EVK board"
	select BOARD_LATE_INIT
	select IMX8DXL
	select FSL_CAAM
	select FSL_BLOB
	select ARCH_MISC_INIT
	select SPL_CRYPTO if SPL

config TARGET_IMX8DXL_ORANGEBOX
	bool "Support i.MX8DXL OrangeBox board"
	select BOARD_LATE_INIT
	select IMX8DXL
	select FSL_CAAM
	select FSL_BLOB
	select ARCH_MISC_INIT
	select SPL_CRYPTO if SPL

endchoice

source "board/freescale/imx8qm_mek/Kconfig"
source "board/freescale/imx8qxp_mek/Kconfig"
source "board/congatec/cgtqmx8/Kconfig"
source "board/freescale/imx8qm_val/Kconfig"
source "board/freescale/imx8qxp_val/Kconfig"
source "board/freescale/imx8dxl_phantom_mek/Kconfig"
source "board/freescale/imx8dxl_evk/Kconfig"
source "board/freescale/imx8dxl_orangebox/Kconfig"
source "board/advantech/imx8qm_rom7720_a1/Kconfig"
source "board/toradex/apalis-imx8/Kconfig"
source "board/toradex/colibri-imx8x/Kconfig"
source "board/siemens/capricorn/Kconfig"

config SKIP_RESOURCE_CHECKING
	bool "Skip resource owner checking to kernel FDT nodes"
	help
	  By default the kernel FDT nodes are checked if belong to current partition.
	  Set the config to skip this checking.

config IMX_SNVS_SEC_SC
	bool "Support SNVS configuration"
	help
	  Allow to configure the SNVS via SCU API to configure tampers and secure
	  violation.

config IMX_SNVS_SEC_SC_AUTO
	bool "Support SNVS configuration command"
	depends on IMX_SNVS_SEC_SC
	help
	  This configuration will apply the selected configurations automatically
	  at boot.

endif
