Return-Path: Received: from mail-out.m-online.net (mail-out.m-online.net [212.18.0.10]) by mail.openembedded.org (Postfix) with ESMTP id 55ECE60097 for ; Sun, 19 Oct 2014 19:15:57 +0000 (UTC) Received: from mail.nefkom.net (unknown [192.168.8.184]) by mail-out.m-online.net (Postfix) with ESMTP id 3jLW656qTDz3hjZq; Sun, 19 Oct 2014 21:15:57 +0200 (CEST) X-Auth-Info: 1YL+1C8omOIS5XRHQQNonl/t1FpI5aIZEjNsUkM685Q= Received: from chi.lan (host-82-135-33-74.customer.m-online.net [82.135.33.74]) by smtp-auth.mnet-online.de (Postfix) with ESMTPA id 3jLW653xSKzvdWR; Sun, 19 Oct 2014 21:15:57 +0200 (CEST) From: Marek Vasut To: openembedded-core@lists.openembedded.org Date: Sun, 19 Oct 2014 21:15:46 +0200 Message-Id: <1413746147-7120-7-git-send-email-marex@denx.de> X-Mailer: git-send-email 2.0.0 In-Reply-To: <1413746147-7120-1-git-send-email-marex@denx.de> References: <1413746147-7120-1-git-send-email-marex@denx.de> Cc: Marek Vasut , Paul Eggleton , Koen Kooi Subject: [PATCH 6/7] kernel: Build DTBs early X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 19 Oct 2014 19:16:02 -0000 Pull out the compilation of the DTB blobs right after the kernel's own do_compile function finishes. This makes them available just in time for the kernel image construction functions. Signed-off-by: Marek Vasut Cc: Richard Purdie Cc: Koen Kooi Cc: Paul Eggleton --- meta/recipes-kernel/linux/linux-dtb.inc | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/meta/recipes-kernel/linux/linux-dtb.inc b/meta/recipes-kernel/linux/linux-dtb.inc index 6b8f1a5..ee3a5e1 100644 --- a/meta/recipes-kernel/linux/linux-dtb.inc +++ b/meta/recipes-kernel/linux/linux-dtb.inc @@ -5,6 +5,18 @@ python __anonymous () { d.appendVar("PACKAGES", " kernel-devicetree") } +do_compile_append() { + if test -n "${KERNEL_DEVICETREE}"; then + for DTB in ${KERNEL_DEVICETREE}; do + if echo ${DTB} | grep -q '/dts/'; then + bbwarn "${DTB} contains the full path to the the dts file, but only the dtb name should be used." + DTB=`basename ${DTB} | sed 's,\.dts$,.dtb,g'` + fi + oe_runmake ${DTB} + done + fi +} + do_install_append() { if test -n "${KERNEL_DEVICETREE}"; then for DTB in ${KERNEL_DEVICETREE}; do @@ -13,10 +25,8 @@ do_install_append() { DTB=`basename ${DTB} | sed 's,\.dts$,.dtb,g'` fi DTB_BASE_NAME=`basename ${DTB} .dtb` - DTB_NAME=`echo ${KERNEL_IMAGE_BASE_NAME} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` DTB_SYMLINK_NAME=`echo ${KERNEL_IMAGE_SYMLINK_NAME} | sed "s/${MACHINE}/${DTB_BASE_NAME}/g"` DTB_PATH="${B}/arch/${ARCH}/boot/dts/${DTB}" - oe_runmake ${DTB} if [ ! -e "${DTB_PATH}" ]; then DTB_PATH="${B}/arch/${ARCH}/boot/${DTB}" fi -- 2.1.1