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 D34ECC433FE for ; Mon, 21 Nov 2022 17:45:42 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id D0CB1852EB; Mon, 21 Nov 2022 18:45:40 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=konsulko.com 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=konsulko.com header.i=@konsulko.com header.b="AasqGdcB"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 4D5D4852E1; Mon, 21 Nov 2022 18:45:40 +0100 (CET) Received: from mail-qk1-x731.google.com (mail-qk1-x731.google.com [IPv6:2607:f8b0:4864:20::731]) (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 08ADF853F3 for ; Mon, 21 Nov 2022 18:45:36 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=trini@konsulko.com Received: by mail-qk1-x731.google.com with SMTP id s20so8539915qkg.5 for ; Mon, 21 Nov 2022 09:45:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=konsulko.com; s=google; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=8alKia48cDEYY5E1j3hdDDm/1T7CxEuG1SpQvkvYv9M=; b=AasqGdcBgyaytXZupQEepvokJowb2n3RdWGN22JBJmNihc7t3PwrcnyuSBrD1pOSL0 dqAGjrMpFmjITsvZdBlgACR/NQgitEgcOe5ErbToxkP7SDWUra89NkF8s/RoO2cRsiAH Di1l6xCqrSN3wP7hlyuNLsjghOO7iGW9ZGXGI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=8alKia48cDEYY5E1j3hdDDm/1T7CxEuG1SpQvkvYv9M=; b=alX/kJHoG/izfbmIY4AXbp/Wok+DS8BZNoERsj0Inz2rztrovbO/YDU25y2Ht02ke0 ALl2Ly6W7P9QRiCsbnUCchoWGRdSkzbwRNSZwFtdk6l3XODfg2s2ZOZMoNg5Vya/NhzZ Sk1oQDKm/zKft8npcnGQv4ekhHUJwkDFYXdbaSW9KrY6YBuP9uBj2Gck7P+XJ5gHmkH2 EOCxodGTTmsHke2i0ZcCenE7WS6Nbigeh/9tzxHv2MmWLKfE6yv+95zcsmz+npZFYaKK 6P7H2A7LaqZGoHJTPxd2h8CLr8/z8vXhTt+2AUACEkicr4B+7zxGRQgGwsnpoBkexCqS XjaA== X-Gm-Message-State: ANoB5plqB+5IrtuxysAhuIJBi/yjV/NE2p0UUFaElqdWmziuuVhnOlAg XmFVf/2VxLpY7JwNmD/7zt/7AA== X-Google-Smtp-Source: AA0mqf7yeqXT37d51f+Yp4XQ4Ab6qQXThKJRQb20V9ZQardntIH2TvHs9yidDJNrZ1oRRQyyrLK6Gg== X-Received: by 2002:a37:8846:0:b0:6e5:3b93:2e55 with SMTP id k67-20020a378846000000b006e53b932e55mr5099382qkd.752.1669052734853; Mon, 21 Nov 2022 09:45:34 -0800 (PST) Received: from bill-the-cat (2603-6081-7b00-6400-91a3-6c7b-3405-8039.res6.spectrum.com. [2603:6081:7b00:6400:91a3:6c7b:3405:8039]) by smtp.gmail.com with ESMTPSA id bk23-20020a05620a1a1700b006ce580c2663sm8553708qkb.35.2022.11.21.09.45.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 21 Nov 2022 09:45:34 -0800 (PST) Date: Mon, 21 Nov 2022 12:45:32 -0500 From: Tom Rini To: Pali =?iso-8859-1?Q?Roh=E1r?= Cc: Marek =?iso-8859-1?Q?Beh=FAn?= , Simon Glass , u-boot@lists.denx.de Subject: Re: [PATCH v2] board_f: Add support for CONFIG_OF_BOARD_FIXUP for XIP images Message-ID: <20221121174532.GX7282@bill-the-cat> References: <20220827181220.471-1-pali@kernel.org> <20220828151929.32588-1-kabel@kernel.org> <20221101232303.7wdt7xrsalkydlan@pali> <20221121174201.u3qoksqewebvpeve@pali> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="4vu0d+lqoSa2/ZEk" Content-Disposition: inline In-Reply-To: <20221121174201.u3qoksqewebvpeve@pali> X-Clacks-Overhead: GNU Terry Pratchett 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 --4vu0d+lqoSa2/ZEk Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Nov 21, 2022 at 06:42:01PM +0100, Pali Roh=E1r wrote: > + Tom >=20 > On Wednesday 02 November 2022 00:23:03 Pali Roh=E1r wrote: > > On Monday 10 October 2022 17:48:58 Simon Glass wrote: > > > Hi, > > >=20 > > > On Sun, 28 Aug 2022 at 09:19, Marek Beh=FAn wrote: > > > > > > > > From: Pali Roh=E1r > > > > > > > > When U-Boot is running from flash memory (execute in place) then > > > > gd->fdt_blob before relocation points to read-only flash memory. > > > > > > > > So U-Boot calls board_fix_fdt() with read-only gd->fdt_blob pointer= which > > > > cause immediate CPU crash when callback is trying to modify gd->fdt= _blob. > > > > > > > > Fix this issue by introducing a new config option > > > > OF_DTB_READONLY_BEFORE_RELOC which moves fix_fdt callback after the > > > > reloc_fdt callback. This makes CONFIG_OF_BOARD_FIXUP working also if > > > > U-Boot before relocation is not running from read/write (S)RAM memo= ry. > > > > > > > > This is required for mpc85xx boards when booting from flash NOR. > > > > > > > > Signed-off-by: Pali Roh=E1r > > > > Signed-off-by: Marek Beh=FAn > > > > --- > > > > Changes since v1: > > > > - just changed the new Kconfig option name and associated help stri= ng > > > > --- > > > > common/board_f.c | 8 +++++++- > > > > dts/Kconfig | 6 ++++++ > > > > 2 files changed, 13 insertions(+), 1 deletion(-) > > >=20 > > > Can we just make this the normal behaviour? I think it makes more > > > sense to change the FDT after we have relocated it. Can we? --=20 Tom --4vu0d+lqoSa2/ZEk Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEGjx/cOCPqxcHgJu/FHw5/5Y0tywFAmN7uTUACgkQFHw5/5Y0 tywt2gwAp7C+vQSV1geNDLTwSTVAFfV6Jan4HVY3+TwcLqdatRFsTkMBK6oD3AMk 7jALMIsxcfpCSvPt+I+EylKjV6YERPu0CnJFM2LNQRRMA9Ka5W5s2jFOECm5kY9n wZatEh+dW4ROjDy/+k+0y3PAr5xuZkQTSNvwpGhi1IDh34ZV5i8BCiizXMta46/e 1C6dPS5Xs/73Vam+Pgt5qNAylaXNQcrrmKAr8V6TU+arZWvAeFkAF5DxyhWDvooh 9tZFwPDPzfJwqtAN8NPmMdhHbGoR2oo4yG91HCHSA75cC19d/LG7lj5nWbmvjFlS vY73k3FGpcg2duXDIAhVkEvH/59y4yhMCro3l9uRQHdbU3KSKxWlsu99JlEphN4v U+mmGkMx+pNgCSVK7MXzYRqbXtaHs4hFgQgWnASDLxn0biCdI0+gWrEBzQ50fZug 32dxkxIg5SLkIDBfKjsQdjBF1hiSdTvo1LzX4MDQplp7Z2MtqELTvwVBB+loL4HV ULC7061q =oVMC -----END PGP SIGNATURE----- --4vu0d+lqoSa2/ZEk--