On 5/8/25 10:32 PM, Tom Rini wrote:
On Thu, May 08, 2025 at 03:16:39PM +0200, Wadim Egorov wrote:

This series introduces new Kconfig options to configure default environment
variables used in script-based boot scenarios. Specifically, it allows
setting the following standard boot environment variables:

- boot_script_dhcp via BOOTSCRIPT_DHCP
- script_offset_f and script_size_f via USE_SPI_FLASH_SCRIPT and
   related options

These changes make it possible to define standard boot environment variables
directly via Kconfig, allowing higher-level build systems like Yocto to set
them at build time. This avoids the need for post-build environment patches
or runtime overrides, improving reproducibility and simplifying integration
in automated firmware build workflows.

Wadim Egorov (2):
   boot: Add BOOTSCRIPT_DHCP Kconfig option for boot_script_dhcp env
   mtd: bootdev: Add Kconfig option for defining script parameters

  boot/Kconfig            | 18 ++++++++++++++++++
  drivers/mtd/spi/Kconfig | 26 ++++++++++++++++++++++++++
  include/env_default.h   |  7 +++++++
  3 files changed, 51 insertions(+)

It would be nice to see what the Yocto side of this looks like for
example. My first thought is about if this is really easier / better to
maintain than dropping in a new env file? Thanks.


We use config fragments in Yocto (based on merge_config.sh) to enable or disable u-boot features in different builds. Because users may require different SPI flash memory layouts, they can override variables like script_offset_f in their own layer instead of appending an extra patch for this job.

Reply via email to