#
# Copyright (c) 2021 Nordic Semiconductor ASA
#
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

menuconfig FMFU_FDEV
	bool "Full Modem Firmware Upgrade from flash device"
	depends on ZCBOR
	depends on NRF_MODEM_LIB
	depends on MBEDTLS_SHA256_C


if (FMFU_FDEV)

config FMFU_CDDL_DECODER_GENERATE
	bool "Regenerate FMFU CBOR code from cddl using zcbor, for internal use."
	help
	  Nordic internal, see cddl/CMakeLists.txt

config MBEDTLS_HEAP_SIZE
	int
	default 4096

config FMFU_FDEV_SKIP_PREVALIDATION
	bool "Skip prevalidation of modem firmware"
	help
	  Set this option to skip prevalidation of the modem firmware. Note
	  that the modem will still verify the validity of the modem firmmware
	  before booting it, but only after it has been written to the modem.
	  This option

if FMFU_FDEV_SKIP_PREVALIDATION
	comment "FMFU_FDEV_SKIP_PREVALIDATE should ONLY be used during development"
endif

module=FMFU_FDEV
module-dep=LOG
module-str=FMFU FDEV
source "${ZEPHYR_BASE}/subsys/logging/Kconfig.template.log_config"

endif # FMFU_FDEV
