From: Benjamin ROBIN <benjamin.robin@bootlin.com>
To: U-Boot Mailing List <u-boot@lists.denx.de>
Cc: Adrian Freihofer <adrian.freihofer@siemens.com>,
Heiko Schocher <hs@nabladev.com>,
Benjamin ROBIN <dev@benjarobin.fr>,
Jerome Forissier <jerome@forissier.org>,
Joe Hershberger <joe.hershberger@ni.com>,
Marek Vasut <marek.vasut+renesas@mailbox.org>,
Quentin Schulz <quentin.schulz@cherry.de>,
Tom Rini <trini@konsulko.com>
Subject: Re: [PATCH v1] env: add w flags for net config in explicit write mode
Date: Sat, 24 Jan 2026 12:35:19 +0100 [thread overview]
Message-ID: <2397776.ElGaqSPkdT@brobin-bootlin> (raw)
In-Reply-To: <20260124054040.7597-1-hs@nabladev.com>
Hello,
On Saturday, January 24, 2026 at 6:40 AM, Heiko Schocher wrote:
> From: Adrian Freihofer <adrian.freihofer@siemens.com>
>
> In explicit write access mode (CONFIG_ENV_WRITEABLE_LIST) the
> environment variables listed in NET_FLAGS and NET6_FLAGS are
> probably intended to be writeable. Therefore add the 'w' flag
> to these variables.
Users who enable CONFIG_ENV_WRITEABLE_LIST typically want full control over
which environment variables are writable. The new default behavior introduced
by your patch might not align with what all users expect or want.
Would overriding the flags using CFG_ENV_FLAGS_LIST_STATIC not work in this
case?
> diff --git a/include/env_flags.h b/include/env_flags.h
> index 0c48874690f..fc65dcaba21 100644
> --- a/include/env_flags.h
> +++ b/include/env_flags.h
> @@ -56,6 +56,16 @@ enum env_flags_varaccess {
> #define ETHADDR_FLAGS "eth" ETHADDR_WILDCARD "addr:mo,"
> #endif
> #endif
> +#ifdef CONFIG_ENV_WRITEABLE_LIST
> +#define NET_FLAGS \
> + "ipaddr:iw," \
> + "gatewayip:iw," \
> + "netmask:iw," \
> + "serverip:iw," \
> + "nvlan:dw," \
> + "vlan:dw," \
> + "dnsip:iw,"
> +#else
> #define NET_FLAGS \
> "ipaddr:i," \
> "gatewayip:i," \
> @@ -64,16 +74,24 @@ enum env_flags_varaccess {
> "nvlan:d," \
> "vlan:d," \
> "dnsip:i,"
> +#endif
> #else
> #define ETHADDR_FLAGS
> #define NET_FLAGS
> #endif
>
> #ifdef CONFIG_IPV6
> +#ifdef CONFIG_ENV_WRITEABLE_LIST
> +#define NET6_FLAGS \
> + "ip6addr:sw," \
> + "serverip6:sw," \
> + "gatewayip6:sw,"
> +#else
> #define NET6_FLAGS \
> "ip6addr:s," \
> "serverip6:s," \
> "gatewayip6:s,"
> +#endif
> #else
> #define NET6_FLAGS
> #endif
Best regards,
--
Benjamin Robin, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
next prev parent reply other threads:[~2026-01-24 14:35 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-24 5:40 [PATCH v1] env: add w flags for net config in explicit write mode Heiko Schocher
2026-01-24 11:35 ` Benjamin ROBIN [this message]
2026-01-25 13:03 ` Heiko Schocher
2026-01-25 13:33 ` Benjamin ROBIN
2026-01-25 13:40 ` Heiko Schocher
2026-01-26 13:25 ` Heiko Schocher
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2397776.ElGaqSPkdT@brobin-bootlin \
--to=benjamin.robin@bootlin.com \
--cc=adrian.freihofer@siemens.com \
--cc=dev@benjarobin.fr \
--cc=hs@nabladev.com \
--cc=jerome@forissier.org \
--cc=joe.hershberger@ni.com \
--cc=marek.vasut+renesas@mailbox.org \
--cc=quentin.schulz@cherry.de \
--cc=trini@konsulko.com \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.