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 AB56EC2BA4C for ; Wed, 26 Jan 2022 08:54:58 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 9F19D837B6; Wed, 26 Jan 2022 09:54:56 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.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=gmail.com header.i=@gmail.com header.b="lXInVSPW"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 2821383845; Wed, 26 Jan 2022 09:54:55 +0100 (CET) Received: from mail-ed1-x535.google.com (mail-ed1-x535.google.com [IPv6:2a00:1450:4864:20::535]) (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 9D7F183680 for ; Wed, 26 Jan 2022 09:54:52 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=oliver.graute@gmail.com Received: by mail-ed1-x535.google.com with SMTP id w14so14972756edd.10 for ; Wed, 26 Jan 2022 00:54:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:date:to:cc:subject:message-id:mail-followup-to:references :mime-version:content-disposition:in-reply-to:user-agent; bh=Z1LTSKt31zjdXK2/Ggil3BTDpU3E9NXiD0iOzHbA504=; b=lXInVSPWCUhVcuhfMjxitE27iwwlZ25tihuSEUBFTb9C8Uxg2E3LW1wGjBT9+ZzHXY lAx4uI45m8XQaZdSxFKAaSrK6JiTZnMHChL80p/CMBhSejkux9rsUIHkQaXPEhOi2M+J CqK3PPdF7PWkZyJyKmqw69t0ysfFzx05AhS+QUzds2Y3p378ECXKyXrKeXZykkRxsS0a HReyDj9kPQn5/o/l+cEJ6DH7XZZ40e8hC8g77Ui8yxlm/aWBrxeYX8dRtrqHVHnSV+Uq SR6yygDOOgLx6+JcRe6pG1/EApLDNUym/W5JbQetGknziq9G0hIpoKzdeY7nupGgeWvw t71A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:date:to:cc:subject:message-id :mail-followup-to:references:mime-version:content-disposition :in-reply-to:user-agent; bh=Z1LTSKt31zjdXK2/Ggil3BTDpU3E9NXiD0iOzHbA504=; b=QYPopN1U2Zqg4T9xHu0RSjcuFXUOAqo+PjkBnd0sa7JQFEk1g4wQV/QxiKf9FaNucF gF7hZxKQNwA6Lyg4rFvh7lWATbmJCbry96ils69T/+KnhSozo4rt6f40ZXfAMk7UUIcp oAlysTbkCOnSpVGhXIf7okmzTbIWR58fb1arAgjEo1ajehou+0Cd3mGehIUXcGHeusZd M/eYYAqIBUTKooawD8CSEL9Z1u0akJe6XhljTRNX5uJ1JbNJ8E3ygaK0R3sJE4xt9V60 uaumLEJeqySvrAGdokhGwmFWPFLi6nErGbFHoRoq2BwnKdbPuNcT8e38Clm8vNFNlklr FWhQ== X-Gm-Message-State: AOAM531HsknVn8SVxTb0IyfFeDB86dQ/dREkpROXOrQipLDE1C9m7PuY HPlqzuHUDB+hRp2WYi6wQJ8= X-Google-Smtp-Source: ABdhPJyH34lo9y9PRHsA1i52VO32urMGeNua5KhynURzRFcWm+AgfwCMSNQK1xQABqrP8fcHuSYkXw== X-Received: by 2002:a05:6402:26c4:: with SMTP id x4mr20183410edd.22.1643187292054; Wed, 26 Jan 2022 00:54:52 -0800 (PST) Received: from localhost (dslb-002-207-138-002.002.207.pools.vodafone-ip.de. [2.207.138.2]) by smtp.gmail.com with ESMTPSA id my25sm7202912ejc.100.2022.01.26.00.54.50 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 26 Jan 2022 00:54:51 -0800 (PST) From: Oliver Graute X-Google-Original-From: Oliver Graute Date: Wed, 26 Jan 2022 09:18:13 +0100 To: Stefano Babic , Fabio Estevam , "NXP i.MX U-Boot Team" Cc: aford173@gmail.com, peng.fan@nxp.com, marcel.ziswiler@toradex.com, tharvey@gateworks.com, andrey.zhizhikin@leica-geosystems.com, u-boot@lists.denx.de Subject: Re: [RFC] imx: imx8qm-rom7720: switch to binman Message-ID: <20220126081813.GD10212@optiplex> Mail-Followup-To: Stefano Babic , Fabio Estevam , "NXP i.MX U-Boot Team" , aford173@gmail.com, peng.fan@nxp.com, marcel.ziswiler@toradex.com, tharvey@gateworks.com, andrey.zhizhikin@leica-geosystems.com, u-boot@lists.denx.de References: <20220110103033.29958-1-oliver.graute@kococonnector.com> <20220112091325.12341-1-oliver.graute@kococonnector.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220112091325.12341-1-oliver.graute@kococonnector.com> User-Agent: Mutt/1.9.4 (2018-02-28) 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.5 at phobos.denx.de X-Virus-Status: Clean On 12/01/22, Oliver Graute wrote: > Switch to use binman to pack images > > Signed-off-by: Oliver Graute > --- > > A flash.bin is now generated by binman but its now bigger then with > mkimage_fit_atf.sh 800K vs. 1.1M and is currently NOT booting. > So something is still messed up. > > arch/arm/dts/imx8qm-rom7720-a1.dts | 1 + > arch/arm/dts/imx8qm-u-boot.dtsi | 136 ++++++++++++++++++ > arch/arm/mach-imx/imx8/Kconfig | 1 + > .../advantech/imx8qm_rom7720_a1/imximage.cfg | 16 +-- > configs/imx8qm_rom7720_a1_4G_defconfig | 2 +- > doc/board/advantech/imx8qm-rom7720-a1.rst | 3 +- > 6 files changed, 142 insertions(+), 17 deletions(-) > create mode 100644 arch/arm/dts/imx8qm-u-boot.dtsi > > diff --git a/arch/arm/dts/imx8qm-rom7720-a1.dts b/arch/arm/dts/imx8qm-rom7720-a1.dts > index d1f2fff869..332d441c6d 100644 > --- a/arch/arm/dts/imx8qm-rom7720-a1.dts > +++ b/arch/arm/dts/imx8qm-rom7720-a1.dts > @@ -10,6 +10,7 @@ > /memreserve/ 0x80000000 0x00020000; > > #include "fsl-imx8qm.dtsi" > +#include "imx8qm-u-boot.dtsi" > > / { > model = "Advantech iMX8QM Qseven series"; > diff --git a/arch/arm/dts/imx8qm-u-boot.dtsi b/arch/arm/dts/imx8qm-u-boot.dtsi > new file mode 100644 > index 0000000000..98379516cc > --- /dev/null > +++ b/arch/arm/dts/imx8qm-u-boot.dtsi > @@ -0,0 +1,136 @@ > +// SPDX-License-Identifier: GPL-2.0+ > +/* > + * Copyright 2021 NXP > + */ > + > +/ { > + binman: binman { > + multiple-images; > + }; > +}; > + > +&binman { > + u-boot { > + align-size = <4>; > + align = <4>; > + filename = "u-boot.bin"; > + pad-byte = <0xff>; > + > + u-boot-spl { > + align-end = <4>; > + }; > + }; > + > + spl { > + filename = "spl.bin"; > + mkimage { > + args = "-n spl/u-boot-spl.cfgout -T imx8mimage -e 0x100000"; this refers to the wrong container format for imx8qm! So replacing s/imx8mimage/imx8image/ does help to get a working image. > > #define __ASSEMBLY__ > > -/* Boot from SD, sector size 0x400 */ > -BOOT_FROM SD 0x400 > -/* SoC type IMX8QM */ > -SOC_TYPE IMX8QM > -/* Append seco container image */ > -APPEND mx8qm-ahab-container.img > -/* Create the 2nd container */ > -CONTAINER > -/* Add scfw image with exec attribute */ > -IMAGE SCU mx8qm-val-scfw-tcm.bin > -/* Add ATF image with exec attribute */ > -IMAGE A35 bl31.bin 0x80000000 > -/* Add U-Boot image with load attribute */ > -DATA A35 u-boot-dtb.bin 0x80020000 I need to keep this here to. > +BOOT_FROM sd > +LOADER u-boot-dtb.bin 0x10000 with this changes the resulting flash.bin is as big as before and its booting flawlessly. I 'll ppst later a patch v1 for this. Best regards, Oliver