Return-Path: Received: from mail-gg0-f182.google.com (mail-gg0-f182.google.com [209.85.161.182]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id AE2B6E0083C for ; Mon, 30 Dec 2013 20:12:50 -0800 (PST) Received: by mail-gg0-f182.google.com with SMTP id e26so1986152gga.41 for ; Mon, 30 Dec 2013 20:12:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=GTY+Lz9JMLoTmmZWYT4pqq0bD0t1lvIEWn1ttsBHK+s=; b=MthYfasf23XBorAIgcpNhazqw3xQEeltdhs47h8JCycKAWViwCyk4ROjZACLVFrRcc q7OWMKz16WRiwo+ba2BOM9iAQOdU4RURtvWqBIFuf5fij52WGTiqP95E5kM1fUhhuv7H pPXZ9pKrw0BZ4x3xQsigumC6sbLMggky55CV4VQU7vlM1iAk0wquv3ifnKTDTJt8sgEY 0qDrPT9lf3wYsi247q+WzPj/wZZ/5LShKjqZSsGuSKHlRNMoJCIgOQs5NOgqapCDwwLh DOh5Z+tLpqjv0KEInxNUBmYsZflGbOzei92pmgtrDnAJ/GrCnM8bCglD63c43jj0kDI+ yDgw== X-Received: by 10.236.82.46 with SMTP id n34mr47242086yhe.25.1388463169943; Mon, 30 Dec 2013 20:12:49 -0800 (PST) Received: from localhost.localdomain ([75.76.228.60]) by mx.google.com with ESMTPSA id e50sm64535235yhd.26.2013.12.30.20.12.48 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 30 Dec 2013 20:12:49 -0800 (PST) From: John Weber To: meta-freescale@yoctoproject.org Date: Mon, 30 Dec 2013 22:12:41 -0600 Message-Id: <1388463161-17349-3-git-send-email-rjohnweber@gmail.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1388463161-17349-1-git-send-email-rjohnweber@gmail.com> References: <1388463161-17349-1-git-send-email-rjohnweber@gmail.com> Subject: [meta-fsl-arm-extra][PATCH 2/2] u-boot-fslc: make wandboard use zImage by default X-BeenThere: meta-freescale@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Usage and development list for the meta-fsl-* layers List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 31 Dec 2013 04:12:50 -0000 Change the default environment to use zImage instead of uImage, because using zImage does not require a LOADADDR assignment when building the kernel to be consistent with the loadaddr environment variable in u-boot, decreasing the chance for error. This requires changes to the default environment to load a file named zImage instead of uImage, and to use the 'bootz' command instead of 'bootm' when booting the kernel. Also included in this patch is a change to fdt_addr to move it to 0x18000000, to avoid the space needed to load the kernel. Signed-off-by: John Weber --- ...ard-Set-default-environment-to-use-zImage.patch | 95 ++++++++++++++++++++ recipes-bsp/u-boot/u-boot-fslc_2013.10.bbappend | 6 ++ 2 files changed, 101 insertions(+) create mode 100644 recipes-bsp/u-boot/u-boot-fslc/0001-wandboard-Set-default-environment-to-use-zImage.patch create mode 100644 recipes-bsp/u-boot/u-boot-fslc_2013.10.bbappend diff --git a/recipes-bsp/u-boot/u-boot-fslc/0001-wandboard-Set-default-environment-to-use-zImage.patch b/recipes-bsp/u-boot/u-boot-fslc/0001-wandboard-Set-default-environment-to-use-zImage.patch new file mode 100644 index 0000000..3b8b71a --- /dev/null +++ b/recipes-bsp/u-boot/u-boot-fslc/0001-wandboard-Set-default-environment-to-use-zImage.patch @@ -0,0 +1,95 @@ +From c41e1f6ac541aa5c76328633b7776241e57d8fdd Mon Sep 17 00:00:00 2001 +From: John Weber +Date: Mon, 30 Dec 2013 13:37:48 -0600 +Subject: [PATCH] wandboard: Set default environment to use zImage + +Upstream-Status: pending + +Signed-off-by: John Weber +--- + include/configs/wandboard.h | 22 +++++++++++----------- + 1 file changed, 11 insertions(+), 11 deletions(-) + +diff --git a/include/configs/wandboard.h b/include/configs/wandboard.h +index 442a984..7f702d9 100644 +--- a/include/configs/wandboard.h ++++ b/include/configs/wandboard.h +@@ -107,13 +107,13 @@ + + #define CONFIG_EXTRA_ENV_SETTINGS \ + "script=boot.scr\0" \ +- "uimage=uImage\0" \ ++ "image=zImage\0" \ + "console=ttymxc0\0" \ + "splashpos=m,m\0" \ + "fdt_high=0xffffffff\0" \ + "initrd_high=0xffffffff\0" \ + "fdt_file=" CONFIG_DEFAULT_FDT_FILE "\0" \ +- "fdt_addr=0x11000000\0" \ ++ "fdt_addr=0x18000000\0" \ + "boot_fdt=try\0" \ + "ip_dyn=yes\0" \ + "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \ +@@ -139,22 +139,22 @@ + "fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \ + "bootscript=echo Running bootscript from mmc ...; " \ + "source\0" \ +- "loaduimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${uimage}\0" \ ++ "loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \ + "loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \ + "mmcboot=echo Booting from mmc ...; " \ + "run mmcargs; " \ + "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \ + "if run loadfdt; then " \ +- "bootm ${loadaddr} - ${fdt_addr}; " \ ++ "bootz ${loadaddr} - ${fdt_addr}; " \ + "else " \ + "if test ${boot_fdt} = try; then " \ +- "bootm; " \ ++ "bootz; " \ + "else " \ + "echo WARN: Cannot load the DT; " \ + "fi; " \ + "fi; " \ + "else " \ +- "bootm; " \ ++ "bootz; " \ + "fi;\0" \ + "netargs=setenv bootargs console=${console},${baudrate} " \ + "root=/dev/nfs " \ +@@ -166,19 +166,19 @@ + "else " \ + "setenv get_cmd tftp; " \ + "fi; " \ +- "${get_cmd} ${uimage}; " \ ++ "${get_cmd} ${image}; " \ + "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \ + "if ${get_cmd} ${fdt_addr} ${fdt_file}; then " \ +- "bootm ${loadaddr} - ${fdt_addr}; " \ ++ "bootz ${loadaddr} - ${fdt_addr}; " \ + "else " \ + "if test ${boot_fdt} = try; then " \ +- "bootm; " \ ++ "bootz; " \ + "else " \ + "echo WARN: Cannot load the DT; " \ + "fi; " \ + "fi; " \ + "else " \ +- "bootm; " \ ++ "bootz; " \ + "fi;\0" + + #define CONFIG_BOOTCOMMAND \ +@@ -186,7 +186,7 @@ + "if run loadbootscript; then " \ + "run bootscript; " \ + "else " \ +- "if run loaduimage; then " \ ++ "if run loadimage; then " \ + "run mmcboot; " \ + "else run netboot; " \ + "fi; " \ +-- +1.7.9.5 + diff --git a/recipes-bsp/u-boot/u-boot-fslc_2013.10.bbappend b/recipes-bsp/u-boot/u-boot-fslc_2013.10.bbappend new file mode 100644 index 0000000..3ff3fc8 --- /dev/null +++ b/recipes-bsp/u-boot/u-boot-fslc_2013.10.bbappend @@ -0,0 +1,6 @@ +FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" + +SRC_URI_append = " \ + file://0001-wandboard-Set-default-environment-to-use-zImage.patch \ +" + -- 1.7.9.5