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 C25C9EB64DA for ; Wed, 19 Jul 2023 13:34:27 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 88AD186765; Wed, 19 Jul 2023 15:34:25 +0200 (CEST) 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="Rl05baAe"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id C524686765; Wed, 19 Jul 2023 15:34:23 +0200 (CEST) Received: from mail-yw1-x112e.google.com (mail-yw1-x112e.google.com [IPv6:2607:f8b0:4864:20::112e]) (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 9CB7686763 for ; Wed, 19 Jul 2023 15:34:20 +0200 (CEST) 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-yw1-x112e.google.com with SMTP id 00721157ae682-5728df0a7d9so70599297b3.1 for ; Wed, 19 Jul 2023 06:34:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=konsulko.com; s=google; t=1689773659; x=1692365659; 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=dwKSVyww8DkCHg9gzDdoGGNsySbvtz3QKmG/uuAcmRY=; b=Rl05baAe3/UC31iGmkqldePP2Yr1xlcNUemlbK3ZAdFJm9Qv8779V3fFd5jblJsXIN NxMNmecu3ZHY54xFShJA2Qq6FUuDm0PFQTL20V2XiZoG07JziaRMn4Ecl2LlafUUNE9h d/Dj+hLmce1Bx5yiTPjteVm7tH9+za5wsicec= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689773659; x=1692365659; 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=dwKSVyww8DkCHg9gzDdoGGNsySbvtz3QKmG/uuAcmRY=; b=jAkeKZP3NV2HswUwz7bNt/iNfBOPbhqbh37epAbpTOZSJRsKlnNVeyVKV2BzZ1e2vw se4xFBvXl1LD/nnKrAPBjyd29SPlVirRiPPFTKOP48NJvM5hhgI0X17x6aOIK8bUxY0Z lJeXO6be+yLYaPtjz/SAcfZo/TVreSlTRxqLFI2pT5TwzfZ2BiWR47iU69F2iEPEwmWp bA8K+cmME4BV8OqgX42T0zSrS3pS4ZFODlDsEMdbuSh09rZE11oWR/gXpEIMeo+MRIB/ ZRKe63j6MeEVx7Rle7KRmaN3/6Q1yCMgSxImacQ5v6jqyf4gSDQ7naF/sWdS1nlA7X/5 t1jg== X-Gm-Message-State: ABy/qLYNo0QlWZhCZBR0/oChK+Hldpa2e8aFhvpF8Unsg4xGLhqFEQch Q7QgU7G3X3LUp4OnXVgdOdu2vQ== X-Google-Smtp-Source: APBJJlHri3iGmz461n9LOlDcGyEAcpVMn8ZFsfixoX/zBft0LUDuL91suTmkuLLa78saAhHdcxKH9Q== X-Received: by 2002:a81:4990:0:b0:577:4975:c944 with SMTP id w138-20020a814990000000b005774975c944mr2927232ywa.42.1689773659380; Wed, 19 Jul 2023 06:34:19 -0700 (PDT) Received: from bill-the-cat (2603-6081-7b00-6400-db2e-065f-d044-b9a4.res6.spectrum.com. [2603:6081:7b00:6400:db2e:65f:d044:b9a4]) by smtp.gmail.com with ESMTPSA id c6-20020a0dc106000000b0055a07e36659sm999740ywd.145.2023.07.19.06.34.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 19 Jul 2023 06:34:18 -0700 (PDT) Date: Wed, 19 Jul 2023 09:34:16 -0400 From: Tom Rini To: Simon Glass Cc: Jason Kacines , Andrew Davis , Vignesh Raghavendra , Bryan Brattlof , Praneeth Bajjuri , u-boot@lists.denx.de Subject: Re: [RFC PATCH 1/3] scripts: kconfig: Add config fragment support in board/../ Message-ID: <20230719133416.GV1670569@bill-the-cat> References: <20230711212048.1340990-1-j-kacines@ti.com> <20230711212048.1340990-2-j-kacines@ti.com> <20230713225441.GR2066889@bill-the-cat> <20230716151205.GR2066889@bill-the-cat> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="KsTk4J3fKaze+pS1" 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.8 at phobos.denx.de X-Virus-Status: Clean --KsTk4J3fKaze+pS1 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jul 18, 2023 at 07:07:58PM -0600, Simon Glass wrote: > Hi, >=20 > On Sun, 16 Jul 2023 at 09:12, Tom Rini wrote: > > > > On Sat, Jul 15, 2023 at 05:40:35PM -0600, Simon Glass wrote: > > > Hi Tom, > > > > > > On Thu, 13 Jul 2023 at 16:54, Tom Rini wrote: > > > > > > > > On Wed, Jul 12, 2023 at 08:00:28AM -0600, Simon Glass wrote: > > > > > Hi Jason, > > > > > > > > > > On Tue, 11 Jul 2023 at 16:29, Jason Kacines wr= ote: > > > > > > > > > > > > Add support to config fragments (.config) located in the /board > > > > > > directory. This will allow only base defconfigs to live in /con= figs and > > > > > > > > > > Does this mean defconfigs? > > > > > > > > This looks like it would cover defconfig files too, but the initial > > > > motivation is config fragments. See > > > > https://patchwork.ozlabs.org/project/uboot/patch/20230606071850.270= 001-5-clamor95@gmail.com/ > > > > for another example. > > > > > > > > > > all fragments to live in their respective device directory in /= board/.. > > > > > > > > > > Why do we want this? The patch should have a motivation. > > > > > > > > I've asked a few people to look in to this because we have a lot of > > > > cases today of N _defconfig files where we could really instead hav= e 1 > > > > _defconfig file and N config fragment files. But I do not want them > > > > living in the top level configs directory as that will get even more > > > > unmanageable. > > > > > > OK I see, thank you. The patch still needs this motivation though. > > > > So you're saying you want the message re-worded? >=20 > Yes, to explain why. I think the message is fine as it clearly says what it does. > Could we also get some docs in doc/build/gcc.rst or similar? No, I don't think that makes sense yet. And looking at that doc, we should split that up in to compiler specifics and then a general build doc. Using fragments belongs in the board docs which use fragments (as is done in the series which have boards using fragments) and as a general "do this to make developing your board easier" that should come later once there's more agreement and understanding of what we can and should do with fragments, rather than meta-options in Kconfig. > > > > What's not in this patch (and not an ask at this point) is figuring= out > > > > how buildman could handle "foo_defconfig bar.config" as the required > > > > config target. > > > > > > Indeed. Also, should they appear in the boards.cfg list? > > > > I doubt it? I'm not sure yet how we address getting buildman to know > > about valid additional combinations. Take the example of something like: > > som_vendor_carrier_defconfig + som_vendor_imx7_som.config + > > emmc_boot_instead.config + customer_production_tweaks.config > > > > How would you want buildman to know about that? Does it even really need > > to, on the other hand? And that's not I think an uncommon example, it's > > just splitting colibri_imx7_emmc_defconfig in to how it would be used by > > someone taking that carrier+som to production, with their own > > touchscreen and a few other tweaks in the dtb that needs to be passed to > > linux. Or the mnt reform with whatever SOM/COM you happen to have for > > it. >=20 > Well firstly we should only worry about things that are in-tree. Well, since I'm not letting people bring in fragments until it won't make the configs directory even more unmanageable, we have a problem. The problem which this patch solves. And the example I gave above is in-tree, except for the final step of "now make this my product", which when it's a matter of a new device tree and config, is fine for most cases. > The thing is, if we don't validate that the configs at least build, > then someone could change a config (anywhere in Kconfig or in a 'base' > defconfig) and break the build for these 'add-on' configs. Also if I'm not worried about this at the start. If people start trying to enable unique drivers only in fragments, we have a problem. But based on all of the proposed uses so far, we shouldn't see unique settings there that we need to have compile tested all the time. > there is no record of what fragments can be built with what, it could > get awfully confusing. Exactly why I want these fragments to be able to live in the board directory rather than the top level configs directory. Honestly, this also opens up the possibility of moving the defconfig files from configs/ to the board directory and I think that would be really good. > I would suggest an interface where you can query which fragments are > available for a board, and that buildman support building them. For > that to work, we need some sort of structure. For example the config > fragment could have a line listing the defconfig / .config filename it > is intended to augment. I'm not sure how buildman will handle fragments, if at all, but that's a secondary consideration. Buildman isn't used by most people and in most cases, "make" is, and that supports (and has supported for I don't know how many years, off-hand) config fragments. --=20 Tom --KsTk4J3fKaze+pS1 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEGjx/cOCPqxcHgJu/FHw5/5Y0tywFAmS35lQACgkQFHw5/5Y0 tyzmSAv+KTl1G+r8zYxmaPFmQ8xaYLZ2lIgjH6lSavYpTKCDCYBzBSHyj1I/aJuw BlzgNnrppRvlIgMVXYTLKCD6lV3jSRmrCjUIaMJ311gvQifZMLB5hMwtj1JkHYQz 1xjxbF3OBi7x20AnwjBlP3k81Emso29JvHN1dvQLKAIUPfRDwlAbFSjO+LKV6GZS q3oEpM76tH1mZi4tdbTbVAXnHO99cgedKTwJrEKFECObUNsRQ6OjGSHzLxSBqziF 8g8mEW5JSIuolj7nSgmkhgvjk2IACq1xnGkSK/dLCiNMQdDBo/mA1nBDdtuvnKF0 uY/vsTKFLOR5cGMreVFbk0SMzZ0wPP+fxkefmmg0JFxk6tkqLSku2boB4cK3uwNp dS9MePJT42lw3WVdN56+hrr9llQm5rXStC1BP8rHTTNOmWvhIudgvSvO/cJr1FIz oe8wDdHWuO5utIt3E4KqRMzvcCV6NB3mHHKIkqUyg1NNM/7RRof5rf76arRpCqp6 I2eyAV5R =9ONf -----END PGP SIGNATURE----- --KsTk4J3fKaze+pS1--