env: CONFIG_DEFAULT_ENV_FILE and CFG_EXTRA_ENV_SETTINGS
Tom Rini
trini at konsulko.com
Fri Jul 12 18:50:26 CEST 2024
On Fri, Jul 12, 2024 at 10:14:27AM +0200, Rasmus Villemoes wrote:
> Tony Dinh <mibodhi at gmail.com> writes:
>
> > Hi Tom,
> >
> > I'm trying to move some envs from a board header file to the default
> > env file. I recall that the envs in CONFIG_DEFAULT_ENV_FILE are
> > appended to the envs in CFG_EXTRA_ENV_SETTINGS. As you mentioned here
> > before:
> >
> > https://lore.kernel.org/all/20220810170439.GJ1146598@bill-the-cat/
> >
> > But it looks like envs in CFG_EXTRA_ENV_SETTINGS are completely
> > erased, and then the envs are populated with what's in
> > CONFIG_DEFAULT_ENV_FILE.
> >
>
> Author of CONFIG_DEFAULT_ENV_FILE here.
>
> Yes, the point of that option is that you supply the entire and full
> intended default environment in that file. No U-Boot CONFIG_ options of
> CFG_* defines or anything else affects what goes into the default env
> when that option is used. [At run-time, U-Boot probably injects/sets a
> few env vars, but that's true regardless of how the default env came to
> be].
>
> I think there may be some confusion with the much newer
> CONFIG_ENV_SOURCE_FILE, which is another mechanism entirely. In that
> case the pointed-to source file is sent through cpp, thus allowing some
> u-boot config stuff to be used/referenced, and I think some further
> bells-and-whistles also exist. I don't know if CFG_EXTRA_ENV_SETTINGS
> are taken into account in that case or not.
Yes, I think you're right about the confusion as I too missed that in my
reply.
--
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20240712/965438d1/attachment.sig>
More information about the U-Boot
mailing list