Patchwork [U-Boot,v2,08/16] km/common: introduce $uimage variable

login
register
mail settings
Submitter Holger Brunck
Date Jan. 21, 2013, 1:55 p.m.
Message ID <1358776528-27254-8-git-send-email-holger.brunck@keymile.com>
Download mbox | patch
Permalink /patch/214162/
State Awaiting Upstream
Delegated to: Kim Phillips
Headers show

Comments

Holger Brunck - Jan. 21, 2013, 1:55 p.m.
From: Andreas Huber <andreas.huber@keymile.com>

Replace the hardcoded string with a variable. If CONFIG_NAND_ECC_BCH is
set we use a specific name for the uImage (ecc_bch_uImage).

Signed-off-by: Andreas Huber <andreas.huber@keymile.com>
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
---
Changes for v2:
    - none

 include/configs/km/keymile-common.h |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

Patch

diff --git a/include/configs/km/keymile-common.h b/include/configs/km/keymile-common.h
index f64748e..ae88759 100644
--- a/include/configs/km/keymile-common.h
+++ b/include/configs/km/keymile-common.h
@@ -148,6 +148,12 @@ 
 	"ubi part " CONFIG_KM_UBI_PARTITION_NAME_APP "; fi\0"
 #endif /* CONFIG_KM_UBI_PARTITION_NAME_APP */
 
+#ifdef CONFIG_NAND_ECC_BCH
+#define CONFIG_KM_UIMAGE_NAME "ecc_bch_uImage\0"
+#else
+#define CONFIG_KM_UIMAGE_NAME "uImage\0"
+#endif
+
 /*
  * boottargets
  * - set 'subbootcmds'
@@ -210,9 +216,10 @@ 
  */
 #define CONFIG_KM_DEF_ENV_FLASH_BOOT					\
 	"cramfsaddr=" __stringify(CONFIG_KM_CRAMFS_ADDR) "\0"		\
-	"cramfsloadkernel=cramfsload ${load_addr_r} uImage\0"		\
+	"cramfsloadkernel=cramfsload ${load_addr_r} ${uimage}\0"	\
 	"ubicopy=ubi read "__stringify(CONFIG_KM_CRAMFS_ADDR)		\
 			" bootfs${boot_bank}\0"				\
+	"uimage=" CONFIG_KM_UIMAGE_NAME					\
 	CONFIG_KM_DEV_ENV_FLASH_BOOT_UBI
 
 /*