public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@nvidia.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [RFC PATCH 6/7] Add support for loading environment from uEnv.txt in config_distro_bootcmd.
Date: Mon, 06 Oct 2014 20:55:43 -0700	[thread overview]
Message-ID: <5433643F.80101@nvidia.com> (raw)
In-Reply-To: <1412374123-6787-7-git-send-email-vagrant@debian.org>

On 10/03/2014 03:08 PM, Vagrant Cascadian wrote:


> diff --git a/include/config_distro_bootcmd.h b/include/config_distro_bootcmd.h

>  			"for prefix in ${boot_prefixes}; do "             \
>  				"run scan_dev_for_extlinux; "             \
>  				"run scan_dev_for_scripts; "              \
> +				"run scan_dev_for_uenv_files; "           \
>  			"done;"                                           \

I've always thought of uEnv.txt being stored in a single hard-coded
location, and used to set e.g. $boot_targets to influence which
locations get searched for boot files. However, this patch appears to
use it to house actual boot command sequences.

In other words, I intended:

* (Optionally, and preferably via CONFIG_PREBOOT) load uEnv.txt from a
hard-coded location.
* Search a list of locations for boot files, of type extlinux.conf (or
for legacy reasons, boot .scr)

However, this patch now allows:

* Search a list of locations for boot files, of type extlinux.conf, or
for legacy reasons, boot .scr, or uEnv.txt

I don't think that's something we should encourage in
config_distro_bootcmd.h; the entire point of this header file is to
define a single way (extlinux.conf) for distros to define the available
boot options. Yes unfortunately we have boot.scr too as a legacy option,
but perhaps someday we can drop that. If we grow more options (allowing
boot scripts in uEnv.txt) that removes the standardization.

If we absolutely have to support uEnv.txt for legacy reasons on some
platforms, we should at least make it optional so that we don't add
support for it to all the other platforms that don't want to pick up
legacy stuff. Perhaps we should "run scan_dev_hook" and allow boards to
define arbitrary stuff there, so there's no mention at all of uEnv.txt
in config_distro_bootcmd.h.

  reply	other threads:[~2014-10-07  3:55 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-03 22:08 [U-Boot] [RFC PATCH 0/7] Switch am335x_evm.h based boards to use config_distro_bootcmd Vagrant Cascadian
2014-10-03 22:08 ` [U-Boot] [RFC PATCH 1/7] Allow checking in multiple partitions for scan_dev_for_boot Vagrant Cascadian
2014-10-07  3:48   ` Stephen Warren
2014-10-07  6:07     ` Vagrant Cascadian
2014-10-03 22:08 ` [U-Boot] [RFC PATCH 2/7] Allow overriding boot_partitions default value by setting BOOTENV_BOOT_PARTITIONS before including config_distro_bootcmd Vagrant Cascadian
2014-10-03 22:08 ` [U-Boot] [RFC PATCH 3/7] Add BOOTENV_INIT_COMMAND for commands that may be needed to run before bootcmd, such as setting the fdt file variables for platfroms that detect on boot Vagrant Cascadian
2014-10-03 22:08 ` [U-Boot] [RFC PATCH 4/7] Add BOOTENV_POST_COMMAND, which is appended to the end of bootcmd Vagrant Cascadian
2014-10-03 22:08 ` [U-Boot] [RFC PATCH 5/7] Only set CONFIG_BOOTDELAY if not already set Vagrant Cascadian
2014-10-03 22:08 ` [U-Boot] [RFC PATCH 6/7] Add support for loading environment from uEnv.txt in config_distro_bootcmd Vagrant Cascadian
2014-10-07  3:55   ` Stephen Warren [this message]
2014-10-07  6:26     ` Vagrant Cascadian
2014-10-03 22:08 ` [U-Boot] [RFC PATCH 7/7] Switch am335x_evm.h to use config_distro_defaults and config_distro_bootcmd. Add scriptaddr to DEFAULT_LINUX_BOOT_ENV, as scriptaddr is used for boot scripts " Vagrant Cascadian
2014-10-24 16:22   ` Dennis Gilmore
2014-10-27  5:33     ` Rob Herring

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=5433643F.80101@nvidia.com \
    --to=swarren@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