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 127E3CCA47B for ; Mon, 11 Jul 2022 18:22:40 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 4F1CE84003; Mon, 11 Jul 2022 20:22:38 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=tinet.cat Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 4C75C8401B; Mon, 11 Jul 2022 20:22:36 +0200 (CEST) Received: from mx1.tinet.cat (mx1.dipta.cat [195.76.233.59]) (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 9B34E80112 for ; Mon, 11 Jul 2022 20:22:31 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=tinet.cat Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=xdrudis@tinet.cat X-ASG-Debug-ID: 1657563748-12aaf258c2586640001-4l7tJC Received: from smtp01.tinet.cat (smtp01.tinet.org [195.77.216.131]) by mx1.tinet.cat with ESMTP id kknTUdZlYcLKotLj; Mon, 11 Jul 2022 20:22:28 +0200 (CEST) X-Barracuda-Envelope-From: xdrudis@tinet.cat X-Barracuda-Effective-Source-IP: smtp01.tinet.org[195.77.216.131] X-Barracuda-Apparent-Source-IP: 195.77.216.131 Received: from begut (99.red-79-152-185.dynamicip.rima-tde.net [79.152.185.99]) by smtp01.tinet.cat (Postfix) with ESMTPSA id 82BCE605E0C3; Mon, 11 Jul 2022 20:22:28 +0200 (CEST) Date: Mon, 11 Jul 2022 20:22:27 +0200 From: Xavier Drudis Ferran To: Quentin Schulz Cc: sjg@chromium.org, philipp.tomsich@vrull.eu, kever.yang@rock-chips.com, alpernebiyasak@gmail.com, hanetzer@startmail.com, email2tema@gmail.com, pbrobinson@gmail.com, u-boot@lists.denx.de, Quentin Schulz Subject: Re: [PATCH] rockchip: rk3399: boot_devices: fix eMMC node name Message-ID: <20220711182227.GC2182@begut> X-ASG-Orig-Subj: Re: [PATCH] rockchip: rk3399: boot_devices: fix eMMC node name References: <20220711141533.122440-1-foss+uboot@0leil.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20220711141533.122440-1-foss+uboot@0leil.net> User-Agent: Mutt/1.10.1 (2018-07-13) X-Barracuda-Connect: smtp01.tinet.org[195.77.216.131] X-Barracuda-Start-Time: 1657563748 X-Barracuda-URL: https://webmail.tinet.cat:443/cgi-mod/mark.cgi X-Barracuda-Scan-Msg-Size: 2315 X-Barracuda-BRTS-Status: 1 X-Barracuda-Bayes: SPAM GLOBAL 0.9590 1.0000 3.8734 X-Barracuda-Spam-Score: 3.87 X-Barracuda-Spam-Status: No, SCORE=3.87 using global scores of TAG_LEVEL=1000.0 QUARANTINE_LEVEL=6.0 KILL_LEVEL=8.0 tests= X-Barracuda-Spam-Report: Code version 3.2, rules version 3.2.3.99305 Rule breakdown below pts rule name description ---- ---------------------- -------------------------------------------------- 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.6 at phobos.denx.de X-Virus-Status: Clean El Mon, Jul 11, 2022 at 04:15:33PM +0200, Quentin Schulz deia: > From: Quentin Schulz > > When idbloader.img is flashed on the eMMC, the SPL still tries to load > from SPI-NOR first. > > This is due to an incorrect look-up in the Device Tree. Since commit > 822556a93459 ("arm: dts: sync the Rockhip 3399 SoCs from Linux"), the > node name (but not label) changed from sdhci@fe330000 to mmc@fe330000 > meaning U-Boot SPL is not looking for the correct node name anymore and > fails to find the "same-as-spl" node when eMMC is the medium from which > the SPL booted. > Yes, I also saw that. I changed and tested it at some time, but since there were other changes, I hesitate to send a Tested by for your patch. FWIW: Reviewed-by: Xavier Drudis Ferran > Fixes: 822556a93459 ("arm: dts: sync the Rockhip 3399 SoCs from Linux") > Cc: Quentin Schulz > Signed-off-by: Quentin Schulz > --- > > Sorry for resend, was not yet subscribed. > > arch/arm/mach-rockchip/rk3399/rk3399.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/arch/arm/mach-rockchip/rk3399/rk3399.c b/arch/arm/mach-rockchip/rk3399/rk3399.c > index 01a05599cd..de11a3fa30 100644 > --- a/arch/arm/mach-rockchip/rk3399/rk3399.c > +++ b/arch/arm/mach-rockchip/rk3399/rk3399.c > @@ -27,7 +27,7 @@ DECLARE_GLOBAL_DATA_PTR; > #define GRF_BASE 0xff770000 > > const char * const boot_devices[BROM_LAST_BOOTSOURCE + 1] = { > - [BROM_BOOTSOURCE_EMMC] = "/sdhci@fe330000", > + [BROM_BOOTSOURCE_EMMC] = "/mmc@fe330000", > [BROM_BOOTSOURCE_SPINOR] = "/spi@ff1d0000/flash@0", > [BROM_BOOTSOURCE_SD] = "/mmc@fe320000", > }; > @@ -181,7 +181,7 @@ const char *spl_decode_boot_device(u32 boot_device) > const char *ofpath; > } spl_boot_devices_tbl[] = { > { BOOT_DEVICE_MMC1, "/mmc@fe320000" }, > - { BOOT_DEVICE_MMC2, "/sdhci@fe330000" }, > + { BOOT_DEVICE_MMC2, "/mmc@fe330000" }, > { BOOT_DEVICE_SPI, "/spi@ff1d0000" }, Not related to this patch, but I also changed "/spi@ff1d0000" -> "/spi@ff1d0000/flash@0". Not sure whether it needs to be different in both arrays in some case for some reason. > }; > > -- > 2.36.1 >