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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 872D0C433EF for ; Wed, 10 Nov 2021 08:28:26 +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 B27D7610A3 for ; Wed, 10 Nov 2021 08:28:24 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org B27D7610A3 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=walle.cc 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 DCD36839A8; Wed, 10 Nov 2021 09:28:22 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=walle.cc 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; secure) header.d=walle.cc header.i=@walle.cc header.b="a8UeAvEU"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 9C1F38398A; Wed, 10 Nov 2021 09:28:20 +0100 (CET) Received: from ssl.serverraum.org (ssl.serverraum.org [IPv6:2a01:4f8:151:8464::1:2]) (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 1A2DA839B0 for ; Wed, 10 Nov 2021 09:28:17 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=walle.cc Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=michael@walle.cc Received: from ssl.serverraum.org (web.serverraum.org [172.16.0.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ssl.serverraum.org (Postfix) with ESMTPSA id 4423522221; Wed, 10 Nov 2021 09:28:15 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=walle.cc; s=mail2016061301; t=1636532895; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=1k2yLvXapmdnU2hX3OnrlZqNXSWG5+VVyoQ8cXqRBB0=; b=a8UeAvEUd5mqx1PVi+Cz7gDiAV7cDeeF5WHuV+fb+V0iVGDpBRNlx/esHrUwIkFe8aIK/I G0aaOJPRqCoOSj7Dk+scuUpSLR2fucBjrxOzELDo1cczolNN5yZwotyuzGfIz5KXxeP2Iq nPM6Rf3YNYUwSH1OmMJDxs8O0h7W6Xs= MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Wed, 10 Nov 2021 09:28:14 +0100 From: Michael Walle To: Tom Rini Cc: Rasmus Villemoes , Heiko Thiery , Wolfgang Denk , u-boot@lists.denx.de, Stefano Babic , Fabio Estevam , Simon Glass Subject: Re: [RFC 0/2] Do not stop with an error when mkimage fails In-Reply-To: <20211110013720.GD24579@bill-the-cat> References: <20211104185231.2927-1-heiko.thiery@gmail.com> <729199.1636053161@gemini.denx.de> <963318.1636296486@gemini.denx.de> <20211109194224.GB24579@bill-the-cat> <11cebfaf-8fc4-f80d-ed0f-bd8810a43514@prevas.dk> <3253160d-b2e1-2101-5cd4-b8549b5acbae@prevas.dk> <20211110013720.GD24579@bill-the-cat> User-Agent: Roundcube Webmail/1.4.11 Message-ID: <1905d9358be72f2731f18c18642da4a4@walle.cc> X-Sender: michael@walle.cc 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 Am 2021-11-10 02:37, schrieb Tom Rini: > On Wed, Nov 10, 2021 at 01:26:12AM +0100, Rasmus Villemoes wrote: >> On 10/11/2021 01.18, Rasmus Villemoes wrote: >> > On 09/11/2021 20.42, Tom Rini wrote: >> >> On Tue, Nov 09, 2021 at 08:21:07PM +0100, Heiko Thiery wrote: >> >>> Hi Wolfgang, >> >>> >> > >> >>> I know this is not a perfect solution but I don't know how to get my >> >>> board merged without doing this kind of workaround for the U-Boot CI. >> >> >> >> Unfortunately in these days of needing multiple inputs to create a >> >> functional image and also needing to have CI be able to be at all >> >> useful, what we do in many many many cases is yell loudly to the user >> >> that the resulting file here will NOT work and why. So yes, some "yell >> >> it won't work but not return non-zero exit status" is the norm. >> >> >> >> I would be very much open however to some way to handle this >> >> differently. Some environment variable our tools check for and then >> >> yell-but-succeed? Some other idea? I'm just thinking out loud here. >> > >> > Yes, I believe the build system must be taught some env var (or other >> > means) for opting in to this behavior. >> >> Oh, and it should of course only paper over missing binary blobs, not >> arbitrary errors from mkimage or other tools. The easiest way to do >> that >> is probably to create some dummy blob(s) [only when >> CREATE_BROKEN_IMAGES >> is set of course] before calling the tool that will consume the blobs. > > Some patches along those lines would be most welcome :) If I understand Simon correctly, then it is possible to fill in missing blobs later with binman (or an fit image in general?). Which is quite useful in a build system, because you don't have a chain of dependent packages, but you can assemble all the binaries in a final step. But this also means, that "missing binary blobs" are not an error but may even be expected. Unfortunately, this all falls apart if the binary is inside an image produced by mkimage (like the hdmi phy firmware in for the imx8). Though the finaly image is generated by binman, you cannot replace/insert the hdmi phy firmware later on [except you'd unpack the imx image, replace the firmware, pack it again and then replace it again in the outer image]. IMHO quite a drawback if we're saying binman isn't replacing mkimage. -michael