From patchwork Tue Jun 15 00:17:47 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Drew Fustini X-Patchwork-Id: 1491925 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=busybox.net (client-ip=2605:bc80:3010::133; helo=smtp2.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=beagleboard-org.20150623.gappssmtp.com header.i=@beagleboard-org.20150623.gappssmtp.com header.a=rsa-sha256 header.s=20150623 header.b=Yb7EyoVc; dkim-atps=neutral Received: from smtp2.osuosl.org (smtp2.osuosl.org [IPv6:2605:bc80:3010::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4G3pnv54Mgz9sW6 for ; Tue, 15 Jun 2021 10:18:43 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id AF6444046E; Tue, 15 Jun 2021 00:18:36 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id xuNkv3es7zxC; Tue, 15 Jun 2021 00:18:36 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by smtp2.osuosl.org (Postfix) with ESMTP id 126F640454; Tue, 15 Jun 2021 00:18:35 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from smtp4.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id C5CB71BF3FD for ; Tue, 15 Jun 2021 00:18:22 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id B465140534 for ; Tue, 15 Jun 2021 00:18:22 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp4.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=beagleboard-org.20150623.gappssmtp.com Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7TWNvJeI4aP7 for ; Tue, 15 Jun 2021 00:18:21 +0000 (UTC) X-Greylist: whitelisted by SQLgrey-1.8.0 Received: from mail-pf1-x42a.google.com (mail-pf1-x42a.google.com [IPv6:2607:f8b0:4864:20::42a]) by smtp4.osuosl.org (Postfix) with ESMTPS id C8DC340533 for ; Tue, 15 Jun 2021 00:18:21 +0000 (UTC) Received: by mail-pf1-x42a.google.com with SMTP id q25so11898374pfh.7 for ; Mon, 14 Jun 2021 17:18:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=beagleboard-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=rdA/ttfLgI+AEP+gqLda7aFRjbidgfZU+xk+EDpbZ6M=; b=Yb7EyoVcQOA7fq5pgD26/WGsdo8DGb4lucUJso0eY6QBKs7z0XRkcsaiMhwWTxyhW8 xSDXAXnSPTCcU+F+bFktm9IGMVhNwsjI5Q/NDOlZ9ykWyJRScNGeUeUVxH5pCrjn0mrz aAhm1ZqYp2aBgLtJQ6YOdRZ/kTURH/hvrFEwMtjmhx2+GntUMwkw8GzIeyr5cv9GB+Jl qFZFJ3iNFEOS1Jsi9LdE4ZO/5d2akabo0QpYKLJvW+yg6Gx3q5ITAgeCB9mc1Eiek7Hb A0R/HRO//H+WV/RtGH9yw67fE8VJfJFignyndaapYDofR5lXeQ/U+fN/pFj2UpOx8rQ3 sBMA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=rdA/ttfLgI+AEP+gqLda7aFRjbidgfZU+xk+EDpbZ6M=; b=NWy1+UMF54b/R8v0gmcYovmVhQ5ToKfWvKxik8jNTZHNkOj0GANqkrMs4qWIvtc+fO 1ciCSYFxXZfJUk0ypeOH+ZK7ZLTfdrY8McTvE/i9kR9Z4FU6KcJfhpSFvIhKSPfBEdpA ZshumwltUkN80HoKcHGENwFhVr/8VqTk4x+XLjjhgna+Lygv7O8/NgfG2nult9ClCxZ/ I511WEaSsjo3tCPm9PXXTx/bSvUCLKXOEPULPlBOpTnbBf9plhH5YUJOe0OVW1V+sByP gtjv4jhem9JP33NV5F2aXKt7MwbDQCEeI11WF2jzqAY9bvohaXVdDHaDStEYGt4ITWJR 8auQ== X-Gm-Message-State: AOAM530X8HYYH8NZnSOl1P6LAAZKJE9zska7SATCvpVLA5BmOORDMD4n Vu/epEi/ieIgCA+4SyqRijxoMLd/9/h8sg== X-Google-Smtp-Source: ABdhPJzeydJgK77iv7JbyYqns6U9aa00iRXsctXX2k2y9plHAJFsfiljuejDAY58K2ML7w3J6YOg4Q== X-Received: by 2002:a05:6a00:23d0:b029:2de:c1a2:f1e with SMTP id g16-20020a056a0023d0b02902dec1a20f1emr1278364pfc.60.1623716300661; Mon, 14 Jun 2021 17:18:20 -0700 (PDT) Received: from x1.hsd1.or.comcast.net ([2601:1c0:4701:ae70:d92:6466:8a78:3f88]) by smtp.gmail.com with ESMTPSA id e10sm14908956pgc.63.2021.06.14.17.18.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 14 Jun 2021 17:18:20 -0700 (PDT) From: Drew Fustini To: buildroot@buildroot.org Date: Mon, 14 Jun 2021 17:17:47 -0700 Message-Id: <20210615001750.421889-2-drew@beagleboard.org> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20210615001750.421889-1-drew@beagleboard.org> References: <20210615001750.421889-1-drew@beagleboard.org> MIME-Version: 1.0 Subject: [Buildroot] [PATCH 1/4] boot/uboot: introduce BR2_TARGET_UBOOT_FORMAT_DTB X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Drew Fustini , Alistair Francis , Thomas Petazzoni , Bin Meng Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" If u-boot CONFIG_OF_SEPARATE is defined [1], then the device tree will be built and placed in a u-boot.dtb file alongside u-boot.bin. When BR2_TARGET_UBOOT_FORMAT_DTB is enabled, buildroot will copy u-boot.dtb to $(BINARIES_DIR). This is useful for RISC-V platforms that want to build OpenSBI with an external DTB by using FW_FDT_PATH [2]. [1] https://github.com/lentinj/u-boot/blob/master/doc/README.fdt-control [2] https://github.com/riscv/opensbi/blob/master/docs/firmware/fw.md Signed-off-by: Drew Fustini Reviewed-by: Bin Meng Reviewed-by: Alistair Francis --- boot/uboot/Config.in | 3 +++ boot/uboot/uboot.mk | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/boot/uboot/Config.in b/boot/uboot/Config.in index 00c667412006..44a16d892a60 100644 --- a/boot/uboot/Config.in +++ b/boot/uboot/Config.in @@ -252,6 +252,9 @@ config BR2_TARGET_UBOOT_FORMAT_BIN bool "u-boot.bin" default y +config BR2_TARGET_UBOOT_FORMAT_DTB + bool "u-boot.dtb" + config BR2_TARGET_UBOOT_FORMAT_DTB_BIN bool "u-boot-dtb.bin" diff --git a/boot/uboot/uboot.mk b/boot/uboot/uboot.mk index dbe82e65b17e..923fd0c1d46c 100644 --- a/boot/uboot/uboot.mk +++ b/boot/uboot/uboot.mk @@ -48,6 +48,10 @@ ifeq ($(BR2_TARGET_UBOOT_FORMAT_BIN),y) UBOOT_BINS += u-boot.bin endif +ifeq ($(BR2_TARGET_UBOOT_FORMAT_DTB),y) +UBOOT_BINS += u-boot.dtb +endif + ifeq ($(BR2_TARGET_UBOOT_FORMAT_ELF),y) UBOOT_BINS += u-boot # To make elf usable for debuging on ARC use special target