All of lore.kernel.org
 help / color / mirror / Atom feed
From: Shawn Guo <shawn.gsc@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] mx51evk: consolidate env for mmcboot and netboot
Date: Wed, 27 Oct 2010 19:19:40 +0800	[thread overview]
Message-ID: <AANLkTinRMO-Xh=tbo4DAYkFYoALe8PxuaUTCWem=u4Ox@mail.gmail.com> (raw)
In-Reply-To: <1288020030-18693-1-git-send-email-shawn.gsc@gmail.com>

Copy Linaro for comments, as Linaro may be concerned by this patch.

On Mon, Oct 25, 2010 at 11:20 PM, Shawn Guo <shawn.gsc@gmail.com> wrote:
> This patch is to consolidate default mx51evk env for two primary
> boot modes, mmcboot and netboot.
>
> It also cleans some unused env like netdev, uboot and redundant
> env like loadaddr since CONFIG_LOADADDR already defines it.
>
> Signed-off-by: Shawn Guo <shawn.gsc@gmail.com>
> ---
> ?include/configs/mx51evk.h | ? 50 ++++++++++++++++++++++++++++++++++----------
> ?1 files changed, 38 insertions(+), 12 deletions(-)
>
> diff --git a/include/configs/mx51evk.h b/include/configs/mx51evk.h
> index 6165473..186cd8c 100644
> --- a/include/configs/mx51evk.h
> +++ b/include/configs/mx51evk.h
> @@ -126,18 +126,42 @@
>
> ?#define CONFIG_LOADADDR ? ? ? ? ? ? ? ?0x90800000 ? ? ?/* loadaddr env var */
>
> -#define ? ? ? ?CONFIG_EXTRA_ENV_SETTINGS ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? \
> - ? ? ? ? ? ? ? "netdev=eth0\0" ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? \
> - ? ? ? ? ? ? ? "uboot_addr=0xa0000000\0" ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? \
> - ? ? ? ? ? ? ? "uboot=u-boot.bin\0" ? ? ? ? ? ? ? ? ? ?\
> - ? ? ? ? ? ? ? "loadaddr=0x90800000\0" ? ? ? ? ? ? ? ? \
> - ? ? ? ? ? ? ? "bootargs_base=setenv bootargs console=tty "\
> - ? ? ? ? ? ? ? ? ? ? ? "console=ttymxc0,${baudrate}\0"\
> - ? ? ? ? ? ? ? "bootargs_nfs=setenv bootargs ${bootargs} root=/dev/nfs "\
> - ? ? ? ? ? ? ? ? ? ? ? "ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0"\
> - ? ? ? ? ? ? ? "bootcmd=run bootcmd_net\0" ? ? ? ? ? ? ? ? ? ? ? ? ? ? \
> - ? ? ? ? ? ? ? "bootcmd_net=run bootargs_base bootargs_nfs; " ? ? ? ? ?\
> - ? ? ? ? ? ? ? ? ? ? ? "tftpboot ${loadaddr} ${kernel}; bootm\0"
> +#define CONFIG_EXTRA_ENV_SETTINGS \
> + ? ? ? "script=boot.scr\0" \
> + ? ? ? "uimage=uImage\0" \
> + ? ? ? "mmcdev=0\0" \
> + ? ? ? "mmcpart=2\0" \
> + ? ? ? "mmcroot=/dev/mmcblk0p3 rw\0" \
> + ? ? ? "mmcrootfstype=ext3 rootwait\0" \
> + ? ? ? "mmcargs=setenv bootargs console=ttymxc0,${baudrate} " \
> + ? ? ? ? ? ? ? "root=${mmcroot} " \
> + ? ? ? ? ? ? ? "rootfstype=${mmcrootfstype}\0" \
> + ? ? ? "loadbootscript=" \
> + ? ? ? ? ? ? ? "fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \
> + ? ? ? "bootscript=echo Running bootscript from mmc ...; " \
> + ? ? ? ? ? ? ? "source\0" \
> + ? ? ? "loaduimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${uimage}\0" \
> + ? ? ? "mmcboot=echo Booting from mmc ...; " \
> + ? ? ? ? ? ? ? "run mmcargs; " \
> + ? ? ? ? ? ? ? "bootm\0" \
> + ? ? ? "netargs=setenv bootargs console=ttymxc0,${baudrate} " \
> + ? ? ? ? ? ? ? "root=/dev/nfs " \
> + ? ? ? ? ? ? ? "ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0" \
> + ? ? ? "netboot=echo Booting from net ...; " \
> + ? ? ? ? ? ? ? "run netargs; " \
> + ? ? ? ? ? ? ? "dhcp ${uimage}; bootm\0" \
> +
> +#define CONFIG_BOOTCOMMAND \
> + ? ? ? "if mmc rescan ${mmcdev}; then " \
> + ? ? ? ? ? ? ? "if run loadbootscript; then " \
> + ? ? ? ? ? ? ? ? ? ? ? "run bootscript; " \
> + ? ? ? ? ? ? ? "else " \
> + ? ? ? ? ? ? ? ? ? ? ? "if run loaduimage; then " \
> + ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? "run mmcboot; " \
> + ? ? ? ? ? ? ? ? ? ? ? "else run netboot; " \
> + ? ? ? ? ? ? ? ? ? ? ? "fi; " \
> + ? ? ? ? ? ? ? "fi; " \
> + ? ? ? "else run netboot; fi"
>
> ?#define CONFIG_ARP_TIMEOUT ? ? 200UL
>
> @@ -145,6 +169,8 @@
> ?* Miscellaneous configurable options
> ?*/
> ?#define CONFIG_SYS_LONGHELP ? ? ? ? ? ?/* undef to save memory */
> +#define CONFIG_SYS_HUSH_PARSER ? ? ? ? /* use "hush" command parser */
> +#define CONFIG_SYS_PROMPT_HUSH_PS2 ? ? "> "
> ?#define CONFIG_SYS_PROMPT ? ? ? ? ? ? ?"MX51EVK U-Boot > "
> ?#define CONFIG_AUTO_COMPLETE
> ?#define CONFIG_SYS_CBSIZE ? ? ? ? ? ? ?256 ? ? /* Console I/O Buffer Size */
> --
> 1.7.1
>
>



-- 
Regards,
Shawn

  reply	other threads:[~2010-10-27 11:19 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-25 15:20 [U-Boot] [PATCH] mx51evk: consolidate env for mmcboot and netboot Shawn Guo
2010-10-27 11:19 ` Shawn Guo [this message]
2010-10-28 11:20 ` Stefano Babic

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='AANLkTinRMO-Xh=tbo4DAYkFYoALe8PxuaUTCWem=u4Ox@mail.gmail.com' \
    --to=shawn.gsc@gmail.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.