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 BD0E0C19F2A for ; Thu, 11 Aug 2022 16:28:05 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id D8F2A84A19; Thu, 11 Aug 2022 18:28:03 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=gateworks.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=gateworks-com.20210112.gappssmtp.com header.i=@gateworks-com.20210112.gappssmtp.com header.b="pCOHP1Xx"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id D02E684A1A; Thu, 11 Aug 2022 18:28:01 +0200 (CEST) Received: from mail-pl1-x62a.google.com (mail-pl1-x62a.google.com [IPv6:2607:f8b0:4864:20::62a]) (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 865E38492A for ; Thu, 11 Aug 2022 18:27:58 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=gateworks.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=tharvey@gateworks.com Received: by mail-pl1-x62a.google.com with SMTP id 17so17333158plj.10 for ; Thu, 11 Aug 2022 09:27:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gateworks-com.20210112.gappssmtp.com; s=20210112; h=to:subject:message-id:date:from:mime-version:from:to:cc; bh=D8G+lewxDkVfgLUAuxpbofx83PfRPWN1Yjiz39pj7QU=; b=pCOHP1XxzIHG5HRt0S4fgeflBkCfzKOfFFao0Tyl3ziF0A6CkxYDn5WF6rsY/HI6/y WUi/54brOU0o5DTwj6KW9Mr+2he+fob7J9rv76VR9P7uY6alhiVLSjfgYfHRFnxRtGni mXiWcXQ0au4ouByLm0ERk3R01GsCU9/FigZWVw64bwkm5ZB/6ADCX0FgqIGVMxUmsbQA EeHkRg51ffsjv75bGCvO3UGtddjIMyHYSay9NgRKa+R55yF+OyDJZThXjTofoU1fYS0F XkHjbRF02ReyDpPeZnGJfUC1n8+ijPDoJFQF5N+HXuGJnRoqbiD5BVjmw4YUL+6U+A9p ZYmA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=to:subject:message-id:date:from:mime-version:x-gm-message-state :from:to:cc; bh=D8G+lewxDkVfgLUAuxpbofx83PfRPWN1Yjiz39pj7QU=; b=CfHsyt0/b0Ik3MhK08kXocqqRIpLc25pu6MmKgm0ueHisXOdzElPV6ULS7YGfX9ZZc 8Z5xIzwL2Ms3qHzPVXiav3jC3J9DYI7IXQhmRetNduxIu60M1xn1GvA5wh3mWsmwwWxi 7k6rLJfTkBC0Wuq/6D9sb10dSKspZtugC24X9t3FAtDdqfrkuudzDPIs8jep+Ua0kbz3 +rGZ1+66UhH+Uol+Jh4nMg5JV5WhqZ96Es1WWjzY1nHv+yWuqkcFpoitalRnNFaWmAfq 59bdpv73gn3Kf7xV4dmae/t0BEIFEi1RlGL1cgJDiH8bOxa4xXTY6t+PjsbfHqjVw4uR yOow== X-Gm-Message-State: ACgBeo1RDRZTeVHLqspCCkbnp6h5+jK3TPoiSffYNIUoNGa/tsfAN5vt 74BH3JNMI/xy6M4d/7ld4+3ZyMGDSc7wqPLNRAl6p20uc9VuvA== X-Google-Smtp-Source: AA6agR7Xeg9JQJBLaw+S1RjbqIAgB/UyUdibNadcKkcagdafkOhwsKYEUl3hNy6IszVRSQm16UCgC/VG7wGYm0c/Ft4= X-Received: by 2002:a17:90b:f8c:b0:1f2:ea98:a273 with SMTP id ft12-20020a17090b0f8c00b001f2ea98a273mr9713540pjb.155.1660235275869; Thu, 11 Aug 2022 09:27:55 -0700 (PDT) MIME-Version: 1.0 From: Tim Harvey Date: Thu, 11 Aug 2022 09:27:44 -0700 Message-ID: Subject: binman warning/failure when blobs are missing To: u-boot , Simon Glass Content-Type: text/plain; charset="UTF-8" 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 Greetings, After a couple of hours troubleshooting a bad boot image today I realized the issue was that I had some 0 byte files for the lpddr4 training blobs that are part of the imx8mp binman created image. Digging in I found that if a blob referenced in the binman node is missing a warning will be output but the missing files will be 'created' as 0 byte files such that the next time you build you will get no warning (but will have a non-working image). Additionally the error does not cause a non-zero exit code. I'm not that fluent in python these days, and don't have the time for a while to try and fix this but I figured I would at least send this email in case someone else does. Example: # rm *lpddr4*.bin # make sure lpddr4*.bin files referenced in binman nodes are missing # make distclean imx8mp_venice_defconfig flash.bin && echo "build ok" ... BINMAN flash.bin Image 'main-section' is missing external blobs and is non-functional: ddr-1d-ime m-fw ddr-1d-dmem-fw ddr-2d-imem-fw ddr-2d-dmem-fw Image 'main-section' has faked external blobs and is non-functional: lpddr4_pmu_ train_1d_imem_202006.bin lpddr4_pmu_train_1d_dmem_202006.bin lpddr4_pmu_train_2d _imem_202006.bin lpddr4_pmu_train_2d_dmem_202006.bin Some images are invalid ^^^ excellent warning build ok ^^^ not so great that there is a successful exit code # make flash.bin && echo "build ok" ... BINMAN flash.bin build ok ^^^ absolutely horrible that 0 byte files were created and thus everything looks good this time around! # stat -c "%s %n" lpddr4*.bin 0 lpddr4_pmu_train_1d_dmem_202006.bin 0 lpddr4_pmu_train_1d_imem_202006.bin 0 lpddr4_pmu_train_2d_dmem_202006.bin 0 lpddr4_pmu_train_2d_imem_202006.bin Best Regards, Tim