From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D6508C433EF for ; Fri, 3 Dec 2021 20:14:15 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 732CF830A9; Fri, 3 Dec 2021 21:13:48 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="N/wq6KoR"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 2E3C682A69; Fri, 3 Dec 2021 21:13:40 +0100 (CET) Received: from mail-vk1-xa35.google.com (mail-vk1-xa35.google.com [IPv6:2607:f8b0:4864:20::a35]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 9DDC883097 for ; Fri, 3 Dec 2021 21:13:32 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@google.com Received: by mail-vk1-xa35.google.com with SMTP id 84so2598261vkc.6 for ; Fri, 03 Dec 2021 12:13:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=zlYGz3wjitEsm2o7KFwtC2l1V63rV7Tqew7a1x4TlnA=; b=N/wq6KoR8+wuriNSxJHi8Rb+eIR8QCrVyBRmKXVQe+cQ6ST4H/ACX7hT1hHIB1GIAS IZ3TSwo69oSZQRH6IRaUmHQN5OFXOn7wRbaFkZXjd7K3R/UVzqjS1tqUsBX8UjVizQ// eXRAFIl/cSwizfwTlg5tcOk9vPHbBaWm4eFG0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=zlYGz3wjitEsm2o7KFwtC2l1V63rV7Tqew7a1x4TlnA=; b=sKGbay/m2jWYUOtBH7cj1uJga6NNm8+V/cVe7hGoeKwj+DQKfeu4LD4wftULRJrgvN h/hwrrJB0bMxt/udtQZe3mpJCA5yCpNyx6106UY8hAX0gSFamhJHWoizGnzp5StW0m3S 4EOoow4GbcRn7Uyq1PU/6g0dJJqzcsthrZs60X4zrRpfMoiuf5kQRrVPyTTUN8lRUWHf dFS08yot1JiDWf3RrYKEn2KXfqLwMwqA8d6RbgWKNXKi3wrWEZUeA2j731HLQI2my3Qm WVLz6ggfzuPQjRFIR1wJljcanjANxWkcCssd2yoK9vDhzGCksAzgQZpCzPzGRJ3laUE7 v22w== X-Gm-Message-State: AOAM5301PV6WK+YPRPo02hdb0H6rEXo/LtLJYd+lsTViw9fYzE3sODmt RU4gdniPnxDUsBgDT4rB0SrjwTZevIy4+ew9A+9uOA== X-Google-Smtp-Source: ABdhPJxHjOBifh1j/BAe4EOLF3v549Q6YUTiLfc+y6OWnbV6AyN1dYqxsGQxhzGCSl/w5z+pcThL5gwq5WWv0ByIh1I= X-Received: by 2002:a05:6122:d11:: with SMTP id az17mr25835200vkb.22.1638562410937; Fri, 03 Dec 2021 12:13:30 -0800 (PST) MIME-Version: 1.0 References: <20211202155919.2429190-1-sjg@chromium.org> <20211202155919.2429190-8-sjg@chromium.org> In-Reply-To: From: Simon Glass Date: Fri, 3 Dec 2021 13:13:20 -0700 Message-ID: Subject: Re: [PATCH v6 07/25] arm: rpi: Add a devicetree file for rpi_4 To: Peter Robinson Cc: Mark Kettenis , u-boot@lists.denx.de, seanga2@gmail.com, ilias.apalodimas@linaro.org, trini@konsulko.com, francois.ozog@linaro.org, xypron.glpk@gmx.de, albert.u.boot@aribaud.net, mbrugger@suse.com, swarren@nvidia.com, swarren@wwwdotorg.org Content-Type: text/plain; charset="UTF-8" X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.38 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean Hi Peter, Taking another look at https://github.com/raspberrypi/firmware.git I see that the README says that the .dtb files are build from Linux. So it seems I can simply grab them from there. Regards, Simon On Fri, 3 Dec 2021 at 05:16, Peter Robinson wrote: > > On Thu, Dec 2, 2021 at 6:26 PM Simon Glass wrote: > > > > Hi Mark, > > > > On Thu, 2 Dec 2021 at 10:34, Mark Kettenis wrote: > > > > > > > From: Simon Glass > > > > Date: Thu, 2 Dec 2021 08:59:01 -0700 > > > > > > > > Add this file, obtained from the Raspbian boot disk, so there is a > > > > reference devicetree in the U-Boot tree. The same one is used for > > > > 32- and 64-bit variants. > > > > > > > > Note that U-Boot does not normally need this at runtime, since > > > > CONFIG_OF_BOARD is enabled. The previous firmware stage provides a > > > > devicetree at runtime. > > > > > > > > Signed-off-by: Simon Glass > > > > --- > > > > > > > > (no changes since v1) > > > > > > > > arch/arm/dts/Makefile | 3 +- > > > > arch/arm/dts/bcm2711-rpi-4-b.dts | 1958 ++++++++++++++++++++++++++++++ > > > > configs/rpi_4_32b_defconfig | 1 + > > > > configs/rpi_4_defconfig | 1 + > > > > configs/rpi_arm64_defconfig | 1 + > > > > 5 files changed, 1963 insertions(+), 1 deletion(-) > > > > create mode 100644 arch/arm/dts/bcm2711-rpi-4-b.dts > > > > > > > > diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile > > > > index 2d92b2f940d..9cddab37207 100644 > > > > --- a/arch/arm/dts/Makefile > > > > +++ b/arch/arm/dts/Makefile > > > > @@ -1077,7 +1077,8 @@ dtb-$(CONFIG_ARCH_BCM283X) += \ > > > > bcm2837-rpi-3-a-plus.dtb \ > > > > bcm2837-rpi-3-b.dtb \ > > > > bcm2837-rpi-3-b-plus.dtb \ > > > > - bcm2837-rpi-cm3-io3.dtb > > > > + bcm2837-rpi-cm3-io3.dtb \ > > > > + bcm2711-rpi-4-b.dtb > > > > > > > > dtb-$(CONFIG_ARCH_BCM63158) += \ > > > > bcm963158.dtb > > > > diff --git a/arch/arm/dts/bcm2711-rpi-4-b.dts b/arch/arm/dts/bcm2711-rpi-4-b.dts > > > > new file mode 100644 > > > > index 00000000000..425e9fb91c4 > > > > --- /dev/null > > > > +++ b/arch/arm/dts/bcm2711-rpi-4-b.dts > > > > @@ -0,0 +1,1958 @@ > > > > +// SPDX-License-Identifier: GPL-2.0+ OR MIT > > > > +/* > > > > + * Sample device tree for rpi_4 > > > > + > > > > + * Copyright 2021 Google LLC > > > > + */ > > > > > > This is of course an utter lie. This wasn't written from scratch by a > > > Google employee. > > > > > > The original copyright and license for the dtb files you > > > "disassembled" applies. You don't specify exactly where you obtained > > > the file from, but it probably came from here: > > > > > > https://github.com/raspberrypi/firmware > > > > > > And the README.md for that repo states that: > > > > > > "The dtbs, overlays and associated README are built from Linux > > > kernel sources, released under the GPL (see boot/COPYING.linux)" > > > > > > They're probably talking about their own fork of the Linux kernel > > > sources here as there are still differences between their device trees > > > and the the device trees in the official Linux tree. But if you > > > insist on having a device tree in the U-Boot tree, that's where you > > > should look. > > > > IANAL and didn't consider this point. > > > > I got this from the boot disk (using fdtdump) and it does not include > > a copyright message. I'll change this in the next version. > > Should probably just get the original one from their upstream source > repo then rather than decompiling it.