summaryrefslogtreecommitdiff
path: root/drivers/fastboot/fb_command.c
diff options
context:
space:
mode:
authorTom Rini <[email protected]>2025-12-04 08:35:41 -0600
committerTom Rini <[email protected]>2025-12-04 08:35:41 -0600
commit2d08dfc1dc4fc159b13d54535fdca4566b5808d1 (patch)
tree6682c52efde5e39c0857e06d8a635872c7fb4edd /drivers/fastboot/fb_command.c
parentd300702c5be5a846032834abe4f01dcd3f50b3a8 (diff)
parent769c6cbbb53074025c3af53d8df5571ae18d74c3 (diff)
Merge tag 'u-boot-dfu-next-20251203' of https://source.denx.de/u-boot/custodians/u-boot-dfu into next
u-boot-dfu-next-20251203: CI: https://source.denx.de/u-boot/custodians/u-boot-dfu/-/pipelines/28617 Fastboot: - Add generic flashing support using BLK
Diffstat (limited to 'drivers/fastboot/fb_command.c')
-rw-r--r--drivers/fastboot/fb_command.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/fastboot/fb_command.c b/drivers/fastboot/fb_command.c
index 791088bc094..18d86988f4c 100644
--- a/drivers/fastboot/fb_command.c
+++ b/drivers/fastboot/fb_command.c
@@ -8,6 +8,7 @@
#include <env.h>
#include <fastboot.h>
#include <fastboot-internal.h>
+#include <fb_block.h>
#include <fb_mmc.h>
#include <fb_nand.h>
#include <fb_spi_flash.h>
@@ -338,6 +339,10 @@ void fastboot_data_complete(char *response)
*/
static void __maybe_unused flash(char *cmd_parameter, char *response)
{
+ if (IS_ENABLED(CONFIG_FASTBOOT_FLASH_BLOCK))
+ fastboot_block_flash_write(cmd_parameter, fastboot_buf_addr,
+ image_size, response);
+
if (IS_ENABLED(CONFIG_FASTBOOT_FLASH_MMC))
fastboot_mmc_flash_write(cmd_parameter, fastboot_buf_addr,
image_size, response);
@@ -362,6 +367,9 @@ static void __maybe_unused flash(char *cmd_parameter, char *response)
*/
static void __maybe_unused erase(char *cmd_parameter, char *response)
{
+ if (IS_ENABLED(CONFIG_FASTBOOT_FLASH_BLOCK))
+ fastboot_block_erase(cmd_parameter, response);
+
if (IS_ENABLED(CONFIG_FASTBOOT_FLASH_MMC))
fastboot_mmc_erase(cmd_parameter, response);