summaryrefslogtreecommitdiffstats
path: root/meta-phosphor/common/recipes-bsp
diff options
context:
space:
mode:
authorAdriana Kobylak <anoo@us.ibm.com>2017-08-19 09:32:18 -0500
committerPatrick Williams <patrick@stwcx.xyz>2017-08-21 23:19:54 +0000
commit57ef7224ca9ff6cadbdf3c8577c71263055c6717 (patch)
treec08dc86d2eb476f1fa15316f6cac88bc2b09daab /meta-phosphor/common/recipes-bsp
parent65007350889b5bb559b81a39891b05b1f3ec5086 (diff)
downloadtalos-openbmc-57ef7224ca9ff6cadbdf3c8577c71263055c6717.tar.gz
talos-openbmc-57ef7224ca9ff6cadbdf3c8577c71263055c6717.zip
u-boot: Reorder and update patches and bootenv fixes
Yocto does not apply patches by name, but instead it applies them in the order that files are added to the SRC_URI variable. Therefore move the common patch file to the top in the u-boot.inc file, followed by the optional patches that are enabled via machine feature. Update the patches so that they apply on that order. Fix the loadaddr env variable to convert from an int. Escape bootargs variables to keep the variable names and not have them replaced during build time. Change-Id: I28d469c643d66e4b11225f37c3331e471676aec5 Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
Diffstat (limited to 'meta-phosphor/common/recipes-bsp')
-rw-r--r--meta-phosphor/common/recipes-bsp/u-boot/files/0001-config-ast-common-hack-bootopts.patch10
-rw-r--r--meta-phosphor/common/recipes-bsp/u-boot/files/0004-config-ast-common-ubi-bootops.patch9
-rw-r--r--meta-phosphor/common/recipes-bsp/u-boot/u-boot.inc4
3 files changed, 12 insertions, 11 deletions
diff --git a/meta-phosphor/common/recipes-bsp/u-boot/files/0001-config-ast-common-hack-bootopts.patch b/meta-phosphor/common/recipes-bsp/u-boot/files/0001-config-ast-common-hack-bootopts.patch
index d168769fc..f0895cec8 100644
--- a/meta-phosphor/common/recipes-bsp/u-boot/files/0001-config-ast-common-hack-bootopts.patch
+++ b/meta-phosphor/common/recipes-bsp/u-boot/files/0001-config-ast-common-hack-bootopts.patch
@@ -9,7 +9,7 @@ Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
1 file changed, 6 insertions(+)
diff --git a/include/configs/ast-common.h b/include/configs/ast-common.h
-index 110c780070..6f2a50b854 100644
+index 15e1db4..e7fa6ed 100644
--- a/include/configs/ast-common.h
+++ b/include/configs/ast-common.h
@@ -84,7 +84,10 @@
@@ -23,9 +23,9 @@ index 110c780070..6f2a50b854 100644
#define CONFIG_AST_SPI_NOR /* AST SPI NOR Flash */
#define CONFIG_FMC_CS 1
-@@ -96,11 +99,14 @@
- #define CONFIG_ENV_OFFSET 0x60000 /* environment starts here */
- #define CONFIG_ENV_SIZE 0x20000 /* Total Size of Environment Sector */
+@@ -99,11 +102,14 @@
+ #define CONFIG_ENV_SIZE 0x10000 /* Total Size of Environment Sector */
+ #define CONFIG_ENV_SIZE_REDUND 0x10000
+#if 0
#define CONFIG_BOOTCOMMAND \
@@ -39,5 +39,5 @@ index 110c780070..6f2a50b854 100644
#define ASPEED_ENV_SETTINGS \
--
-2.13.0
+1.8.2.2
diff --git a/meta-phosphor/common/recipes-bsp/u-boot/files/0004-config-ast-common-ubi-bootops.patch b/meta-phosphor/common/recipes-bsp/u-boot/files/0004-config-ast-common-ubi-bootops.patch
index d0185655a..4e465ced5 100644
--- a/meta-phosphor/common/recipes-bsp/u-boot/files/0004-config-ast-common-ubi-bootops.patch
+++ b/meta-phosphor/common/recipes-bsp/u-boot/files/0004-config-ast-common-ubi-bootops.patch
@@ -9,7 +9,7 @@ Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
1 file changed, 18 insertions(+), 2 deletions(-)
diff --git a/include/configs/ast-common.h b/include/configs/ast-common.h
-index b8b1f01..9c12f1f 100644
+index e7fa6ed..578de2c 100644
--- a/include/configs/ast-common.h
+++ b/include/configs/ast-common.h
@@ -84,10 +84,16 @@
@@ -38,20 +38,21 @@ index b8b1f01..9c12f1f 100644
#define CONFIG_ENV_OFFSET 0x60000 /* environment starts here */
#define CONFIG_ENV_OFFSET_REDUND 0x70000
-@@ -109,11 +116,20 @@
+@@ -109,12 +116,21 @@
" bootm 20080000; else bootm 20080000 20300000; " \
"fi"
#endif
-#define CONFIG_BOOTCOMMAND "fdt addr 20080000; bootm 20080000"
+#define CONFIG_BOOTCOMMAND "run set_bootargs; run obmc_bootcmd"
#define CONFIG_ENV_OVERWRITE
+
#define ASPEED_ENV_SETTINGS \
+ "ubiblock=0,1 \0" \
+ "root=/dev/ubiblock0_1 \0" \
+ "kernelname=kernel0 \0" \
+ "kernelname=kernel0 \0" \
-+ "loadaddr=" CONFIG_LOADADDR "\0" \
-+ "set_bootargs=setenv bootargs " CONFIG_BOOTARGS " ubi.block=${ubiblock} root=${root} \0" \
++ "loadaddr=" __stringify(CONFIG_LOADADDR) "\0" \
++ "set_bootargs=setenv bootargs " CONFIG_BOOTARGS " ubi.block=\${ubiblock} root=\${root} \0" \
+ "obmc_bootcmd=ubi part obmc-ubi; ubi read ${loadaddr} ${kernelname}; bootm ${loadaddr} \0" \
"verify=yes\0" \
"spi_dma=yes\0" \
diff --git a/meta-phosphor/common/recipes-bsp/u-boot/u-boot.inc b/meta-phosphor/common/recipes-bsp/u-boot/u-boot.inc
index 5ccbea58c..1089ec40c 100644
--- a/meta-phosphor/common/recipes-bsp/u-boot/u-boot.inc
+++ b/meta-phosphor/common/recipes-bsp/u-boot/u-boot.inc
@@ -4,6 +4,8 @@ SRCREV = "a5e0a21ed4b62ab4d8ff09f70b751db0f46ddaac"
UBRANCH = "v2016.07-aspeed-openbmc"
SRC_URI = "git://git@github.com/openbmc/u-boot.git;branch=${UBRANCH};protocol=https"
+SRC_URI += "file://0001-configs-ast-Add-redundnant-env.patch"
+
SRC_URI += "${@bb.utils.contains('MACHINE_FEATURES', 'obmc-ubi-fs', \
'file://0001-config-ast-common-hack-bootopts.patch \
file://0002-Add-MTD-support-to-Aspeed-Flash-driver.patch \
@@ -11,5 +13,3 @@ SRC_URI += "${@bb.utils.contains('MACHINE_FEATURES', 'obmc-ubi-fs', \
file://0004-config-ast-common-ubi-bootops.patch', '', d)}"
PV = "v2016.07+git${SRCPV}"
-
-SRC_URI += "file://0001-configs-ast-Add-redundnant-env.patch"
OpenPOWER on IntegriCloud