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 27830C00140 for ; Mon, 8 Aug 2022 15:48:38 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id B4A1584068; Mon, 8 Aug 2022 17:48:35 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=tinet.cat Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 153A68456C; Mon, 8 Aug 2022 17:48:34 +0200 (CEST) Received: from mx1.tinet.cat (mx1.dipta.cat [195.76.233.59]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id B808984068 for ; Mon, 8 Aug 2022 17:48:31 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=tinet.cat Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=xdrudis@tinet.cat X-ASG-Debug-ID: 1659973710-12aaf205fa416fa0001-4l7tJC Received: from smtp01.tinet.cat (smtp.tinet.cat [195.77.216.131]) by mx1.tinet.cat with ESMTP id Ez3Ide0cuwOzIwZx; Mon, 08 Aug 2022 17:48:30 +0200 (CEST) X-Barracuda-Envelope-From: xdrudis@tinet.cat X-Barracuda-Effective-Source-IP: smtp.tinet.cat[195.77.216.131] X-Barracuda-Apparent-Source-IP: 195.77.216.131 Received: from begut (99.red-79-152-185.dynamicip.rima-tde.net [79.152.185.99]) by smtp01.tinet.cat (Postfix) with ESMTPSA id 45BCD605D0A1; Mon, 8 Aug 2022 17:48:30 +0200 (CEST) Date: Mon, 8 Aug 2022 17:48:29 +0200 From: Xavier Drudis Ferran To: Simon Glass Cc: U-Boot Mailing List , Xavier Drudis Ferran , Alper Nebi Yasak Subject: Re: [SPAM] [PATCH 2/2] binman: Add more documentation about binman usage Message-ID: X-ASG-Orig-Subj: Re: [SPAM] [PATCH 2/2] binman: Add more documentation about binman usage References: <20220807223326.1460843-1-sjg@chromium.org> <20220807223326.1460843-2-sjg@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20220807223326.1460843-2-sjg@chromium.org> X-Barracuda-Connect: smtp.tinet.cat[195.77.216.131] X-Barracuda-Start-Time: 1659973710 X-Barracuda-URL: https://webmail.tinet.cat:443/cgi-mod/mark.cgi X-Barracuda-Scan-Msg-Size: 2572 X-Barracuda-BRTS-Status: 1 X-Barracuda-Bayes: SPAM GLOBAL 0.9869 1.0000 4.1909 X-Barracuda-Spam-Score: 4.19 X-Barracuda-Spam-Status: No, SCORE=4.19 using global scores of TAG_LEVEL=1000.0 QUARANTINE_LEVEL=6.0 KILL_LEVEL=8.0 tests= X-Barracuda-Spam-Report: Code version 3.2, rules version 3.2.3.99939 Rule breakdown below pts rule name description ---- ---------------------- -------------------------------------------------- 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 El Sun, Aug 07, 2022 at 04:33:26PM -0600, Simon Glass deia: > This is an attempt to answer the comments provided by Xavier [1]. > Thank you. Sorry if I point out silly things too. No agony intended. > > +Note that binman can itself can create a FIT. This helps to move mkimage one "can" too much > +invocations out of the Makefile and into binman image descriptions. It also > +helps by removing the need for ad-hoc tools like `make_fit_atf.py`. > + > Maybe in future tense? We're not there yet?, because of tee.bin, see Jerome's message. Or is tee.bin not officialy supported yet in U-Boot? > +How do you know how to incorporate ATF? It is handled by the atf-bl31 entry type > +(etype). An etype is an implementation of reading a binary into binman, in this > +case the `bl31.bin` file. When you build U-Boot but do not set the BL31 > +environment variable, binman provides a help message, which comes from > +`missing-blob-help`:: > + > + See the documentation for your board. You may need to build ARM Trusted > + Firmware and build with BL31=/path/to/bl31.bin > + > +The mechanism by which binman is advised of this is also in the Makefile. See > +the `-a atf-bl31-path=${BL31}` piece in `cmd_binman`. This tells binman to > +set the EntryArg `atf-bl31-path` to the value of the `BL31` environment > +variable. Within binman, this EntryArg is picked up by the `Entry_atf_bl31` > +etype. An EntryArg is simply an argument to the entry. The `atf-bl31-path` > +name is documented in :ref:`etype_atf_bl31`. > + Still confused. Shouldn't you mention split-elf ? The way I use it bl31.elf is not simply copied into an image (atf_bl31.py is just a Entry_blob_named_by_arg). It is sliced in pieces and put into u-boot.itb. Each piece carries a little metadada like the load address, extracted from the elf by make_fit_atf.py or binman with split-elf. The problem is binman cannot incorporate an image it produced as a binary into another, so we must still use make_fit_atf.py. But then binman does not use atf-bl31, it simply includes a blob with filename="u-boot.itb". Maybe it's not the best way to do it and people should just add a atf-bl31 {} section in their binman image and it somehow works ? Because that's what I would assume from your text. Or maybe you're talking of other boards, but then try not to write it as this is the method one uses always when one has atf (TF-A)? Anyway, thank you for writing it. The docs help understand many of the issues and are a good improvement.