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 361AFC433EF for ; Wed, 5 Jan 2022 16:55:18 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 325B080FDA; Wed, 5 Jan 2022 17:55:16 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org 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=chromium.org header.i=@chromium.org header.b="OvuMXxEz"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 79D7C83754; Wed, 5 Jan 2022 17:55:13 +0100 (CET) Received: from mail-ua1-x92a.google.com (mail-ua1-x92a.google.com [IPv6:2607:f8b0:4864:20::92a]) (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 8ABCC8083E for ; Wed, 5 Jan 2022 17:55:09 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@google.com Received: by mail-ua1-x92a.google.com with SMTP id y4so13304957uad.1 for ; Wed, 05 Jan 2022 08:55:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Bf4PF0rozJ47Yi0VWDiGoDL2rcsYzeH6+VmmucUXp88=; b=OvuMXxEzOzztq3iwJucQA4ZgLf496nG9pag9ajlJ1MK4IQl6oaQhLC8ivBlGuAjqYg HFjqSCtuWvT72/EU+CU3aS2M5p5bj0XmuQhKj9sNyQKG+qsF1tINbE7VXo7ipKCzrvNm WXF3FcyhVMoqs6PE7haV+rrYySSwS4tfdJXGM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Bf4PF0rozJ47Yi0VWDiGoDL2rcsYzeH6+VmmucUXp88=; b=hU398aKv69PZV+qsgkCl/kS2LCVsg9HFkvBQcSXcEdFP1z4njISrqshuXHjwKJ9wr1 XF/jtCAVWhe1ccJQpNlmr+RBJzITpJiaRgXEuILFsZYCwGYqP1tnZw8fpjKk9kUFXX0Q 6Q2pGpPY4Cl43lK2Q2Od/Ht6SR0UQ6XvKjSuXh2OVN77A6ji6YeWIyWKiLlczKxzAwcs jwQEhdVuFZTn+2OSqWYCdy0ZZXrICjEAb2O+VGAsaa2jkRZTAbzdjPyC4mWCsAE15Olq 5JEd8ZjQJlT5eiIBNmFhkrGrnF6X09mkXFoPKKQI80OJSYQbnW/+kLyeNUUAce8qx2DE 2hjA== X-Gm-Message-State: AOAM530OUalDzGJsVyeNIEqsifpWDt0R2SbR6BGupMOJl6+QC5MJEacJ nmNir9hZ6Owl6BLomF3IseONdnX7mrsXNDgQuTwqWw== X-Google-Smtp-Source: ABdhPJxpWlntWV/CmQhJ3OPcnjmx1XhNzRr10LGcyMrKJdGXn8flo6qgjLqoHLV9UMlt5q9A5QgUEP7YmpZxxP6JWJk= X-Received: by 2002:a67:e897:: with SMTP id x23mr16908454vsn.19.1641401707936; Wed, 05 Jan 2022 08:55:07 -0800 (PST) MIME-Version: 1.0 References: <20220105125816.197045-1-heiko.thiery@gmail.com> In-Reply-To: From: Simon Glass Date: Wed, 5 Jan 2022 09:54:55 -0700 Message-ID: Subject: Re: [RFC Patch v3] binman: add support for creating dummy files for external blobs To: Heiko Thiery Cc: U-Boot Mailing List , Stefano Babic , Fabio Estevam , Michael Walle , Tom Rini , Wolfgang Denk Content-Type: text/plain; charset="UTF-8" X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.38 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 Hi Heiko, On Wed, 5 Jan 2022 at 09:06, Simon Glass wrote: > > Hi Heiko, > > On Wed, 5 Jan 2022 at 05:58, Heiko Thiery wrote: > > > > While converting to binman for an imx8mq board, it has been found that > > building in the u-boot CI fails. This is because an imx8mq requires an > > external binary (signed_hdmi_imx8m.bin). If this file cannot be found > > mkimage fails. > > To be able to build this board in the u-boot CI a binman option > > (--fake-ext-blobs) is introduced that can be switched on via the u-boot > > makefile option BINMAN_FAKE_EXT_BLOBS. With that the needed dummy files are > > created. > > > > Signed-off-by: Heiko Thiery > > --- > > v3: > > - add CheckFakedBlobs() and print a list of faked files at the end > > - add unittest > > > > v2: > > - pass allow_fake_blobs to ProcessImage() > > - set AllowAllowFakeBlob() to images/entries > > - create fake blob in Entry_blot.ObtainContents() when file is missing and > > creation is allowed > > > > still missing: > > - unittest > > - option to set BINMAN_FAKE_EXT_BLOBS in Makefile via environment > > variable. With that we could simply set this env variable in the CI > > (gitlab-ci.yml) with adding support to buildman. > > > > Makefile | 1 + > > tools/binman/cmdline.py | 2 ++ > > tools/binman/control.py | 26 +++++++++++++++++++------- > > tools/binman/entry.py | 23 +++++++++++++++++++++++ > > tools/binman/etype/blob.py | 18 ++++++++++++++++++ > > tools/binman/etype/blob_ext.py | 8 ++++++++ > > tools/binman/etype/mkimage.py | 20 ++++++++++++++++++++ > > tools/binman/etype/section.py | 20 ++++++++++++++++++++ > > tools/binman/ftest.py | 13 ++++++++++++- > > tools/binman/test/203_fake_blob.dts | 14 ++++++++++++++ > > 10 files changed, 137 insertions(+), 8 deletions(-) > > create mode 100644 tools/binman/test/203_fake_blob.dts > > Please check that you keep to 80cols, except where it would split a string. > > This is missing a few holes in test coverage. Did you try 'binman test -T' ? > > If you are stuck I could fiddle with it a bit. BTW if you need the external tools you might try u-boot-dm/bin-working which has a command that might fetch them: binman tool --fetch missing It is WIP at present, so has an old version of your patch in there. Regards, Simon