All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hannes Petermaier <oe5hpm@oevsv.at>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 19/21] board/BuR/kwb: Redesign default-environment
Date: Fri, 30 Jan 2015 14:25:22 +0100	[thread overview]
Message-ID: <1422624324-15431-19-git-send-email-oe5hpm@oevsv.at> (raw)
In-Reply-To: <1422624324-15431-1-git-send-email-oe5hpm@oevsv.at>

Due to several changes in the boot-process we do a complete redesign of the
default environment.

Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at>
---
 include/configs/kwb.h |   81 +++++++++++++++++++++++++++----------------------
 1 file changed, 45 insertions(+), 36 deletions(-)

diff --git a/include/configs/kwb.h b/include/configs/kwb.h
index 7989f4b..dd30df2 100644
--- a/include/configs/kwb.h
+++ b/include/configs/kwb.h
@@ -43,49 +43,58 @@
 #define CONFIG_SYS_U_BOOT_MAX_SIZE_SECTORS		0x200 /* 256 KB */
 #define CONFIG_SPL_MMC_SUPPORT
 
-#undef CONFIG_SPL_OS_BOOT
-#ifdef CONFIG_SPL_OS_BOOT
-#define CONFIG_SYS_SPL_ARGS_ADDR		0x80F80000
-
-/* RAW SD card / eMMC */
-#define CONFIG_SYS_MMCSD_RAW_MODE_KERNEL_SECTOR	0x900	/* address 0x120000 */
-#define CONFIG_SYS_MMCSD_RAW_MODE_ARGS_SECTOR	0x80	/* address 0x10000 */
-#define CONFIG_SYS_MMCSD_RAW_MODE_ARGS_SECTORS	0x80	/* 64KiB */
-
-#endif /* CONFIG_SPL_OS_BOOT */
-
-/* Always 128 KiB env size */
-#define CONFIG_ENV_SIZE			(128 << 10)
+/* Always 64 KiB env size */
+#define CONFIG_ENV_SIZE			(64 << 10)
 
 #ifndef CONFIG_SPL_BUILD
 #define CONFIG_EXTRA_ENV_SETTINGS \
-	"autoload=0\0" \
-	"loadaddr=0x80100000\0" \
-	"bootfile=arimg\0" \
-	"usbboot=echo Booting from USB-Stick ...; " \
-		"usb start; " \
-		"fatload usb 0 ${loadaddr} ${bootfile}; " \
-		"usb stop; " \
-		"go ${loadaddr};\0" \
-	"netboot=echo Booting from network ...; " \
-		"setenv autoload 0; " \
-		"dhcp; " \
-		"tftp ${loadaddr} arimg; " \
-		"go ${loadaddr}\0" \
-	"usbupdate=echo Updating UBOOT from USB-Stick ...; " \
-		"usb start; " \
-		"fatload usb 0 0x80000000 updateubootusb.img; " \
-		"source;\0" \
-	"netupdate=echo Updating UBOOT from Network (TFTP) ...; " \
-		"setenv autoload 0; " \
-		"dhcp;" \
-		"tftp 0x80000000 updateUBOOT.img;" \
-		"source;\0"
+BUR_COMMON_ENV \
+"vx_romfsbase=0x800E0000\0" \
+"vx_romfssize=0x20000\0" \
+"vx_memtop=0x8FBEF000\0" \
+"loadromfs=mmc read ${vx_romfsbase} 700 100\0" \
+"autoload=0\0" \
+"loadaddr=0x80100000\0" \
+"logoaddr=0x82000000\0" \
+"defaultARlen=0x8000\0" \
+"loaddefaultAR=mmc read ${loadaddr} 800 ${defaultARlen}\0" \
+"defaultAR=run loadromfs; run loaddefaultAR; go ${loadaddr}\0" \
+"logo0=fatload mmc 0:1 ${logoaddr} SYSTEM/ADDON/Bootlogo/Bootlogo.bmp.gz && " \
+	"bmp display ${logoaddr} 0 0\0" \
+"logo1=fatload mmc 0:1 ${logoaddr} SYSTEM/BASE/Bootlogo/Bootlogo.bmp.gz && " \
+	"bmp display ${logoaddr} 0 0\0" \
+"mmcboot=echo booting AR from eMMC-flash ...; "\
+	"run logo0 || run logo1; " \
+	"run loadromfs; " \
+	"fatload mmc 0:1 ${loadaddr} arimg && go ${loadaddr}; " \
+	"run defaultAR;\0" \
+"netboot=echo booting AR from network ...; " \
+	"run loadromfs; " \
+	"tftp ${loadaddr} arimg && go ${loadaddr}; " \
+	"puts 'networkboot failed!';\0" \
+"usbupdate=echo updating u-boot from usb ...; " \
+	"usb start; " \
+	"fatload usb 0 0x80000000 updateubootusb.img && source; " \
+	"puts 'usbupdate failed!'\0" \
+"netscript=echo running script from network (tftp) ...; " \
+	"tftp 0x80000000 netscript.img && source; " \
+	"puts 'netscript load failed!'\0" \
+"netupdate=tftp ${loadddr} MLO && mmc write ${loadaddr} 100 100; " \
+	"tftp ${loadaddr} u-boot.img && mmc write ${loadaddr} 300 300\0" \
+"netupdatedefaultAR=echo updating defaultAR from network (tftp) ...; " \
+	"if tftp 0x80100000 arimg.bin; " \
+	"then mmc write 0x80100000 800 ${defaultARlen}; " \
+	"else setcurs 1 8; puts 'defAR update failed (tftp)!'; fi;\0" \
+"netupdateROMFS=echo updating romfs from network (tftp) ...; " \
+	"if tftp 0x80100000 romfs.bin; " \
+	"then mmc write 0x80100000 700 100; " \
+	"else setcurs 1 8; puts 'romfs update failed (tftp)!'; fi;\0"
+
 #endif /* !CONFIG_SPL_BUILD*/
 
 #define CONFIG_BOOTCOMMAND \
 	"run usbupdate;"
