From mboxrd@z Thu Jan 1 00:00:00 1970 Delivery-date: Fri, 09 Jun 2023 15:29:28 +0200 Received: from metis.ext.pengutronix.de ([2001:67c:670:201:290:27ff:fe1d:cc33]) by lore.white.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1q7cBG-00HFXr-48 for lore@lore.pengutronix.de; Fri, 09 Jun 2023 15:29:28 +0200 Received: from localhost ([127.0.0.1] helo=metis.ext.pengutronix.de) by metis.ext.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1q7cBD-0007xt-9h; Fri, 09 Jun 2023 15:29:27 +0200 Received: from ptz.office.stw.pengutronix.de ([2a0a:edc0:0:900:1d::77] helo=[127.0.0.1]) by metis.ext.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1q7cB1-0007xb-IX; Fri, 09 Jun 2023 15:29:15 +0200 Message-ID: Date: Fri, 9 Jun 2023 15:29:15 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.10.1 Content-Language: en-US To: Johannes Zink , distrokit@pengutronix.de References: <20230606-default_enable_fastboot_rock3a-v2-0-92606c4de9a9@pengutronix.de> From: Ahmad Fatoum In-Reply-To: <20230606-default_enable_fastboot_rock3a-v2-0-92606c4de9a9@pengutronix.de> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Subject: Re: [DistroKit] [PATCH v2 0/4] enable uploading kernel, dtb and initramfs over fastboot and boot it on Rock3A X-BeenThere: distrokit@pengutronix.de X-Mailman-Version: 2.1.29 Precedence: list List-Id: DistroKit Mailinglist List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: patchwork-jzi@pengutronix.de Sender: "DistroKit" X-SA-Exim-Connect-IP: 127.0.0.1 X-SA-Exim-Mail-From: distrokit-bounces@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false On 09.06.23 12:28, Johannes Zink wrote: > This series enables building Android sparse images of kernel, dtb and > initramfs for the Radxa Rock3A, enables mounting corresponding ram-files > as fastboot partitions in the barebox fastboot gadget, and adds support > for booting the image uploaded via fastboot. > > This can be useful in situations, where booting a Linux system is > required on such target without touching the nonvolatile storage, e.g. > for debugging purposes. > > For uploading kernel, dtb and initramfs use > > fastboot flash ram-kernel platform-v8a/images/linuximage -S 1 > fastboot flash ram-oftree platform-v8a/images/rk3568-rock-3a.dtb -S 1 > fastboot flash ram-initramfs platform-v8a/images/initramfs-sparse.img -S 1 Did you find out why -S 1 is needed instead of relying on automatic sparsing? > then for booting either use the barebox command > > boot ram-fastboot > > or pass the bootcommand over fastboot from the host via > > fastboot oem exec boot ram-fastboot > > Best regards > Johannes > > To: distrokit@pengutronix.de > Cc: patchwork-jzi@pengutronix.de > > Signed-off-by: Johannes Zink > --- > Changes in v2: > - worked in feedback from Ahmad, Jan and Robert (off-list). Thanks for > your review and feedback! > - only support zstd compressed initramfs, drop support for gzip (image > generation and kernel config) > - drop generation of android-sparse images. Use -S 1 parameter on > fastboot command instead to avoid cut-off issues > - export mmc{0,1,2} as optional partitions with generic names now, > add init script to detect these partitions on boot > - rename fastboot partitions {kernel,initramfs,oftree} to > ram-{kernel,initramfs,oftree} to make their non-permanent state more > obvious > - change name of fastboot boot script to ram-fastboot for the same > reason > - remove unneeded root=/dev/ram from kernel cmdline for the > ram-fastboot target > - update commit messages and cover-letter accordingly > - Link to v1: https://lore.distrokit.org/20230606-default_enable_fastboot_rock3a-v1-0-42195d538df2@pengutronix.de > > --- > Johannes Zink (4): > v8a: enable initrd generation > v8a: kernel: enable initramfs in kernel config > v8a: barebox: enable loading kernel, dtb and initrd via fastboot > v8a: barebox: add a boot target for fastboot loaded image files > > .../barebox-common-defaultenv/boot/ram-fastboot | 7 +++++++ > .../barebox-common-defaultenv/init/detect-mmcs | 3 +++ > .../barebox-common-defaultenv/nv/fastboot.acm | 1 + > .../barebox-common-defaultenv/nv/fastboot.bbu | 1 + > .../barebox-common-defaultenv/nv/fastboot.partitions | 1 + > .../barebox-common-defaultenv/nv/usbgadget.autostart | 1 + > configs/platform-v8a/kernelconfig | 15 ++++++++++++--- > configs/platform-v8a/platformconfig | 12 +++++++++++- > 8 files changed, 37 insertions(+), 4 deletions(-) > --- > base-commit: 282b5aff9aecf141de5040f896a9a10081596350 > change-id: 20230606-default_enable_fastboot_rock3a-3223c6b01647 > > Best regards, -- Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |