diff options
author | Samuli Piippo <samuli.piippo@digia.com> | 2014-10-17 15:27:20 +0300 |
---|---|---|
committer | Samuli Piippo <samuli.piippo@theqtcompany.com> | 2014-11-12 12:41:18 +0200 |
commit | b5742f386fd5b2a713f19b9a311d3c83b2cd2b01 (patch) | |
tree | 2285ef2a704d6606bc728a59d50484ddb5b185b0 /meta-toradex-extras/recipes | |
parent | 2716404d718cb200b0ed42c7ef24b0c89ca4d049 (diff) | |
download | meta-boot2qt-b5742f386fd5b2a713f19b9a311d3c83b2cd2b01.tar.gz |
toradex: support for the new v2.3 toradex release
Kernel is now using dtb, include it in the bootfs.
U-boot update to make sdboot the default.
Include u-boot script for updating the u-boot.
Change-Id: I7e4f01ad3d903fbf807c5bf3904a9f955a59e97a
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@digia.com>
Diffstat (limited to 'meta-toradex-extras/recipes')
4 files changed, 139 insertions, 0 deletions
diff --git a/meta-toradex-extras/recipes/u-boot/u-boot-script-toradex.bb b/meta-toradex-extras/recipes/u-boot/u-boot-script-toradex.bb new file mode 100644 index 0000000..4254062 --- /dev/null +++ b/meta-toradex-extras/recipes/u-boot/u-boot-script-toradex.bb | |||
@@ -0,0 +1,58 @@ | |||
1 | ############################################################################# | ||
2 | ## | ||
3 | ## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). | ||
4 | ## | ||
5 | ## This file is part of the Qt Enterprise Embedded Scripts of the Qt | ||
6 | ## framework. | ||
7 | ## | ||
8 | ## $QT_BEGIN_LICENSE$ | ||
9 | ## Commercial License Usage Only | ||
10 | ## Licensees holding valid commercial Qt license agreements with Digia | ||
11 | ## with an appropriate addendum covering the Qt Enterprise Embedded Scripts, | ||
12 | ## may use this file in accordance with the terms contained in said license | ||
13 | ## agreement. | ||
14 | ## | ||
15 | ## For further information use the contact form at | ||
16 | ## http://qt.digia.com/contact-us. | ||
17 | ## | ||
18 | ## | ||
19 | ## $QT_END_LICENSE$ | ||
20 | ## | ||
21 | ############################################################################# | ||
22 | |||
23 | LICENSE = "CLOSED" | ||
24 | DEPENDS = "u-boot-mkimage-native" | ||
25 | |||
26 | PV = "v2.3" | ||
27 | |||
28 | SRC_URI = "file://flash_mmc.scr" | ||
29 | |||
30 | inherit deploy | ||
31 | |||
32 | UPDATESCRIPT = "${WORKDIR}/flash_mmc.scr" | ||
33 | |||
34 | do_mkimage () { | ||
35 | uboot-mkimage -A arm -O linux -T script -C none -a 0 -e 0 \ | ||
36 | -n "update script" -d ${UPDATESCRIPT} \ | ||
37 | flash_mmc.img | ||
38 | } | ||
39 | |||
40 | addtask mkimage after do_compile before do_install | ||
41 | |||
42 | do_deploy () { | ||
43 | install -d ${DEPLOYDIR} | ||
44 | install ${S}/flash_mmc.img ${DEPLOYDIR}/flash_mmc-${MACHINE}-${PV}-${PR}.img | ||
45 | |||
46 | cd ${DEPLOYDIR} | ||
47 | rm -f flash_mmc-${MACHINE}.img | ||
48 | ln -sf flash_mmc-${MACHINE}-${PV}-${PR}.img flash_mmc-${MACHINE}.img | ||
49 | } | ||
50 | |||
51 | addtask deploy after do_install before do_build | ||
52 | |||
53 | do_compile[noexec] = "1" | ||
54 | do_install[noexec] = "1" | ||
55 | do_populate_sysroot[noexec] = "1" | ||
56 | |||
57 | PACKAGE_ARCH = "${MACHINE_ARCH}" | ||
58 | COMPATIBLE_MACHINE = "(apalis-imx6)" | ||
diff --git a/meta-toradex-extras/recipes/u-boot/u-boot-script-toradex/flash_mmc.scr b/meta-toradex-extras/recipes/u-boot/u-boot-script-toradex/flash_mmc.scr new file mode 100644 index 0000000..5b7dc80 --- /dev/null +++ b/meta-toradex-extras/recipes/u-boot/u-boot-script-toradex/flash_mmc.scr | |||
@@ -0,0 +1,2 @@ | |||
1 | setenv update_uboot 'fatload mmc ${drive}:1 ${loadaddr} u-boot.imx && setexpr blkcnt $filesize + 0x1ff && setexpr blkcnt ${blkcnt} / 0x200 && mmc dev 0 && mmc write ${loadaddr} 2 ${blkcnt}' | ||
2 | echo 'enter "run update_uboot" to update the uboot' | ||
diff --git a/meta-toradex-extras/recipes/u-boot/u-boot-toradex-fsl/0001-Update-default-args-for-apalis-imx6.patch b/meta-toradex-extras/recipes/u-boot/u-boot-toradex-fsl/0001-Update-default-args-for-apalis-imx6.patch new file mode 100644 index 0000000..c7f0f9b --- /dev/null +++ b/meta-toradex-extras/recipes/u-boot/u-boot-toradex-fsl/0001-Update-default-args-for-apalis-imx6.patch | |||
@@ -0,0 +1,53 @@ | |||
1 | From 7872f8e770a202f41fbcf0372b27eb3669c433a1 Mon Sep 17 00:00:00 2001 | ||
2 | From: Samuli Piippo <samuli.piippo@digia.com> | ||
3 | Date: Mon, 27 Oct 2014 14:53:25 +0200 | ||
4 | Subject: [PATCH] Update default args for apalis imx6 | ||
5 | |||
6 | Boot from sd card by default, disable kernel logs from tty1, and | ||
7 | disable cursor blinking. | ||
8 | --- | ||
9 | include/configs/apalis-imx6.h | 15 ++++++++------- | ||
10 | 1 file changed, 8 insertions(+), 7 deletions(-) | ||
11 | |||
12 | diff --git a/include/configs/apalis-imx6.h b/include/configs/apalis-imx6.h | ||
13 | index 3fb17e2..728c5dd 100644 | ||
14 | --- a/include/configs/apalis-imx6.h | ||
15 | +++ b/include/configs/apalis-imx6.h | ||
16 | @@ -205,18 +205,19 @@ | ||
17 | "&& setenv dtbparam \" - ${fdt_addr_r}\" && true\0" | ||
18 | |||
19 | #define SD_BOOTCMD \ | ||
20 | - "sdargs=ip=off root=/dev/mmcblk1p2 rw,noatime rootfstype=ext3 " \ | ||
21 | - "rootwait\0" \ | ||
22 | + "drive=2\0" \ | ||
23 | "sdboot=" "run setup; " \ | ||
24 | - "setenv bootargs ${defargs} ${sdargs} ${setupargs} " \ | ||
25 | + "setenv bootargs ${defargs} ip=off root=/dev/mmcblk${drive}p2 " \ | ||
26 | + "rw,noatime rootfstype=ext3 rootwait ${setupargs} " \ | ||
27 | "${vidargs}; echo Booting from SD card in 8bit slot...; " \ | ||
28 | - "run sddtbload; fatload mmc 1:1 ${kernel_addr_r} " \ | ||
29 | + "run sddtbload; fatload mmc ${drive}:1 ${kernel_addr_r} " \ | ||
30 | "${boot_file} && bootm ${kernel_addr_r} ${dtbparam}\0" \ | ||
31 | - "sddtbload=setenv dtbparam; fatload mmc 1:1 ${fdt_addr_r} " \ | ||
32 | + "sddtbload=setenv dtbparam; fatload mmc ${drive}:1 ${fdt_addr_r} " \ | ||
33 | "${fdt_file} && setenv dtbparam \" - ${fdt_addr_r}\" && true\0" | ||
34 | |||
35 | #define CONFIG_EXTRA_ENV_SETTINGS \ | ||
36 | - "bootcmd=run emmcboot ; echo ; echo emmcboot failed ; " \ | ||
37 | + "bootcmd=run sdboot ; echo ; echo sdboot failed ; " \ | ||
38 | + "run emmcboot ; echo ; echo emmcboot failed ; " \ | ||
39 | "run nfsboot ; echo ; echo nfsboot failed ; " \ | ||
40 | "usb start ;" \ | ||
41 | "setenv stdout serial,vga ; setenv stdin serial,usbkbd\0" \ | ||
42 | @@ -229,7 +230,7 @@ | ||
43 | NFS_BOOTCMD \ | ||
44 | SD_BOOTCMD \ | ||
45 | "setup=setenv setupargs fec_mac=${ethaddr} " \ | ||
46 | - "consoleblank=0 no_console_suspend=1 console=tty1 " \ | ||
47 | + "consoleblank=0 no_console_suspend=1 vt.global_cursor_default=0 " \ | ||
48 | "console=${console},${baudrate}n8\0 " \ | ||
49 | "setupdate=setenv drive 1; fatload mmc ${drive}:1 ${kernel_addr_r} " \ | ||
50 | "flash_mmc.img || setenv drive 2; fatload mmc ${drive}:1 " \ | ||
51 | -- | ||
52 | 1.8.3.2 | ||
53 | |||
diff --git a/meta-toradex-extras/recipes/u-boot/u-boot-toradex-fsl_git.bbappend b/meta-toradex-extras/recipes/u-boot/u-boot-toradex-fsl_git.bbappend new file mode 100644 index 0000000..aa33199 --- /dev/null +++ b/meta-toradex-extras/recipes/u-boot/u-boot-toradex-fsl_git.bbappend | |||
@@ -0,0 +1,26 @@ | |||
1 | ############################################################################# | ||
2 | ## | ||
3 | ## Copyright (C) 2014 Digia Plc and/or its subsidiary(-ies). | ||
4 | ## | ||
5 | ## This file is part of the Qt Enterprise Embedded Scripts of the Qt | ||
6 | ## framework. | ||
7 | ## | ||
8 | ## $QT_BEGIN_LICENSE$ | ||
9 | ## Commercial License Usage Only | ||
10 | ## Licensees holding valid commercial Qt license agreements with Digia | ||
11 | ## with an appropriate addendum covering the Qt Enterprise Embedded Scripts, | ||
12 | ## may use this file in accordance with the terms contained in said license | ||
13 | ## agreement. | ||
14 | ## | ||
15 | ## For further information use the contact form at | ||
16 | ## http://qt.digia.com/contact-us. | ||
17 | ## | ||
18 | ## | ||
19 | ## $QT_END_LICENSE$ | ||
20 | ## | ||
21 | ############################################################################# | ||
22 | |||
23 | FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" | ||
24 | SRC_URI += " \ | ||
25 | file://0001-Update-default-args-for-apalis-imx6.patch \ | ||
26 | " | ||