-#define CONFIG_BOOTDELAY		1 /* TODO: f?r release auf 0 setzen */
+#define CONFIG_BOOTDELAY		0
 
 /* undefine command which we not need here */
 #undef	CONFIG_BOOTM_NETBSD
-- 
1.7.9.5

  parent reply	other threads:[~2015-01-30 13:25 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-30 13:25 [U-Boot] [PATCH 01/21] drivers/video/am335x-fb: Add possibility to wait for stable power/picture Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 02/21] common/lcd: Add command for setting cursor within lcd-framework Hannes Petermaier
2015-02-01 14:48   ` Nikita Kiryanov
2015-02-02  7:32     ` Hannes Petermaier
2015-02-03 11:52       ` Nikita Kiryanov
2015-01-30 13:25 ` [U-Boot] [PATCH 03/21] common/lcd: Add command for writing to lcd-display Hannes Petermaier
2015-02-01 14:53   ` Nikita Kiryanov
2015-02-02  7:37     ` Hannes Petermaier
2015-02-03 11:53       ` Nikita Kiryanov
2015-01-30 13:25 ` [U-Boot] [PATCH 04/21] board/BuR/common: Take usage of am335x LCD-Display Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 05/21] board/BuR/common: try to setup cpsw mac-address from the devicetree Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 06/21] board/BuR/tseries: Enable HW-Watchdog Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 07/21] board/BuR/tseries: Enable U-Boot BOOTCOUNT feature Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 08/21] board/BuR/tseries: Enable EXT4 support Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 09/21] board/BuR/tseries: Change pinmux for GPIO2_28 from GPIO to PWM-Timeroutput Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 10/21] board/BuR/tseries: Chg pinmux - use free NAND Pins in non NAND-config as GPIO Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 11/21] board/BuR/tseries: Chg Pinmux - enable UART1 pins Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 12/21] board/BuR/common: Introduce Network Console and common environment for it Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 13/21] board/BuR/common: Enable CONFIG_CMD_TIME Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 14/21] board/BuR/common: Add support for displaying BMP on LCD Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 15/21] board/BuR/tseries: Rework default-environment settings Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 16/21] board/BuR/tseries: cosmetic changes Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 17/21] board/BuR/kwb: switch to board HW-Rev3 Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 18/21] board/BuR/kwb: Support booting Linux Hannes Petermaier
2015-01-30 13:25 ` Hannes Petermaier [this message]
2015-01-30 13:25 ` [U-Boot] [PATCH 20/21] board/BuR/kwb: Form a bootline for vxWorks Hannes Petermaier
2015-01-30 13:25 ` [U-Boot] [PATCH 21/21] board/BuR/kwb: Support modify bootcmd through reset-controller Hannes Petermaier

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=1422624324-15431-19-git-send-email-oe5hpm@oevsv.at \
    --to=oe5hpm@oevsv.at \
    --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.