From: "Cédric Le Goater" <clg@fr.ibm.com>
To: Cyril Bur <cyrilbur@gmail.com>
Cc: Joel Stanley <joel@jms.id.au>, openbmc@lists.ozlabs.org
Subject: Re: [PATCH openbmc v3 1/2] meta-phosphor/u-boot: Move to newer version
Date: Mon, 11 Apr 2016 17:12:40 +0200 [thread overview]
Message-ID: <570BBEE8.6090703@fr.ibm.com> (raw)
In-Reply-To: <20160411134218.68c9d659@camb691>
On 04/11/2016 05:42 AM, Cyril Bur wrote:
> On Tue, 5 Apr 2016 17:25:09 +0200
> Cédric Le Goater <clg@fr.ibm.com> wrote:
>
>> Hello,
>>
>> I have given some time recently to the OpenBmc U-Boot and came up with
>> a first initial port of the aspeed code on a recent version, v2016.03.
>> Here is the tree :
>>
>> https://github.com/legoater/u-boot/commits/v2016.03-aspeed-openbmc
>>
>> There is still quite a lot of cleanup to do, the code has warnings, some
>> configure defines are probably obsolete. This is clearly not finished yet.
>> But it is usable.
>>
>> These compilers on jessie generate a u-boot.bin file which boots a
>> palmetto bmc with success :
>>
>> gcc version 5.2.0 (crosstool-NG crosstool-ng-1.22.0)
>> gcc version 4.8.4 20141219 (release) (4.8.4-1+11-1)
>>
>> So if some of you has time (and a flash programmer), could you please
>> give it a try ? I will be glad to have positive feedback. You can curse
>> me if not :)
>
> Hi Cedric,
>
> Took me a couple of days to get around to actually booting it, sorry. Now
> that I've done it though, nice work!
>
> DRAM Init-DDR3
> CBR0-1357135670123456701234567
> CBR134Done
>
>
> U-Boot 2016.03 (Apr 08 2016 - 14:53:05 +1000)
>
> I2C: ready
> DRAM: 256 MiB
> WARNING: Caches not enabled
> Flash: SPI Flash ID: 19ba20
> 32 MiB
> In: serial
> Out: serial
> Err: serial
> H/W: AST2400 series chip Rev. 01
> Watchdog: 300s
> Net: aspeednic#0
> autoboot in 10 seconds (stop with 'Delete' key)...
>
> It appears to work how we want it. By default it just boots exactly as before.
> I tftped a kernel and initramfs and that works fine.
>
> Thumbs up from me,
Hello Cyril,
Thanks for testing !
Here's a patch below to integrate the branch in the openbmc build.
This is a new build framework for me, so may be there is a better
way to do so.
The resulting flash image was tested on a palmetto.
Cheers,
C.
From: Cédric Le Goater <clg@fr.ibm.com>
Subject: [PATCH] uboot: use v2016.03-aspeed-openbmc branch
Date: Mon, 11 Apr 2016 16:49:07 +0200
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Signed-off-by: Cédric Le Goater <clg@fr.ibm.com>
---
meta-openbmc-bsp/meta-aspeed/meta-ast2400/recipes-bsp/u-boot/u-boot-fw-utils_2016.03%.bbappend | 13 ++
meta-openbmc-bsp/meta-aspeed/meta-ast2400/recipes-bsp/u-boot/u-boot_2016.03%.bbappend | 10 +
meta-phosphor/common/recipes-bsp/u-boot/u-boot-fw-utils_2016.03.bb | 54 ++++++++++
meta-phosphor/common/recipes-bsp/u-boot/u-boot_2016.03.bb | 31 +++++
4 files changed, 108 insertions(+)
Index: openbmc.git/meta-phosphor/common/recipes-bsp/u-boot/u-boot-fw-utils_2016.03.bb
===================================================================
--- /dev/null
+++ openbmc.git/meta-phosphor/common/recipes-bsp/u-boot/u-boot-fw-utils_2016.03.bb
@@ -0,0 +1,54 @@
+#require recipes-bsp/u-boot/u-boot.inc
+
+SUMMARY = "U-Boot bootloader fw_printenv/setenv utilities"
+SECTION = "bootloader"
+DEPENDS = "mtd-utils"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://Licenses/README;md5=a2c678cfd4a4d97135585cad908541c6"
+
+# This revision corresponds to the tag "v2013.07"
+# We use the revision in order to avoid having to fetch it from the
+# repo during parse
+# SRCREV = "62c175fbb8a0f9a926c88294ea9f7e88eb898f6c"
+SRCREV="28aaabf6d1ebd144755287cef417bb59a50f0191"
+
+PV = "v2016.03+git${SRCPV}"
+
+UBRANCH = "v2016.03-aspeed-openbmc"
+SRC_URI = "git://git@github.com/legoater/u-boot.git;branch=${UBRANCH};protocol=https"
+S = "${WORKDIR}/git"
+
+#INSANE_SKIP_${PN} = "already-stripped"
+#EXTRA_OEMAKE_class-target = 'CROSS_COMPILE=${TARGET_PREFIX} CC="${CC} ${CFLAGS} ${LDFLAGS}" V=1'
+#EXTRA_OEMAKE_class-cross = 'ARCH=${TARGET_ARCH} CC="${CC} ${CFLAGS} ${LDFLAGS}" V=1'
+EXTRA_OEMAKE = 'CROSS_COMPILE="${TARGET_PREFIX}" CC="${CC} ${CFLAGS} ${LDFLAGS}" STRIP=true V=1'
+
+inherit uboot-config
+
+do_compile () {
+ oe_runmake ${MACHINE}_defconfig
+ oe_runmake env
+}
+
+do_install () {
+ install -d ${D}${base_sbindir}
+ install -d ${D}${sysconfdir}
+ install -m 755 ${S}/tools/env/fw_printenv ${D}${base_sbindir}/fw_printenv
+ ln -sf fw_printenv ${D}${base_sbindir}/fw_setenv
+ install -m 0644 ${S}/tools/env/fw_env.config ${D}${sysconfdir}/fw_env.config
+}
+
+#do_install_class-cross () {
+# install -d ${D}${bindir_cross}
+# install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_printenv
+# install -m 755 ${S}/tools/env/fw_printenv ${D}${bindir_cross}/fw_setenv
+#}
+
+#SYSROOT_PREPROCESS_FUNCS_class-cross = "uboot_fw_utils_cross"
+#uboot_fw_utils_cross() {
+# sysroot_stage_dir ${D}${bindir_cross} ${SYSROOT_DESTDIR}${bindir_cross}
+#}
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+#BBCLASSEXTEND = "cross native"
Index: openbmc.git/meta-phosphor/common/recipes-bsp/u-boot/u-boot_2016.03.bb
===================================================================
--- /dev/null
+++ openbmc.git/meta-phosphor/common/recipes-bsp/u-boot/u-boot_2016.03.bb
@@ -0,0 +1,31 @@
+require recipes-bsp/u-boot/u-boot.inc
+
+# To build u-boot for your machine, provide the following lines in your machine
+# config, replacing the assignments as appropriate for your machine.
+# UBOOT_MACHINE = "omap3_beagle_config"
+# UBOOT_ENTRYPOINT = "0x80008000"
+# UBOOT_LOADADDRESS = "0x80008000"
+
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://Licenses/README;md5=a2c678cfd4a4d97135585cad908541c6"
+
+# We use the revision in order to avoid having to fetch it from the repo during parse
+SRCREV = "28aaabf6d1ebd144755287cef417bb59a50f0191"
+
+PV = "v2016.03+git${SRCPV}"
+
+UBRANCH = "v2016.03-aspeed-openbmc"
+SRC_URI = "git://git@github.com/legoater/u-boot.git;branch=${UBRANCH};protocol=https"
+
+S = "${WORKDIR}/git"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+EXTRA_OEMAKE = 'CROSS_COMPILE="${TARGET_PREFIX}" CC="${CC} ${CFLAGS} ${LDFLAGS}" STRIP=true V=1'
+
+do_compile () {
+ oe_runmake ${MACHINE}_defconfig
+ oe_runmake
+}
+
+
Index: openbmc.git/meta-openbmc-bsp/meta-aspeed/meta-ast2400/recipes-bsp/u-boot/u-boot-fw-utils_2016.03%.bbappend
===================================================================
--- /dev/null
+++ openbmc.git/meta-openbmc-bsp/meta-aspeed/meta-ast2400/recipes-bsp/u-boot/u-boot-fw-utils_2016.03%.bbappend
@@ -0,0 +1,13 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
+
+SRC_URI += "file://fw_env.config"
+SRC_URI += "file://config.patch"
+
+do_install_append() {
+ if [ -e ${WORKDIR}/fw_env.config ] ; then
+ install -d ${D}${sysconfdir}
+ install -m 644 ${WORKDIR}/fw_env.config ${D}${sysconfdir}/fw_env.config
+ fi
+}
+
+BBCLASSEXTEND += "native"
Index: openbmc.git/meta-openbmc-bsp/meta-aspeed/meta-ast2400/recipes-bsp/u-boot/u-boot_2016.03%.bbappend
===================================================================
--- /dev/null
+++ openbmc.git/meta-openbmc-bsp/meta-aspeed/meta-ast2400/recipes-bsp/u-boot/u-boot_2016.03%.bbappend
@@ -0,0 +1,10 @@
+FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
+
+SRC_URI += "file://fw_env.config"
+SRC_URI += "file://config.patch"
+
+# Do not install u-boot in rootfs
+#do_install[postfuncs] += "remove_uboot_from_rootfs"
+#remove_uboot_from_rootfs() {
+# rm -rf ${D}/boot/u-boot*
+#}
next prev parent reply other threads:[~2016-04-11 15:12 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-04 14:00 [PATCH openbmc v3 0/2] Revert "Back off GCC to 4.9.3" OpenBMC Patches
2016-04-04 14:00 ` [PATCH openbmc v3 1/2] meta-phosphor/u-boot: Move to newer version OpenBMC Patches
2016-04-05 15:25 ` Cédric Le Goater
2016-04-11 3:42 ` Cyril Bur
2016-04-11 15:12 ` Cédric Le Goater [this message]
2016-04-04 14:00 ` [PATCH openbmc v3 2/2] Revert "Back off GCC to 4.9.3" OpenBMC Patches
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=570BBEE8.6090703@fr.ibm.com \
--to=clg@fr.ibm.com \
--cc=cyrilbur@gmail.com \
--cc=joel@jms.id.au \
--cc=openbmc@lists.ozlabs.org \
/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.