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 420A4EB64D9 for ; Mon, 19 Jun 2023 14:50:59 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 675FE863A0; Mon, 19 Jun 2023 16:50:55 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=collabora.com header.i=@collabora.com header.b="luA/zE9A"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id D2E4786308; Mon, 19 Jun 2023 16:50:48 +0200 (CEST) Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 3C299865D4 for ; Mon, 19 Jun 2023 16:44:58 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=detlev.casanova@collabora.com Received: from arisu.localnet (mtl.collabora.ca [66.171.169.34]) (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) (Authenticated sender: detlev) by madras.collabora.co.uk (Postfix) with ESMTPSA id 09E6866003B0; Mon, 19 Jun 2023 15:44:56 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1687185897; bh=mtCJnArDzkSNMhqRZqTISTvjtYo/5r5zmLebq1REuwA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=luA/zE9A9H5lyRg2FZijKoG2EahCIUJB+8u4+Tjd8V3EQ8EHdy0VgIweVW66lxhy6 3nl7jvcm0CDOMGORrkwlTBWzvwS9869noG7YnecdFc7XMFhvzW/YwhYx1iraARfony 5oAd7lofZ+wnXzlwVyNBYNpQeWPryNmM2Gjq099J4JihEeCf3PhXhzulBhbIcfsJUZ v+6mV15cuH41ufgKU7H5ih+uVmnEQz1gaO8bCaYdZVTUZXaYraLj+27CQrJS3Z22Cl EbCFPN/tIov0GUErupr56p2MXKdingRUdy1FEniQSo5yKKN9vi8CaZol9XIplzgI3k /AqxAZfH+t/LA== From: Detlev Casanova To: u-boot@lists.denx.de, Marek Vasut Cc: Marek Vasut , Hai Pham , Tam Nguyen Subject: Re: [PATCH v1 4/4] configs: rcar3: Add shell function to select the linux devicetree Date: Mon, 19 Jun 2023 10:45:01 -0400 Message-ID: <4870499.31r3eYUQgx@arisu> In-Reply-To: <7b37715c-59b5-6836-4019-e4fec417a43c@mailbox.org> References: <20230616152122.588168-1-detlev.casanova@collabora.com> <20230616152122.588168-5-detlev.casanova@collabora.com> <7b37715c-59b5-6836-4019-e4fec417a43c@mailbox.org> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 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.8 at phobos.denx.de X-Virus-Status: Clean On Friday, June 16, 2023 8:45:31 P.M. EDT Marek Vasut wrote: > On 6/16/23 17:21, Detlev Casanova wrote: > > This function uses the sysinfo command to determine which linux device > > tree is selected for the running board. > > > > Signed-off-by: Detlev Casanova > > --- > > > > configs/rcar3_ulcb_defconfig | 1 + > > include/configs/rcar-gen3-common.h | 9 ++++++++- > > 2 files changed, 9 insertions(+), 1 deletion(-) > > > > diff --git a/configs/rcar3_ulcb_defconfig b/configs/rcar3_ulcb_defconfig > > index b8fdb5e3826..bb5f8f742ea 100644 > > --- a/configs/rcar3_ulcb_defconfig > > +++ b/configs/rcar3_ulcb_defconfig > > @@ -47,6 +47,7 @@ CONFIG_CMD_EXT4=y > > > > CONFIG_CMD_EXT4_WRITE=y > > CONFIG_CMD_FAT=y > > CONFIG_CMD_FS_GENERIC=y > > > > +CONFIG_CMD_SYSINFO=y > > > > CONFIG_OF_CONTROL=y > > CONFIG_OF_LIST="r8a77950-ulcb-u-boot r8a77960-ulcb-u-boot > > r8a77965-ulcb-u-boot" CONFIG_MULTI_DTB_FIT_LZO=y > > > > diff --git a/include/configs/rcar-gen3-common.h > > b/include/configs/rcar-gen3-common.h index 213caa75238..b278eb85a81 > > 100644 > > --- a/include/configs/rcar-gen3-common.h > > +++ b/include/configs/rcar-gen3-common.h > > @@ -33,6 +33,13 @@ > > > > /* ENV setting */ > > > > #define CFG_EXTRA_ENV_SETTINGS \ > > > > - "bootm_size=0x10000000\0" > > + "bootm_size=0x10000000\0" \ > > + "set_board_fdt=sysinfo revision board_rev; " \ > > + "sysinfo id board_id; " \ > > + "if test ${board_rev} = 2.1 && test ${board_id} = 0x0b; then " \ > > + "setenv fdtfile renesas/r8a779m1-ulcb.dtb; " \ > > + "elif test ${board_rev} = 2.0 && test ${board_id} = 0x0b; then "\ > > + "setenv fdtfile renesas/r8a77951-ulcb.dtb; " \ > > + "fi\0" \ > > You must also consider M3W and M3N ULCB, i.e. 77960/77965 ones. > > You must also consider all the other boards which use this header file, > salvator-xs comes to mind. That one also comes with M3W/M3N SoC. Also, > all the other Gen3 boards use this header, E3 Ebise, V3* Condor/Eagle ... Yeah, that's why I'm not sure this function should be here. I don't have the boards to check the revision values.