summaryrefslogtreecommitdiffstats
path: root/recipes-kernel
diff options
context:
space:
mode:
authorJeremy Grosser <jeremy@synack.me>2018-10-18 13:35:23 +0000
committerDenys Dmytriyenko <denys@ti.com>2018-10-18 22:51:45 +0000
commite3e20300d40e0d3577d0d25af151c9d4b69cf44b (patch)
tree2cb2d6c1c9d1b8a4ff011fbb4e1a5284604fbfef /recipes-kernel
parentfab8b9c0331533cfdf02a390bd1d2bcfce557c95 (diff)
downloadmeta-ti-e3e20300d40e0d3577d0d25af151c9d4b69cf44b.tar.gz
lego-ev3: Add support for LEGO Mindstorms EV3 (AM1808)
Thanks for the feedback! Updated patch below. Changes: - Change SERIAL_CONSOLE to new SERIAL_CONSOLES format. - Move SPL_BINARY variable into lego-ev3 machine config - Check for KERNEL_DEVICETREE_BUNDLE before uImage manipulation. - Fix line wrapping errors introduced by MUA Signed-off-by: Jeremy Grosser <jeremy@synack.me> Signed-off-by: Denys Dmytriyenko <denys@ti.com>
Diffstat (limited to 'recipes-kernel')
-rw-r--r--recipes-kernel/linux/bundle-devicetree.inc26
-rw-r--r--recipes-kernel/linux/linux-ti-staging_4.14.bb1
2 files changed, 27 insertions, 0 deletions
diff --git a/recipes-kernel/linux/bundle-devicetree.inc b/recipes-kernel/linux/bundle-devicetree.inc
new file mode 100644
index 00000000..4d450374
--- /dev/null
+++ b/recipes-kernel/linux/bundle-devicetree.inc
@@ -0,0 +1,26 @@
1# Upstream kernel-devicetree.bbclass only supports bundling the DTB with
2# zImage. The factory u-boot on lego-ev3 EEPROM only supports uImage, so we
3# append the DTB to the final uImage here.
4
5do_deploy_append() {
6 if [ "${KERNEL_DEVICETREE_BUNDLE}" = "1" ]; then
7 install -d ${DEPLOYDIR}
8 for dtbf in ${KERNEL_DEVICETREE}; do
9 dtb=`normalize_dtb "$dtbf"`
10 dtb_ext=${dtb##*.}
11 dtb_base_name=`basename $dtb .$dtb_ext`
12 for type in ${KERNEL_IMAGETYPE_FOR_MAKE}; do
13 if [ "$type" = "uImage" ]; then
14 cat ${D}/${KERNEL_IMAGEDEST}/$type \
15 ${DEPLOYDIR}/$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext \
16 > ${DEPLOYDIR}/$type-$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext.bin
17 ln -sf $type-$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext.bin \
18 ${DEPLOYDIR}/$type-$dtb_base_name-${KERNEL_DTB_LINK_NAME}.$dtb_ext.bin
19 cat ${D}/${KERNEL_IMAGEDEST}/$type \
20 ${DEPLOYDIR}/$dtb_base_name-${KERNEL_DTB_NAME}.$dtb_ext \
21 > ${DEPLOYDIR}/$type
22 fi
23 done
24 done
25 fi
26}
diff --git a/recipes-kernel/linux/linux-ti-staging_4.14.bb b/recipes-kernel/linux/linux-ti-staging_4.14.bb
index 5ee206ec..13b94ffe 100644
--- a/recipes-kernel/linux/linux-ti-staging_4.14.bb
+++ b/recipes-kernel/linux/linux-ti-staging_4.14.bb
@@ -8,6 +8,7 @@ inherit kernel
8require recipes-kernel/linux/setup-defconfig.inc 8require recipes-kernel/linux/setup-defconfig.inc
9require recipes-kernel/linux/cmem.inc 9require recipes-kernel/linux/cmem.inc
10require recipes-kernel/linux/ti-uio.inc 10require recipes-kernel/linux/ti-uio.inc
11require recipes-kernel/linux/bundle-devicetree.inc
11 12
12# Look in the generic major.minor directory for files 13# Look in the generic major.minor directory for files
13FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}-4.14:" 14FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}-4.14:"