summaryrefslogtreecommitdiff
path: root/drivers/fastboot/fb_command.c
diff options
context:
space:
mode:
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);