public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Jon Hunter <jonathanh@nvidia.com>
To: u-boot@lists.denx.de
Subject: [PATCH] distro_bootcmd: Add support for loading user environment
Date: Fri, 31 Jan 2020 13:24:21 +0000	[thread overview]
Message-ID: <4288c8d1-b5d7-ca36-9f92-ed86a256be4d@nvidia.com> (raw)
In-Reply-To: <ea67dff6-1659-30b6-1f76-e2ef2bc76bbf@web.de>


On 31/01/2020 12:42, Soeren Moch wrote:
> On 31.01.20 11:59, Jon Hunter wrote:
>> U-Boot supports loading a user environment from a file in the
>> file-system. Therefore to make it easier for users to override the
>> default environment, add support to the 'distro_bootcmd' to look for
>> and load a user environment in a file called 'uEnv.txt' in the same
>> locations where an extlinux.conf or boot script might be found.
> 
> We already have boot script support, which can easily be used to modify
> the environment. Do we really need to bloat the distro_boot machinery
> further with environment import, that is quite limited in contrast to
> boot scripts?

If you are booting with an extlinux.conf file, as we do by default, then
if this file is found, this is always booted from before you have the
opportunity to run the boot.scr script.

Furthermore if you did switch the order to boot from a boot.scr script
before the extlinux.conf, but you just wanted to do some simple
modifications of the environment before booting (ie. so the boot.scr
does not actually boot the system), then as the code is today you get a
'echo SCRIPT FAILED: continuing...' message.

Yes this could be changed, but just seems cleaner and simpler to add
support to make changes to the environment before the extlinux.conf is
loaded.

Yes this does add more to the environment, but it is hardly significant
bloat, but if that is a concern then we could always disable this by
default and allow users to enable it.

Jon

-- 
nvpublic

  reply	other threads:[~2020-01-31 13:24 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-31 10:59 [PATCH] distro_bootcmd: Add support for loading user environment Jon Hunter
2020-01-31 12:42 ` Soeren Moch
2020-01-31 13:24   ` Jon Hunter [this message]
2020-01-31 14:05     ` Tom Rini
2020-01-31 14:42       ` Jon Hunter
2020-01-31 14:54         ` Tom Rini
2020-01-31 18:18           ` Stephen Warren
2020-01-31 18:28             ` Soeren Moch
2020-01-31 18:34               ` Tom Rini
2020-01-31 14:58         ` David Abdurachmanov
2020-01-31 18:14           ` Tom Rini

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=4288c8d1-b5d7-ca36-9f92-ed86a256be4d@nvidia.com \
    --to=jonathanh@nvidia.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox