Initial support for Nitrogen6X
v2 cover Initial support for Nitrogen6X
This patchset adds support for Nitrogen6X using the deployment used by Boundary Devices. The generated sdcard should just work in the board.
The patches are untested as I don't own a Nitrogen6X and would be good if someone could test those before we apply them.
Otavio Salvador (3):
u-boot-boundary: Add U-Boot recipe for Boundary Devices version
u-boot-script-boundary: Add recipe to deploy the boot scripts
nitrogen6x: Add machine definition
Changes for v2:
* ensure boot scripts are build for rootfs generation
* properly deploy compiled boot script at deploy dir
Known issues:
* boot script still needs changes to work out of box
conf/machine/nitrogen6x.conf | 28 ++++++++++++++++ recipes-bsp/u-boot/u-boot-boundary_git.bb | 16 ++++++++++ recipes-bsp/u-boot/u-boot-script-boundary_git.bb | 37 ++++++++++++++++++++++ 3 files changed, 81 insertions(+) create mode 100644 conf/machine/nitrogen6x.conf create mode 100644 recipes-bsp/u-boot/u-boot-boundary_git.bb create mode 100644 recipes-bsp/u-boot/u-boot-script-boundary_git.bb
Signature · 1 line
1.7.10.4
PATCH v2 1/3 u-boot-boundary: Add U-Boot recipe for Boundary Devices version
--- recipes-bsp/u-boot/u-boot-boundary_git.bb | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 recipes-bsp/u-boot/u-boot-boundary_git.bb
recipes-bsp/u-boot/u-boot-boundary_git.bb new file +16 -0
@@ -0,0 +1,16 @@ +require recipes-bsp/u-boot/u-boot.inc + +LICENSE = "GPLv2+" +LIC_FILES_CHKSUM = "file://COPYING;md5=1707d6db1d42237583f50183a5651ecb" +COMPATIBLE_MACHINE = "(imx6qsabrelite|nitrogen6x)" + +PROVIDES = "u-boot" + +PV = "v2013.01+git${SRCPV}" + +SRCREV = "d6b05d35b8b29392e71fdd8fa43d5cb8bd4fe276" +SRC_URI = "git://github.com/boundarydevices/u-boot-imx6.git" + +S = "${WORKDIR}/git" + +PACKAGE_ARCH = "${MACHINE_ARCH}"
Signature · 1 line
1.7.10.4
PATCH v2 2/3 u-boot-script-boundary: Add recipe to deploy the boot scripts
In reply to Otavio SalvadorThe recipe deploys the scripts used by Boundary Devices to detect and choose video output, load kernel and etc...
--- recipes-bsp/u-boot/u-boot-script-boundary_git.bb | 46 ++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 recipes-bsp/u-boot/u-boot-script-boundary_git.bb
recipes-bsp/u-boot/u-boot-script-boundary_git.bb new file +46 -0
@@ -0,0 +1,46 @@ +LICENSE = "GPLv2+" +LIC_FILES_CHKSUM = "file://COPYING;md5=1707d6db1d42237583f50183a5651ecb" +COMPATIBLE_MACHINE = "(imx6qsabrelite|nitrogen6x)" +DEPENDS = "u-boot-mkimage-native" + +PV = "v2013.01+git${SRCPV}" + +SRCREV = "d6b05d35b8b29392e71fdd8fa43d5cb8bd4fe276" +SRC_URI = "git://github.com/boundarydevices/u-boot-imx6.git" + +S = "${WORKDIR}/git" + +inherit deploy + +do_mkimage () { + uboot-mkimage -A arm -O linux -T script -C none -a 0 -e 0 \ + -n "boot script" -d board/boundary/${MACHINE}/6x_bootscript.txt \ + board/boundary/${MACHINE}/6x_bootscript + + uboot-mkimage -A arm -O linux -T script -C none -a 0 -e 0 \ + -n "upgrade script" -d board/boundary/${MACHINE}/6x_upgrade.txt \ + board/boundary/${MACHINE}/6x_upgrade +} + +addtask mkimage after do_compile before do_install + +do_deploy () { + install -d ${DEPLOYDIR} + install ${S}/board/boundary/${MACHINE}/6x_bootscript \ + ${DEPLOYDIR}/6x_bootscript-${MACHINE}-${PV}-${PR} + install ${S}/board/boundary/${MACHINE}/6x_upgrade \ + ${DEPLOYDIR}/6x_upgrade-${MACHINE}-${PV}-${PR} + + cd ${DEPLOYDIR} + rm -f 6x_bootscript-${MACHINE} 6x_upgrade-${MACHINE} + ln -sf 6x_bootscript-${MACHINE}-${PV}-${PR} 6x_bootscript-${MACHINE} + ln -sf 6x_upgrade-${MACHINE}-${PV}-${PR} 6x_upgrade-${MACHINE} +} + +addtask deploy before do_build after do_compile + +do_compile[noexec] = "1" +do_install[noexec] = "1" +do_populate_sysroot[noexec] = "1" + +PACKAGE_ARCH = "${MACHINE_ARCH}"
Signature · 1 line
1.7.10.4
PATCH v2 3/3 nitrogen6x: Add machine definition
In reply to Otavio SalvadorThis adds the machine definition to Nitrogen6x from Boundary Devices. More information at:
http://boundarydevices.com/products/nitrogen6x-board-imx6-arm-cortex-a9-sbc/
In order to take advance of same code used for imx6qsabrelite (on linux-imx, u-boot, imx-firmaware), we use a MACHINEOVERRIDES trick, so imx6qsabrelite is taken as a fallback for nitrogen6x machine.
To ensure the boot scripts are available at rootfs time, the do_deploy task of u-boot-script-boundary is added as a dependency of do_rootfs.
--- conf/machine/nitrogen6x.conf | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 conf/machine/nitrogen6x.conf
conf/machine/nitrogen6x.conf new file +30 -0
@@ -0,0 +1,30 @@ +#@TYPE: Machine +#@NAME: Nitrogen6X +#@DESCRIPTION: Machine configuration for Boundary Devices Nitrogen6X + +# We need to override the default before everything +MACHINEOVERRIDES = "${MACHINE}:imx6qsabrelite" + +include conf/machine/include/imx-base.inc +include conf/machine/include/tune-cortexa9.inc + +SOC_FAMILY = "mx6q:mx6" + +PREFERRED_PROVIDER_u-boot = "u-boot-boundary" + +# Use SPI NOR U-Boot by default +IMAGE_BOOTLOADER ?= "" + +# Ensure boot scripts will be available at rootfs time +do_rootfs[depends] += "u-boot-script-boundary:do_deploy" + +# Boot scripts to install +BOOT_SCRIPTS = "6x_bootscript-${MACHINE}:6x_bootscript" + +UBOOT_MACHINE = "nitrogen6X_config" + +SERIAL_CONSOLE = "115200 ttymxc1" + +MACHINE_EXTRA_RRECOMMENDS += "linux-firmware-wl12xx" + +MACHINE_FEATURES += " pci wifi bluetooth"
Signature · 1 line
1.7.10.4