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 X-Spam-Level: X-Spam-Status: No, score=-17.3 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E5467C4338F for ; Fri, 30 Jul 2021 21:33:13 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id BD1EC60F94 for ; Fri, 30 Jul 2021 21:33:12 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org BD1EC60F94 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id BAD5A8310F; Fri, 30 Jul 2021 23:33:09 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (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="gQdC17ov"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id A82F88310F; Fri, 30 Jul 2021 23:33:08 +0200 (CEST) Received: from mail-qt1-x829.google.com (mail-qt1-x829.google.com [IPv6:2607:f8b0:4864:20::829]) (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 B4C9482DD5 for ; Fri, 30 Jul 2021 23:33:04 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=trini@konsulko.com Received: by mail-qt1-x829.google.com with SMTP id x9so7433400qtw.13 for ; Fri, 30 Jul 2021 14:33:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=konsulko.com; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=WxuOHIKTtTkALiyhejUuttCq//Xcss539gcijjciYh4=; b=gQdC17ovfgK3P1R4Jl7IRlpLgZo62rog627iVsPTU/fSrrGfVYHYWqZYXMohiMI5EA ATJ9rW4/DFpa700+LD3Ro579lDgSp7CQXgiJ3FJBSsLCfDHNsGy69BehSMa7pTWR7MEP +gFoN3+y2XXCjB3M4LBD6xmgNhT9B2Aec0YBI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=WxuOHIKTtTkALiyhejUuttCq//Xcss539gcijjciYh4=; b=hsAnxW4raRW4cOr8SGtD9xOsU2xxQtGzIe5YTYp72o8zSb+tQ2VXtmAru+u4RWNfeo 6kQhqeiG9FBFi5YxQVHvRpBGC2PnyiAidf81H89ns6PFBBdEHnGybq2yYcidmh4sXY6x VVBV6AqILqZW4IaPjJ5bKWSBCVQdP+dECsvojo4MXcRTSLZ3BzFstnupo31HXciGJRZL SKbz5vfLYg1pF6AY20ELiH9ntrOmOIAREiQaTcc+aY1eZS/il2TGBW80qtRHDzrbKay+ yPR6Lld49bw7hrlIeR6J9tdgHu3VO/fjawS3VzGmhXdxpuYJU1Xd2ICp+qkAJr2bMFdb 9BqQ== X-Gm-Message-State: AOAM532FOW4qm468w11BnlzH3Tx2YaKlnF4PUr/eGgU+iUbmyfqYvzHD XhlJOrs3ooA7fQIupmip/JdsBA== X-Google-Smtp-Source: ABdhPJz/8hnc7U/fSbQzCcEOfFRLOxfjRJyISG1VYv/HcFtBqQ8kcyuMarlz6SJjZLogEwYnIRwXhw== X-Received: by 2002:ac8:5e97:: with SMTP id r23mr4166508qtx.35.1627680783245; Fri, 30 Jul 2021 14:33:03 -0700 (PDT) Received: from bill-the-cat (2603-6081-7b01-cbda-21f8-31e9-a342-f65d.res6.spectrum.com. [2603:6081:7b01:cbda:21f8:31e9:a342:f65d]) by smtp.gmail.com with ESMTPSA id f15sm1167822qtv.60.2021.07.30.14.33.02 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Fri, 30 Jul 2021 14:33:02 -0700 (PDT) Date: Fri, 30 Jul 2021 17:33:00 -0400 From: Tom Rini To: Simon Glass Cc: Heinrich Schuchardt , U-Boot Mailing List , Ilias Apalodimas , Pali =?iso-8859-1?Q?Roh=E1r?= , Mark Kettenis Subject: Re: [PATCH v2 7/9] Make EFI_LOADER depend on DM and OF_CONTROL Message-ID: <20210730213300.GE9379@bill-the-cat> References: <20210702183620.1542680-1-sjg@chromium.org> <20210702183620.1542680-4-sjg@chromium.org> <20210726220735.GA8013@bill-the-cat> <5dba1547-37cc-14f0-1514-1dc337b0d25e@gmx.de> <20210728235513.GJ9379@bill-the-cat> <20210729135247.GO9379@bill-the-cat> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="1leoDTfY/rGR/Atp" Content-Disposition: inline In-Reply-To: X-Clacks-Overhead: GNU Terry Pratchett User-Agent: Mutt/1.9.4 (2018-02-28) X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.2 at phobos.denx.de X-Virus-Status: Clean --1leoDTfY/rGR/Atp Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jul 30, 2021 at 01:02:18PM -0600, Simon Glass wrote: > Hi Tom, >=20 > On Thu, 29 Jul 2021 at 07:52, Tom Rini wrote: > > > > On Wed, Jul 28, 2021 at 07:44:37PM -0600, Simon Glass wrote: > > > Hi, > > > > > > On Wed, 28 Jul 2021 at 17:55, Tom Rini wrote: > > > > > > > > On Thu, Jul 29, 2021 at 01:45:49AM +0200, Heinrich Schuchardt wrote: > > > > > > > > > > > > > > > On 7/27/21 12:07 AM, Tom Rini wrote: > > > > > > On Fri, Jul 02, 2021 at 12:36:18PM -0600, Simon Glass wrote: > > > > > > > > > > > > > This feature should never have been made available when drive= r model > > > > > > > or devicetree are disabled. Add these as conditions, so that = we don't > > > > > > > create even more barriers to migration. > > > > > > > > > > > > > > Add a note about the substantial size increment associated wi= th this > > > > > > > option. > > > > > > > > > > > > > > Signed-off-by: Simon Glass > > > > > > > --- > > > > > > > > > > > > > > Changes in v2: > > > > > > > - Split out new patch to make EFI_LOADER depend on DM and OF_= CONTROL > > > > > > > - Note the approximate size of this feature in the help > > > > > > > > > > > > > > lib/efi_loader/Kconfig | 4 +++- > > > > > > > 1 file changed, 3 insertions(+), 1 deletion(-) > > > > > > > > > > > > > > diff --git a/lib/efi_loader/Kconfig b/lib/efi_loader/Kconfig > > > > > > > index 6242caceb7f..466abfed300 100644 > > > > > > > --- a/lib/efi_loader/Kconfig > > > > > > > +++ b/lib/efi_loader/Kconfig > > > > > > > @@ -1,6 +1,6 @@ > > > > > > > config EFI_LOADER > > > > > > > bool "Support running UEFI applications" > > > > > > > - depends on OF_LIBFDT && ( \ > > > > > > > + depends on OF_LIBFDT && DM && OF_CONTROL && ( \ > > > > > > > > > > Didn't Tom eliminate all boards without CONFIG_DM? Shouldn't we g= et rid > > > > > of this symbol? > > > > > > > > No, but I did send out a message about that today as we're very clo= se. > > > > Much closer than I had expected us to be. > > > > > > Note we will still have SPL_DM, I think. > > > > Right. > > > > > > > Are there boards using DM and not OF_CONTROL or OF_CONTROL and no= t DM? > > > > > > > > Yes, a few. It's vexpress_aemv8a_semi, warp (fixed by > > > > https://patchwork.ozlabs.org/project/uboot/patch/20210402180552.107= 5997-2-pbrobinson@gmail.com/ > > > > so false positive), cm_t335, devkit8000, armadillo-800eva, kzm9g an= d sniper. > > > > > > > > > Why are these separate symbols? Isn't this symbol to be eliminate= d, too? > > > > > > > > Simon? > > > > > > If we do eliminate DM it will be in a separate series. Like Tom I am > > > pleasantly surprised at how close we are. > > > > > > But please let's consider patches on their merits. It is fine to reply > > > with a wishlist but even better to reply with a follow-up patch. > > > > OK. So, build-wise, EFI_LOADER does not require OF_CONTROL. >=20 > I strongly believe it should (and it should have 5 years ago too). New > features should not be built on pre-migration stuff. Well, what legacy interfaces is it using? That's something to figure out and address as needed.=20 > > > Somewhat related, I think we need to create a separate symbol which > > > means (OF_CONTROL && !OF_PLATDATA) so we can just check one thing. > > > > > > Also I think we should push of-platdata, since otherwise we're going > > > to hit the same problem of migrating SPL boards to DM one day. > > > > Note that we don't have CONFIG_OF_PLATDATA just > > CONFIG_(SPL|TPL)_OF_PLATDATA. >=20 > Indeed. But we haven't defined it because we don't want to permit it. > It is just for constrained environments and we assume that U-Boot > proper has enough space (how else could it load Linux?) If OF_PLATDATA for U-Boot itself makes sense or not is a separate discussion to have. > > > > > lib/efi_loader/efi_disk.c is the only place where we maintain dup= licate > > > > > code for DM and non-DM. A dependency on CONFIG_BLK (which itself = depends > > > > > on CONFIG_DM) would make more sense to me. But only in a patch > > > > > eliminating the non-BLK code. > > > > > > > > I just know that off-hand, partition + disk + block has some corner > > > > case, but maybe that corner case is unintentional in terms of usage > > > > today. > > > > > > > > > > > ARM && (SYS_CPU =3D arm1136 || \ > > > > > > > SYS_CPU =3D arm1176 || \ > > > > > > > SYS_CPU =3D armv7 || \ > > > > > > > @@ -25,6 +25,8 @@ config EFI_LOADER > > > > > > > will expose the UEFI API to a loaded application,= enabling it to > > > > > > > reuse U-Boot's device drivers. > > > > > > > > > > > > > > + For ARM 32-bit, this adds about 90KB to the size of U-Boo= t. > > > > > > > + > > > > > > > > > > There is no unit ISO prefix K. Do you mean KiB? > > > > > > > > > > 90 KiB may be the value today. Will you update it regularly? Othe= rwise > > > > > don't put a number here. > > > > > > > > > > I can't see that the effect on size is truly architecture specifi= c. Why > > > > > do you refer to 32bit ARM? > > > > > > > > > > Such a comment would better fit into a documentation chapter on > > > > > downsizing U-Boot. > > > > > > > > Yes, we should probably drop that specific note. > > > > > > From my POV I really like these notes in Kconfig. They appear in a few > > > places and provide people with rough guidance. I'd like to see more of > > > them. I don't know how we can keep them up-to-date, although I'd argue > > > that they should stay constant, if we are holding to our no-bloat > > > ideal. > > > > I feel like EFI gets a bit of an undeserved reputation here. It's not > > growing any worse than the rest of the world is over fixes and error > > correction (which is to say, 16/32/40 bytes here and there). And > > there's not "big" new default features coming in. >=20 > We can agree on the 'reputation' bit but I can't think of a more > deserving feature :-) >=20 > I keep getting the capsule-update series in my inbox, for example and > I know there is TPM stuff in the works. Yes, but TPM and capsule-update won't be default enabled for all platforms. I run every PR I get (and branch I make and merge) through a before/after world build and use buildman's sizes tools to check (aside, I'd love some csv output format for that, but I haven't gotten around to thinking on how to do that) and that's where I'm coming from on this. I am keeping an eye out for default new features everywhere, and default new functionality everywhere. --=20 Tom --1leoDTfY/rGR/Atp Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEGjx/cOCPqxcHgJu/FHw5/5Y0tywFAmEEcAUACgkQFHw5/5Y0 tyzHaAv/ck3ZtzkntMmB+rIyAziPmA1FXlzkQgT+4bLW5YmAuq6+oZSrr6AGzhjy RT0ijpI7BCIm5qkIQLl6+FNgkV9AoiB/0VPzOBYnHlfivFdETJtYe8eShlhOotaM xlAbt9RVn1fxm8uYPQCZiqPWLTWXUHnVz+p8R65AKcqezdk2jUpzNBV5zDtZwY+u HldC60sw9DrAcolmgK0zrHoNSsaTk9Qhk9U2DkMf2hI5nz6pC6fHUAHxgxrS+DB+ Nv9V3mJwLP+zYTf7e3GIf6SqJbjyiSJG6y4hqIZ24/1BHbo5+iW9jhMM6A5L3XDw osJi0XWBLW/JG35tQwp2mbCftS74yaCOlXUihnrnQTC5W8Hl5KjzjtAbBud1SM0d LXyheGMLCj6yS//J1ciqjKIu7+Mx0LZOdeul7wsz2wAGT5tUqjYSPhhnIqt/WnzA M0hj8zWPXAke/Ohqo1dDciC5oyOI47Hi091/b4zDK2Ym+4HumMdYFj4zsECfk16s W1OjkpsM =WtcC -----END PGP SIGNATURE----- --1leoDTfY/rGR/Atp--