From patchwork Sun Feb 5 20:21:21 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jonas Karlman X-Patchwork-Id: 1737765 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=fail reason="key not found in DNS" header.d=kwiboo.se header.i=@kwiboo.se header.a=rsa-sha256 header.s=s1 header.b=Pack+iJV; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4P914z3gYkz23j7 for ; Mon, 6 Feb 2023 07:21:37 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 124C685704; Sun, 5 Feb 2023 21:21:28 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=reject dis=none) header.from=kwiboo.se 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=kwiboo.se header.i=@kwiboo.se header.b="Pack+iJV"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 6A93285651; Sun, 5 Feb 2023 21:21:25 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE, SPF_PASS,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.2 Received: from xvfrqvdb.outbound-mail.sendgrid.net (xvfrqvdb.outbound-mail.sendgrid.net [168.245.72.219]) (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 716C385347 for ; Sun, 5 Feb 2023 21:21:22 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=reject dis=none) header.from=kwiboo.se Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=bounces+31435339-7456-u-boot=lists.denx.de@em2124.kwiboo.se DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kwiboo.se; h=from:subject:mime-version:to:cc:content-transfer-encoding: content-type:cc:content-type:from:subject:to; s=s1; bh=ll57dzMjgtUPJRXQdiNgaVAGRBTAl+5fnO6wD+rZEm4=; b=Pack+iJVDTFyzvMmF3ki/nlIh/MoOMerIAcny3i5767X61425ihT5QDRk9emiLr9mItB Xw4AUc8SOvfWMOsG53XwzXQPDB+6dCwUGcXq8+0Weydlf22MceJxHvB1r7eoKgOCAWHisd y7lSPNTdu5OvWcsVetd/Tf8zShfu9hqPgwQBH6VzK8EWsoSD+LskTC5wAvksZtWzLf+nzB fTqLnKlPC/2Bs5OA55thNGTWxJJs/duQqLe2OJVE0AF6WNZSgWwgBnStZ+d24YDR9FGnQ3 oJde0XPpNVK4uQ2e5ycRO0Gp/+HodDgkIiGDs5KMG8p4lp21W8US0zZlXo/caU4Q== Received: by filterdrecv-6b9548745c-b6qpv with SMTP id filterdrecv-6b9548745c-b6qpv-1-63E00FC0-17 2023-02-05 20:21:20.829206987 +0000 UTC m=+6901984.314832946 Received: from bionic.localdomain (unknown) by geopod-ismtpd-5-2 (SG) with ESMTP id uuDSOaduS3qit8qeDUwF1w Sun, 05 Feb 2023 20:21:20.327 +0000 (UTC) From: Jonas Karlman Subject: [PATCH 0/3] rockchip: Use external TPL binary to create a working firmware image Date: Sun, 05 Feb 2023 20:21:21 +0000 (UTC) Message-Id: <20230205202116.2891673-1-jonas@kwiboo.se> X-Mailer: git-send-email 2.39.1 MIME-Version: 1.0 X-SG-EID: TdbjyGynYnRZWhH+7lKUQJL+ZxmxpowvO2O9SQF5CwCVrYgcwUXgU5DKUU3QxAfZekEeQsTe+RrMu3cja6a0h2WasHP+5m8tEw/LB/C68xbCJVQCsmHjyxHIPrQg3Qd5PiskUCT9Zo3MSW1JIrx5t4aGByk4wHA53s5XOWPct0UirAzzXLyMQ1g96MfCbKOsDFewoDcKTuMnhAZHKO9CXv0btB5ts53bTV6D+fjDPwGH77gxBjZT4CbzzB6FEK2a To: Simon Glass , Philipp Tomsich , Kever Yang , Joseph Chen , Alper Nebi Yasak Cc: Quentin Schulz , Jagan Teki , Heinrich Schuchardt , u-boot@lists.denx.de, Jonas Karlman X-Entity-ID: P7KYpSJvGCELWjBME/J5tg== 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 Rockchip SoCs typically use U-Boot TPL to initialize DRAM, then jumps back to boot-rom to load the next stage of the boot flow, U-Boot SPL. For RK356x there is currently no support to initialize DRAM using U-Boot TPL and instead an external TPL binary must be used to generate a working u-boot-rockchip.bin image. This adds a new generic external-tpl entry to binman and make use of this new entry in rockchip-u-boot.dtsi. Please note that the allow-missing flag and the added missing-msg entry does not work as expected becuase the wrapping mkimage entry used requires that the files to all child entries exists. Instead without a provided EXTERNAL_TPL the build fails with: ValueError: Filename 'ddr.bin' not found in input path (...) originating from Entry_mkimage.ObtainContents: fnames.append(tools.get_input_filename(entry.GetDefaultFilename())) Not sure how to properly add support for allow-missing flag to mkimage entry, possible something for another series? Regards, Jonas Jonas Karlman (3): binman: Add support for an external-tpl entry rockchip: Require an external TPL binary when TPL is missing Revert "board: rockchip: Fix binman_init failure on EVB-RK3568" Makefile | 1 + arch/arm/dts/rockchip-u-boot.dtsi | 16 ++++++++++++---- configs/evb-rk3568_defconfig | 1 - tools/binman/entries.rst | 12 ++++++++++++ tools/binman/etype/external_tpl.py | 18 ++++++++++++++++++ tools/binman/ftest.py | 7 +++++++ tools/binman/missing-blob-help | 5 +++++ tools/binman/test/277_external_tpl.dts | 16 ++++++++++++++++ 8 files changed, 71 insertions(+), 5 deletions(-) create mode 100644 tools/binman/etype/external_tpl.py create mode 100644 tools/binman/test/277_external_tpl.dts