board: add support for liteBoard
PATCH 1/1 board: add support for liteBoard
Board support package includes:
* Buildroot defconfig
* Mainline Linux kernel v4.7.3 with board support patches
* Mainline U-Boot v2016.09 with board support patch
* genimage config to create sdcard image
* Board readme.txt
--- board/grinn/liteboard/genimage.cfg | 48 ++ ...ARM-dts-imx6ul-Add-DTS-for-liteSOM-module.patch | 116 +++ ...0002-ARM-dts-imx6ul-Add-DTS-for-liteBoard.patch | 194 +++++ ...board-liteboard-Add-support-for-liteBoard.patch | 785 +++++++++++++++++++++ board/grinn/liteboard/post-image.sh | 16 + board/grinn/liteboard/readme.txt | 46 ++ configs/grinn_liteboard_defconfig | 26 + 7 files changed, 1231 insertions(+) create mode 100644 board/grinn/liteboard/genimage.cfg create mode 100644 board/grinn/liteboard/patches/linux/0001-ARM-dts-imx6ul-Add-DTS-for-liteSOM-module.patch create mode 100644 board/grinn/liteboard/patches/linux/0002-ARM-dts-imx6ul-Add-DTS-for-liteBoard.patch create mode 100644 board/grinn/liteboard/patches/uboot/0001-board-liteboard-Add-support-for-liteBoard.patch create mode 100755 board/grinn/liteboard/post-image.sh create mode 100644 board/grinn/liteboard/readme.txt create mode 100644 configs/grinn_liteboard_defconfig
board/grinn/liteboard/genimage.cfg new file +48 -0
@@ -0,0 +1,48 @@ +# Minimal microSD card image for Grinn's liteBoard +# +# We mimic the .sdcard Freescale's image format for i.MX6UL: +# * the microSD card must have 1 kB free space at the beginning, +# * SPL is dumped as is, +# * U-Boot is dumped at 69K offset, as configured in SPL +# * a FAT partition at offset 8 MB is containing zImage and dtbs, +# * a single root filesystem partition is required (Ext4 in this case). +# + +image boot.vfat { + vfat { + files = { + "imx6ul-liteboard.dtb", + "zImage" + } + } + size = 16M +} + +image sdcard.img { + hdimage { + } + + partition SPL { + in-partition-table = "no" + image = "SPL" + offset = 1K + } + + partition u-boot { + in-partition-table = "no" + image = "u-boot.img" + offset = 69K + } + + partition boot { + partition-type = 0xC + bootable = "true" + image = "boot.vfat" + offset = 8M + } + + partition rootfs { + partition-type = 0x83 + image = "rootfs.ext4" + } +}
board/grinn/liteboard/patches/linux/0001-ARM-dts-imx6ul-Add-DTS-for-liteSOM-module.patch new file +116 -0
116 lines not on this page · raw message
board/grinn/liteboard/patches/linux/0002-ARM-dts-imx6ul-Add-DTS-for-liteBoard.patch new file +194 -0
194 lines not on this page · raw message
board/grinn/liteboard/patches/uboot/0001-board-liteboard-Add-support-for-liteBoard.patch new file +785 -0
785 lines not on this page · raw message
board/grinn/liteboard/post-image.sh new file +16 -0
@@ -0,0 +1,16 @@ +#!/usr/bin/env bash + +BOARD_DIR="$(dirname $0)" +GENIMAGE_CFG="${BOARD_DIR}/genimage.cfg" +GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" + +rm -rf "${GENIMAGE_TMP}" + +genimage \ + --rootpath "${TARGET_DIR}" \ + --tmppath "${GENIMAGE_TMP}" \ + --inputpath "${BINARIES_DIR}" \ + --outputpath "${BINARIES_DIR}" \ + --config "${GENIMAGE_CFG}" + +exit $?
board/grinn/liteboard/readme.txt new file +46 -0
46 lines not on this page · raw message
configs/grinn_liteboard_defconfig new file +26 -0
@@ -0,0 +1,26 @@ +BR2_arm=y +BR2_cortex_a7=y +BR2_GLOBAL_PATCH_DIR="board/grinn/liteboard/patches" +BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_7=y +BR2_TARGET_GENERIC_GETTY_PORT="ttymxc0" +BR2_SYSTEM_DHCP="eth0" +BR2_ROOTFS_POST_IMAGE_SCRIPT="board/grinn/liteboard/post-image.sh" +BR2_LINUX_KERNEL=y +BR2_LINUX_KERNEL_CUSTOM_VERSION=y +BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="4.7.3" +BR2_LINUX_KERNEL_DEFCONFIG="imx_v6_v7" +BR2_LINUX_KERNEL_DTS_SUPPORT=y +BR2_LINUX_KERNEL_INTREE_DTS_NAME="imx6ul-liteboard" +BR2_TARGET_ROOTFS_EXT2=y +BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_UBOOT=y +BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y +BR2_TARGET_UBOOT_CUSTOM_VERSION=y +BR2_TARGET_UBOOT_CUSTOM_VERSION_VALUE="2016.09" +BR2_TARGET_UBOOT_BOARD_DEFCONFIG="liteboard" +BR2_TARGET_UBOOT_FORMAT_IMG=y +BR2_TARGET_UBOOT_SPL=y +BR2_TARGET_UBOOT_SPL_NAME="SPL" +BR2_PACKAGE_HOST_DOSFSTOOLS=y +BR2_PACKAGE_HOST_GENIMAGE=y +BR2_PACKAGE_HOST_MTOOLS=y
Signature · 1 line
2.9.3
PATCH 1/1 board: add support for liteBoard
Hello,
Quoted 9 lines · Marcin Niestroj
Board support package includes:
* Buildroot defconfig
* Mainline Linux kernel v4.7.3 with board support patches
* Mainline U-Boot v2016.09 with board support patch
* genimage config to create sdcard image
* Board readme.txtSigned-off-by Marcin Niestroj <[email protected]>
This generally looks very good. I've seen on the LAKML that you have submitted upstream the support of this platform to the Linux kernel, I assume you've done the same for the U-Boot part. We generally don't like carrying the entire support for a new board in Buildroot in the form of patches, but if those patches are clean and on their way upstream (which is the case here, then it's fine).
board/grinn/liteboard/genimage.cfg line 9
Quoted 11 lines
+++ b/board/grinn/liteboard/genimage.cfg
board/grinn/liteboard/genimage.cfg new file +9
-0@@ -0,0 +1,48 @@ +# Minimal microSD card image for Grinn's liteBoard +# +# We mimic the .sdcard Freescale's image format for i.MX6UL: +# * the microSD card must have 1 kB free space at the beginning, +# * SPL is dumped as is, +# * U-Boot is dumped at 69K offset, as configured in SPL +# * a FAT partition at offset 8 MB is containing zImage and dtbs, +# * a single root filesystem partition is required (Ext4 in this case). +#
Can you instead use the generic freescale genimage.cfg and post-image script ? See board/freescale/common/.
It's not exactly identical to your genimage file as it's using a single U-Boot image called u-boot.imx instead of the split SPL / u-boot.img that you're using. But since your platform is i.MX6 based, I suppose the u-boot.imx should also work (Cc'ing Fabio on this).
The rest if perfectly fine.
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com
PATCH 1/1 board: add support for liteBoard
Hi,
Quoted 11 lines · Thomas Petazzoni
Hello,
Quoted 8 lines · Marcin Niestroj
Board support package includes:
* Buildroot defconfig
* Mainline Linux kernel v4.7.3 with board support patches
* Mainline U-Boot v2016.09 with board support patch
* genimage config to create sdcard image
* Board readme.txt
Quoted 8 lines
Quoted 1 line
Signed-off-by Marcin Niestroj <[email protected]>This generally looks very good. I've seen on the LAKML that you have submitted upstream the support of this platform to the Linux kernel, I assume you've done the same for the U-Boot part. We generally don't like carrying the entire support for a new board in Buildroot in the form of patches, but if those patches are clean and on their way upstream (which is the case here, then it's fine).
I've not posted U-Boot patch yet, but will do so in near future. For now I wait for response on mainling list about separate liteSOM and liteBoard support in U-Boot. Anyway, there should be not much difference between this patch and the one I will post to mainline U-Boot.
Quoted 17 lines
board/grinn/liteboard/genimage.cfg line 9
Quoted 13 lines
+++ b/board/grinn/liteboard/genimage.cfg
board/grinn/liteboard/genimage.cfg new file +9
-0@@ -0,0 +1,48 @@ +# Minimal microSD card image for Grinn's liteBoard +# +# We mimic the .sdcard Freescale's image format for i.MX6UL: +# * the microSD card must have 1 kB free space at the beginning, +# * SPL is dumped as is, +# * U-Boot is dumped at 69K offset, as configured in SPL +# * a FAT partition at offset 8 MB is containing zImage and dtbs, +# * a single root filesystem partition is required (Ext4 in this case). +#Can you instead use the generic freescale genimage.cfg and post-image script ? See board/freescale/common/.
Quoted 4 lines
It's not exactly identical to your genimage file as it's using a single U-Boot image called u-boot.imx instead of the split SPL / u-boot.img that you're using. But since your platform is i.MX6 based, I suppose the u-boot.imx should also work (Cc'ing Fabio on this).
I've added SPL on purpose. We will have boards with 256 and 512 MB RAM. So right now we check in SPL how much RAM we have and configure memory subsystem accordingly. I believe we cannot configure it in full U-Boot.
In single U-Boot image there are hardcoded values that are copied to processor's registers (DDR configuration is among them) from the "IMX" U-Boot image just before running it.
Also, in mainline U-Boot there is support for imx6ul EVK with separate SPL by default.
Quoted 5 lines
The rest if perfectly fine.
Thomas
Signature · 1 line
Marcin Niestroj
PATCH 1/1 board: add support for liteBoard
Hello,
Quoted 7 lines · Marcin Niestroj
Quoted 6 lines
This generally looks very good. I've seen on the LAKML that you have submitted upstream the support of this platform to the Linux kernel, I assume you've done the same for the U-Boot part. We generally don't like carrying the entire support for a new board in Buildroot in the form of patches, but if those patches are clean and on their way upstream (which is the case here, then it's fine).
Quoted 5 lines
I've not posted U-Boot patch yet, but will do so in near future. For now I wait for response on mainling list about separate liteSOM and liteBoard support in U-Boot. Anyway, there should be not much difference between this patch and the one I will post to mainline U-Boot.
OK, good.
Quoted 9 lines
Quoted 4 lines
It's not exactly identical to your genimage file as it's using a single U-Boot image called u-boot.imx instead of the split SPL / u-boot.img that you're using. But since your platform is i.MX6 based, I suppose the u-boot.imx should also work (Cc'ing Fabio on this).
I've added SPL on purpose. We will have boards with 256 and 512 MB RAM. So right now we check in SPL how much RAM we have and configure memory subsystem accordingly. I believe we cannot configure it in full U-Boot.
Quoted 6 lines
In single U-Boot image there are hardcoded values that are copied to processor's registers (DDR configuration is among them) from the "IMX" U-Boot image just before running it.
Also, in mainline U-Boot there is support for imx6ul EVK with separate SPL by default.
OK, makes sense. Then I'll apply your patch as-is.
Thanks,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com