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=-7.2 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no 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 50508C433F5 for ; Sat, 4 Sep 2021 19:56:56 +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 539C360F55 for ; Sat, 4 Sep 2021 19:56:55 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 539C360F55 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 00EB283265; Sat, 4 Sep 2021 21:56:52 +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="mAauDXM1"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id EBA4E83276; Sat, 4 Sep 2021 21:56:50 +0200 (CEST) Received: from mail-qt1-x82e.google.com (mail-qt1-x82e.google.com [IPv6:2607:f8b0:4864:20::82e]) (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 1C7D682DE4 for ; Sat, 4 Sep 2021 21:56:47 +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-x82e.google.com with SMTP id t35so2236699qtc.6 for ; Sat, 04 Sep 2021 12:56:47 -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=9CslluUN93VN9N77bbf8LDXkrNA33QseWxWpGP7yVes=; b=mAauDXM1RlhSXgE3G8/MIIOL9iTZPiI+0DwOfxn6MZzrsSAIeATUiHifMCnYakdRnD PtuzXpfep+JEgHs+3pe6qbi6og/GGEmct/Z2ppSIPjtAJ/VDQJ4pA60Xig+nES7Mz4aZ MqUp/vNsvkdEqUdoAtn6nuqmu5SE6hoWldNbI= 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=9CslluUN93VN9N77bbf8LDXkrNA33QseWxWpGP7yVes=; b=uVCYtpu8VIHaksuGgCCged8VRwJsGFLVJDFWnjFmGcD+oJnUgJdfEt2NrkcqdSG/UE V8Pa4bgS4xzmwt2beWpbLUqXxqyqwGU6f85soGqkuVBxydZYELZFJ/IqkrHQP95fL2vO KhUNoZS9+TM5housaG2DglxxUswQoSGWR6ZbV5iUaVZS2+CmpEJ+jkn04sbb7kRq69eH b8FmMB2wriZujc2iEE7MuRY0T+Q8/7TTPVRm1sAf0yJpT1KOsgsGTdNiFSoeLTH1dtl5 2TlxouhWGSEDBw6GdJ1TVRZ8F5PfEAS4qT2vVLCQuNq7zGOLJJAObqelnw+4GnLSILyj 692w== X-Gm-Message-State: AOAM531db9XkztuvTX/fdKy111VQf+HhzoxT0LvJ0VnYAqLXuaPkz3/d 6mnLkwHOeMoOV8fZu2bhg5fPnA== X-Google-Smtp-Source: ABdhPJwcpCcEz62hKCxXv5bjiuptFtF80FUDJz9uTMoQLj8Dg9ceHBRPXVbFmwCc8mfwCrbOdqL2Dw== X-Received: by 2002:ac8:1289:: with SMTP id y9mr4697887qti.378.1630785405569; Sat, 04 Sep 2021 12:56:45 -0700 (PDT) Received: from bill-the-cat (2603-6081-7b01-cbda-eda5-0c2a-e600-b83e.res6.spectrum.com. [2603:6081:7b01:cbda:eda5:c2a:e600:b83e]) by smtp.gmail.com with ESMTPSA id e25sm2329008qka.83.2021.09.04.12.56.44 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Sat, 04 Sep 2021 12:56:44 -0700 (PDT) Date: Sat, 4 Sep 2021 15:56:43 -0400 From: Tom Rini To: Marek Vasut Cc: u-boot@lists.denx.de Subject: Re: [PATCH 02/14] lmb: Use CONFIG_LMB_*_REGIONS only if they are defined Message-ID: <20210904195643.GK12964@bill-the-cat> References: <20210830120102.GO858@bill-the-cat> <678a77d9-356a-e924-da8e-102fba938ee3@denx.de> <20210904141019.GC12964@bill-the-cat> <72c92d4d-f064-f7f3-dd4b-57cf994009db@denx.de> <20210904151714.GE12964@bill-the-cat> <20210904160901.GF12964@bill-the-cat> <2de2fee5-dcba-fc40-471e-3f4e1f1147bb@denx.de> <20210904170120.GH12964@bill-the-cat> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="wIc/V6YLA2QdyfT4" 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 --wIc/V6YLA2QdyfT4 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Sep 04, 2021 at 09:37:39PM +0200, Marek Vasut wrote: > On 9/4/21 7:01 PM, Tom Rini wrote: > > [trimming the CC list] > >=20 > > On Sat, Sep 04, 2021 at 06:49:03PM +0200, Marek Vasut wrote: > > > On 9/4/21 6:09 PM, Tom Rini wrote: > > > > On Sat, Sep 04, 2021 at 06:05:50PM +0200, Marek Vasut wrote: > > > > > On 9/4/21 5:17 PM, Tom Rini wrote: > > > > > > On Sat, Sep 04, 2021 at 05:15:45PM +0200, Marek Vasut wrote: > > > > > > > On 9/4/21 4:10 PM, Tom Rini wrote: > > > > > > > [...] > > > > > > >=20 > > > > > > > > > > > > At this point, I think you should rework things to = stop making > > > > > > > > > > > > CONFIG_LMB be optional, it should be a def_bool y. > > > > > > > > > > >=20 > > > > > > > > > > > I disagree, see above. > > > > > > > > > >=20 > > > > > > > > > > The only reason "tools-only_defconfig" builds a useless= u-boot binary > > > > > > > > > > today is in CI where it would be more work than it's wo= rth to make CI > > > > > > > > > > exclude that from the build list. But if you want to j= ust do that > > > > > > > > > > instead, I'll also accept adding -x tools-only to the a= zure/gitlab jobs > > > > > > > > > > that build all other architectures, as tools-only is te= sted in its own > > > > > > > > > > build job, for it's only valid build target. > > > > > > > > >=20 > > > > > > > > > The tools-only build is also used elsewhere, to build jus= t that, tools. > > > > > > > >=20 > > > > > > > > I've repeatedly explained myself and what I'm looking for i= n v2 of this > > > > > > > > series. I will summarize one last time. The "tools-only_d= efconfig" is > > > > > > > > for tools, only. Building anything other than the "tools-o= nly" target > > > > > > > > isn't useful. In U-Boot itself, LMB is required as that is= how we > > > > > > > > prevent a number of CVEs from being trivial to exploit. v2= of this > > > > > > > > series needs to drop patches 1 and 2 of v1 of this series. = It can > > > > > > > > further do any of: > > > > > > > > 1. Nothing else. > > > > > > > > 2. Add tools-only to the exclude list in the "build everyth= ing else" CI > > > > > > > > job. > > > > > > > > 3. Make CONFIG_LMB be def_bool y. > > > > > > >=20 > > > > > > > If tools-only is for tools, only, then why should it enable L= MB ? > > > > > > > The tools are userspace tools, they do not need LMB, and so L= MB can be > > > > > > > disabled. > > > > > > >=20 > > > > > > > This is the part which is unclear to me. > > > > > >=20 > > > > > > I don't know why it's unclear to you at this point, sorry. > > > > >=20 > > > > > Well why exactly does a userspace program require LMB enabled ? > > > > > What does LMB protect in there ? obviously not U-Boot. > > > >=20 > > > > I feel like you've lost the thread. > > >=20 > > > Can you please answer my questions above ? > >=20 > > I have. >=20 > This attitude is not helpful. Please answer my questions, if necessary > please reiterate, otherwise this discussion cannot be resolved and will o= nly > lead to frustration. One last time then. The only reason tools-only_defconfig is ever built for a target other than "tools-only" is because CI does not exclude it =66rom the world build stage. You can fix this by doing option #2 still quoted above. The only CONFIG options that are at all valid for "tools-only" and so the host tools related, are LOCALVERSION (which is why there's a tools-only defconfig at all) and now TOOLS_LIBCRYPTO. Nothing else at all should matter as the tools should always be the same. So your point about "what does userspace need LMB for" is irrelevant. The host tools should need NO option be enabled/disabled. Further, "disabling FOO breaks the build" means we need to investigate what the correct resolution is. In this case, LMB needs to be def_bool y. This is option #3 above. Why does u-boot-as-sandbox need LMB? Because that's how we ensure that the tests that check for overlap fail as expected. Finally, you can just drop the first two patches and call me too stubborn. This is option #1 above. --=20 Tom --wIc/V6YLA2QdyfT4 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQGzBAABCgAdFiEEGjx/cOCPqxcHgJu/FHw5/5Y0tywFAmEzz3gACgkQFHw5/5Y0 tyw+qwv/SFnJ8Tyj0YaeFiGmnc+oN39ez/PPeNi9oMJFt4cdtVbP6FF2+aHPjJrT mHQwQlUVI/jQcKj53Qc3Vv+vEQCTLq5oosoiBq7QHV6C2hVxNBg+Hq3pJasImz+k BaVF2iUZfI0SBeUZhwkLOvcP5OQZlNmhHqPHKsoXx0ROtm/Vogf8C8LIzxw4Vn+X 9j+n4ey5rb2R2ApUkR4HC4YglPmBY9iQ4t2DpVOUixfSQ6DaEmUn5YnOYkM72LBX 77gquXrhc8nzS5VLVUqXWwOXzdydube6WORh1oItnDubpe+USKU8mpXtJg9qTrkY eQWax+rCo3T7U5wI3g/SS5OD6MSAxeIzphMKCaY8Sv4nQ8qF21MsNd9wvjbKnvFI oW/S5XKcU7ssLecy2kn1F+vIY8QR8blfcte2gEfxWmNim0yw1Ajbr1OSXpX7cuAr u9YVxoBYOboXmLxGWT20HggbVgFT38Q5HrmoQ758TRpQVi4NeaD2u1Kfbv4Q7iIG UYMQlGbr =w/Ve -----END PGP SIGNATURE----- --wIc/V6YLA2QdyfT4--