U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Mattijs Korpershoek <mkorpershoek@kernel.org>
To: neil.armstrong@linaro.org, Tom Rini <trini@konsulko.com>,
	Mattijs Korpershoek <mkorpershoek@kernel.org>,
	Mattijs Korpershoek <mkorpershoek@kernel.org>
Cc: u-boot@lists.denx.de, Neil Armstrong <neil.armstrong@linaro.org>,
	Dmitrii Merkurev <dimorinny@google.com>
Subject: Re: [PATCH RFT v3 0/3] fastboot: add support for generic block flashing
Date: Wed, 07 May 2025 12:02:07 +0200	[thread overview]
Message-ID: <87o6w4agdc.fsf@kernel.org> (raw)
In-Reply-To: <20250506-topic-fastboot-blk-v3-0-d94be5829f46@linaro.org>

Hi Neil,

Thank you for the series.

On mar., mai 06, 2025 at 18:10, neil.armstrong@linaro.org wrote:

> This serie permits using any block device as target
> for fastboot by moving the generic block logic into
> a common set of helpers and also use them as generic
> backend.
>
> The erase logic has been extended to support software
> erase since only 2 block drivers exposes the erase
> operation.
>
> Tests are welcome to make sure this series doesn't
> introduce any regressions on the emmc backend.

I've tested the series on khadas-vim3_android_defconfig
keeping CONFIG_FASTBOOT_FLASH_MMC=y (so with the emmc backend)

I tested the following:
# flashing a raw partition with a descriptor:
$ fastboot flash bootloader u-boot_kvim3_noab.bin
# flashing a sparse image:
$ fastboot flash super super.img

I also testing reflashing the super.img when using the generic block
layer:
=> fastboot usb 0
Warning: the fastboot block backend features are limited, consider using the MMC backend

$ fastboot flash super super.img

Both work great!

Tested-by: Mattijs Korpershoek <mkorpershoek@kernel.org>

I've also opened a issue on gitlab to harmonize the fastboot emmc
backend with the generic block backend:
https://source.denx.de/u-boot/custodians/u-boot-dfu/-/issues/6

>
> Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
> ---
> Changes in v3:
> - Move Kconfig/Makefile changes over the 2 patches
> - Relicence to GPL2 with Dmitrii approval
> - Move soft erase in a separate function
> - Update help text of Kconfig BLOCK entries
> - Add warning at init if MMC was selected with BLOCK backend
> - Link to v2: https://lore.kernel.org/r/20250409-topic-fastboot-blk-v2-0-c676f21d414f@linaro.org
>
> Changes in v2:
> - Dropped applied virtio erase patch
> - Reorganize patches, introducing helpers first, using them in mmc afterwards
> - Added soft-erase logic
> - Added move helpers to handle the partitions erase & flash from emmc
> - Fixed const var on last patch
> - Link to v1: https://lore.kernel.org/all/20240306185921.1854109-1-dimorinny@google.com/
>
> ---
> Dmitrii Merkurev (3):
>       fastboot: blk: introduce fastboot block flashing support
>       fastboot: blk: switch emmc to use the block helpers
>       fastboot: integrate block flashing back-end
>
>  drivers/fastboot/Kconfig      |  28 +++-
>  drivers/fastboot/Makefile     |   4 +-
>  drivers/fastboot/fb_block.c   | 323 ++++++++++++++++++++++++++++++++++++++++++
>  drivers/fastboot/fb_command.c |   8 ++
>  drivers/fastboot/fb_common.c  |  22 ++-
>  drivers/fastboot/fb_getvar.c  |   8 +-
>  drivers/fastboot/fb_mmc.c     | 210 ++-------------------------
>  include/fb_block.h            | 105 ++++++++++++++
>  8 files changed, 502 insertions(+), 206 deletions(-)
> ---
> base-commit: 4d3b5c679bc9d5c6cbbeedcc1e4a186f1cc35541
> change-id: 20250408-topic-fastboot-blk-c5e14cd59224
>
> Best regards,
> -- 
> Neil Armstrong <neil.armstrong@linaro.org>

  parent reply	other threads:[~2025-05-07 10:02 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-05-06 16:10 [PATCH RFT v3 0/3] fastboot: add support for generic block flashing neil.armstrong
2025-05-06 16:10 ` [PATCH RFT v3 1/3] fastboot: blk: introduce fastboot block flashing support neil.armstrong
2025-05-07 10:05   ` Mattijs Korpershoek
2025-05-06 16:10 ` [PATCH RFT v3 2/3] fastboot: blk: switch emmc to use the block helpers neil.armstrong
2025-05-07 10:06   ` Mattijs Korpershoek
2025-05-06 16:10 ` [PATCH RFT v3 3/3] fastboot: integrate block flashing back-end neil.armstrong
2025-05-07 10:02 ` Mattijs Korpershoek [this message]
2025-05-07 11:50   ` [PATCH RFT v3 0/3] fastboot: add support for generic block flashing Neil Armstrong
2025-05-20 11:35 ` Mattijs Korpershoek
2025-05-21 14:49   ` Mattijs Korpershoek
2025-05-21 15:12     ` Tom Rini
2025-05-21 18:52       ` Mattijs Korpershoek
2025-05-21 19:03         ` Tom Rini
2025-05-22  6:58           ` Mattijs Korpershoek
2025-05-22  7:52             ` neil.armstrong
2025-05-22 14:30               ` Tom Rini

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87o6w4agdc.fsf@kernel.org \
    --to=mkorpershoek@kernel.org \
    --cc=dimorinny@google.com \
    --cc=neil.armstrong@linaro.org \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox