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 D4ADDC636CC for ; Wed, 8 Feb 2023 00:16:12 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id B9E5785E4A; Wed, 8 Feb 2023 01:16:08 +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="JN090cP6"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 6B4C285DB4; Wed, 8 Feb 2023 01:16:06 +0100 (CET) Received: from mail-qv1-xf2d.google.com (mail-qv1-xf2d.google.com [IPv6:2607:f8b0:4864:20::f2d]) (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 71C7C85DC6 for ; Wed, 8 Feb 2023 01:16:01 +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-qv1-xf2d.google.com with SMTP id d13so10363290qvj.8 for ; Tue, 07 Feb 2023 16:16:01 -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=wYecdRRIV34JLCcscc6Ra6vHgNX+jTOdSTEyhtveXxQ=; b=JN090cP6eaC/iImNKWfC7PLueM0dbGgNXqITer20qfgzyhLIAOK1WcmpQHZRIYxuk4 /A3SNmyGkfqzizk0C1xTphN4cIdews1VHoA6tvtI/vd8qKz800h47c5lsuxnvGq3hQjf EJdbw0PvLcM/ne+d0QdBUbyht82eSF72/gWQ0= 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=wYecdRRIV34JLCcscc6Ra6vHgNX+jTOdSTEyhtveXxQ=; b=EMHcHmcEoJ9OmUbkza15t7PGnc/Vd6/IPk5w06uFL9kOz9+iacA/p9cifg8KQ4Gy31 SZaGHOZ8PZdBxVbTty0OqYnB+8hJPZAC3q5ALmZxqfp4BNk56UeoDj+YkTwP1HO7621L vo58cEScPuXVTjZRrEylxmtvC6srWtvVUcXwAva3wfPamhbsIWrXzibifYHmliR0gye3 GMD4jVP64XnXIn4HYFjSnOCtCIesFUEJ9SgenIvWYNv7X8dPxTgO7nJNfKJAKgSDEfZg U2Wraf30p08gK1RmLvT5/ZT6bmT/hsqBY63hZ18vd14+MM+oL07fCcgZnpV9zfHfrk/q NE7A== X-Gm-Message-State: AO0yUKWpQWQpz+RjOD7p/rGv1rkyY64+Y6i+YvX2ImiELTB/mADDx8IS 6SnhDEHTdObsv+G54v4Ay/6IMFnZbJRDr76ar0s= X-Google-Smtp-Source: AK7set+8fjsRTnFCeiGEDw/Ho+2fh0MjMHBjxSRmTLrm7SrgqLxwdFYVz0iLCODHF9Y42bVI6XW5Jw== X-Received: by 2002:a05:6214:411a:b0:56b:fe88:43a9 with SMTP id kc26-20020a056214411a00b0056bfe8843a9mr1258254qvb.41.1675815360226; Tue, 07 Feb 2023 16:16:00 -0800 (PST) Received: from bill-the-cat (2603-6081-7b00-6400-90cc-7e59-435b-3104.res6.spectrum.com. [2603:6081:7b00:6400:90cc:7e59:435b:3104]) by smtp.gmail.com with ESMTPSA id u10-20020a05622a010a00b003b80fdaa14dsm10788819qtw.73.2023.02.07.16.15.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Feb 2023 16:15:59 -0800 (PST) Date: Tue, 7 Feb 2023 19:15:57 -0500 From: Tom Rini To: Simon Glass Cc: Michal Simek , u-boot@lists.denx.de, U-Boot Custodians Subject: Re: [PATCH v3 6/8] dm: treewide: Complete migration to new driver model schema Message-ID: References: <20230201225428.2001161-1-sjg@chromium.org> <20230201225428.2001161-7-sjg@chromium.org> <5919786f-354d-7d7f-d2a7-19f0b7121a0c@amd.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="Y6nzsfLbNsKRTOpP" Content-Disposition: inline In-Reply-To: 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 --Y6nzsfLbNsKRTOpP Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Feb 07, 2023 at 03:25:18PM -0700, Simon Glass wrote: > Hi Tom, >=20 > On Tue, 7 Feb 2023 at 14:46, Tom Rini wrote: > > > > On Tue, Feb 07, 2023 at 02:43:49PM -0700, Simon Glass wrote: > > > Hi Tom, > > > > > > On Tue, 7 Feb 2023 at 14:06, Tom Rini wrote: > > > > > > > > On Mon, Feb 06, 2023 at 10:12:27AM -0700, Simon Glass wrote: > > > > [snip] > > > > > On Mon, 6 Feb 2023 at 07:56, Michal Simek = wrote: > > > > > > > > > > > > > > > > > > > > > > > > On 2/6/23 15:44, Tom Rini wrote: > > > > > > > On Mon, Feb 06, 2023 at 01:22:48PM +0100, Michal Simek wrote: > > > > > > >> Hi Simon, > > > > > > >> > > > > > > >> On 2/1/23 23:54, Simon Glass wrote: > > > > > > >>> Update various build and test components to use the new sch= ema. > > > > > > >>> > > > > > > >>> Signed-off-by: Simon Glass > > > > > > >>> --- > > > > > > >>> > > > > > > >>> (no changes since v1) > > > > > > >>> > > > > > > >>> drivers/core/ofnode.c | 10 +++++----- > > > > > > >>> drivers/video/video-uclass.c | 4 ++-- > > > > > > >>> dts/Kconfig | 2 +- > > > > > > >>> include/dm/device.h | 2 +- > > > > > > >>> include/dm/ofnode.h | 10 +++++----- > > > > > > >>> scripts/Makefile.lib | 12 ++++++------ > > > > > > >>> test/dm/test-fdt.c | 2 +- > > > > > > >>> test/py/tests/test_ofplatdata.py | 8 ++++---- > > > > > > >>> tools/binman/binman.rst | 3 +-- > > > > > > >>> tools/dtoc/test_fdt.py | 8 ++++---- > > > > > > >>> 10 files changed, 30 insertions(+), 31 deletions(-) > > > > > > >>> > > > > > > >>> diff --git a/drivers/core/ofnode.c b/drivers/core/ofnode.c > > > > > > >>> index 4d56b1a7675..5249a60639b 100644 > > > > > > >>> --- a/drivers/core/ofnode.c > > > > > > >>> +++ b/drivers/core/ofnode.c > > > > > > >>> @@ -1265,22 +1265,22 @@ bool ofnode_pre_reloc(ofnode node) > > > > > > >>> { > > > > > > >>> #if defined(CONFIG_SPL_BUILD) || defined(CONFIG_TPL_BUIL= D) > > > > > > >>> /* for SPL and TPL the remaining nodes after the fdtgre= p 1st pass > > > > > > >>> - * had property dm-pre-reloc or u-boot,dm-spl/tpl. > > > > > > >>> + * had property bootph-all or bootph-pre-sram/bootph-pr= e-ram. > > > > > > >>> * They are removed in final dtb (fdtgrep 2nd pass) > > > > > > >>> */ > > > > > > >>> return true; > > > > > > >>> #else > > > > > > >>> - if (ofnode_read_bool(node, "u-boot,dm-pre-reloc")) > > > > > > >>> + if (ofnode_read_bool(node, "bootph-all")) > > > > > > >>> return true; > > > > > > >>> - if (ofnode_read_bool(node, "u-boot,dm-pre-proper")) > > > > > > >>> + if (ofnode_read_bool(node, "bootph-some-ram")) > > > > > > >>> return true; > > > > > > >>> /* > > > > > > >>> * In regular builds individual spl and tpl handling bo= th > > > > > > >>> * count as handled pre-relocation for later second ini= t. > > > > > > >>> */ > > > > > > >>> - if (ofnode_read_bool(node, "u-boot,dm-spl") || > > > > > > >>> - ofnode_read_bool(node, "u-boot,dm-tpl")) > > > > > > >>> + if (ofnode_read_bool(node, "bootph-pre-ram") || > > > > > > >>> + ofnode_read_bool(node, "bootph-pre-sram")) > > > > > > >>> return true; > > > > > > >> > > > > > > >> Please correct me if I am wrong but this change will likely = break all boards > > > > > > >> which didn't migrate to this at this stage. And because targ= eting early > > > > > > >> stages people will be without console. > > > > > > >> I think we should have transition period for 1-2 releases to= give people > > > > > > >> enough time to migrate. It means print big warning that they= have to migrate > > > > > > >> their DTS. > > > > > > > > > > > > > > What's the migration case here we're missing? Is it platforms= that > > > > > > > maintain a dts externally, via tooling / etc, that populate t= hose nodes? > > > > > > > > > > > > Yes and I expect there will be a lot of DTs around with some ch= anges for > > > > > > specific products. > > > > > > > > > > > > Also for example QEMU is also generating DT based on it's confi= guration and > > > > > > provide it to U-Boot. > > > > > > https://gitlab.com/qemu-project/qemu/-/blob/master/hw/arm/xlnx-= versal-virt.c#L91 > > > > > > When this patch is applied CI loop should fail for Versal. > > > > > > > > > > I am not sure how it helps us to drag this out. It is a breaking > > > > > change, but a drawn-out process is just going to create a lot of > > > > > confusion. People should be free to use the schema in Linux .dts = files > > > > > from now on, but if it is not immediately supported in U-Boot then > > > > > they cannot. This is the most important point, after all. > > > > > > > > Now that we've had some of the external migration issues laid out, = what > > > > would it look like to have some sort of backwards compatible hook h= ere > > > > to fixup an older tree we've been passed? > > > > > > We can't do it for SPL, since the processing happens at built time, > > > but for U-Boot proper we can do something like what Michal suggests, > > > although perhaps with a warning rather than an error. Likely the > > > warning would have to be displayed later (if/when U-Boot starts up) > > > since the console may be one of the problem nodes. > > > > Right, if it's a build time thing, we should be able to ... something. > > Maybe a detect and rename for now, detect and fail in a bit. But >=20 > But we only have this problem with out-of-tree .dts files, so I'm not > sure what you are suggesting here. I'm suggesting that you add the logic to detect these cases and deal with it. We aren't talking about stuff that should have been upstreamed but wasn't, we're talking about tooling that generates valid dts files and needs time to update. --=20 Tom --Y6nzsfLbNsKRTOpP Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEGjx/cOCPqxcHgJu/FHw5/5Y0tywFAmPi6b0ACgkQFHw5/5Y0 tywXpwv/S2bORiaotJu9snCMZYXRvpa61ZwfkctwQRye+0DGQP/7a/snZz7neCAQ uTZp3PEzIimDQ1a4Wx18CnLQDcRqQ2AeJiZ9RnyFPkrwemcIDMxtsQHOIAMBTUGY wPYoquu8URRTBe/M4jiGxh2a7W52WEhFBHMIlt/hFMW2DSL+LIB6WDtlydg9sMpm tWAvDY8frawmWPaiQd/uteNwVkLiLZmYHfPNkwyNEV4/ctCNxG3T5IzEzYUTVgHc BgYk8iRIQVsG5n/G2J4K21mdettNluKW8ow6MDwBqgr15NUZNLcGt39y6cXObK4b SeSn6NWrUduLNR9Yf3vHlJhpD2HvogRNnRfnPKIR/Br8OXdg+q6PiLFCDrsmU2Dp 0+nAJwJ3RmsO4iPd9i/yFgvGDjn8FebIHDv29B+gzCH2C9omy6PnN62BFZNeqO65 46LiswFGUqslo8k+U+8AztdsnR9MDOte1x18HLDjwBu8LDeiMpaqJMQlj5NCVkLt VnXWnXH8 =hNZy -----END PGP SIGNATURE----- --Y6nzsfLbNsKRTOpP--