mcuboot icon indicating copy to clipboard operation
mcuboot copied to clipboard

zephyr: Add a bool Kconfig option for swap move

Open d3zd3z opened this issue 3 years ago • 4 comments

The Kconfig system used by Zephyr does not allow the defaults for choice options to be overridden. To compensate for this, create a new boolean config option that will determine what the default is for the boot mode.

This allows the kconfig override file for various Zephyr boards to change the default to swap move.

Signed-off-by: David Brown [email protected]

d3zd3z avatar Apr 26 '22 20:04 d3zd3z

Making this a draft for additional integration testing with Zephyr.

d3zd3z avatar Apr 26 '22 20:04 d3zd3z

I think this should be benign until other changes are made in Zephyr, so it'd be nice to get this in, so we can work toward getting Zephyr transitioned to using it.

d3zd3z avatar May 24 '22 15:05 d3zd3z

The Kconfig system used by Zephyr does not allow the defaults for choice options to be overridden.

For named choice (like that one you modified) you can modify it using additional Kconfig. An example of this https://github.com/nrfconnect/sdk-nrf/blob/main/drivers/mpsl/flash_sync/Kconfig#L9, choice SOC_FLASH_NRF_RADIO_SYNC_CHOICE is originated from zephyr.

Although override a choice might be unproductive for this particular need.

nvlsianpu avatar May 27 '22 15:05 nvlsianpu

For named choice (like that one you modified) you can modify it using additional Kconfig.

I'd be open to suggestions on how to make this work, but what you've suggested definitely doesn't work when used in a Kconfig.defconfig file. It is stated in the Kconfig documentation that this is a limitation.

d3zd3z avatar May 31 '22 16:05 d3zd3z