From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Warren Date: Mon, 05 Jan 2015 13:31:15 -0700 Subject: [U-Boot] [PATCH 4/4] distro_distro_bootcmd: use CONFIG_BOOTCOMMAND instead of setting bootcmd= In-Reply-To: <1420478019-18877-5-git-send-email-sjoerd.simons@collabora.co.uk> References: <1420478019-18877-1-git-send-email-sjoerd.simons@collabora.co.uk> <1420478019-18877-5-git-send-email-sjoerd.simons@collabora.co.uk> Message-ID: <54AAF493.1070106@wwwdotorg.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 01/05/2015 10:13 AM, Sjoerd Simons wrote: > Move the bootcmd commands into a seperate distro_bootcmd environment > variable. Allowing a user to easily launch the distro boot sequence if > the default bootcmd did not default to distro boot commands. Well, the user can just type "boot" or "run bootcmd", so I don't think this makes it much easier for the user:-P > Also set CONFIG_BOOTCOMMAND to "run distro_bootcmd" if it hasn't been > configured yet rather then putting it directly in the environment. This > allows boards to make the distro boot commands available without > necessarily default to them or to use them as a fallback after running > some board specific commands instead. Reviewed-by: Stephen Warren As an aside, I actually have a local commit that amends the bootcmd value to include BOOTENV_HOOK_BOOTCMD_PRE before the current value, which also allows boards to do arbitrary things before executing the distro boot code. Still, I think your way is more flexible, since it allows board-provided scripts to invoke $distro_bootcmd when/whereever they want. I'll rework my code on top of this.