[PATCH 2/2] fastboot: fb_mmc: Add mfgtool all partition size
Angus Ainslie
angus at akkea.ca
Fri Dec 17 16:42:00 CET 2021
NXP mfgtool uses all to specify the entire partition
Signed-off-by: Angus Ainslie <angus at akkea.ca>
---
drivers/fastboot/fb_mmc.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/fastboot/fb_mmc.c b/drivers/fastboot/fb_mmc.c
index 2738dc836e..9ebf392252 100644
--- a/drivers/fastboot/fb_mmc.c
+++ b/drivers/fastboot/fb_mmc.c
@@ -84,6 +84,13 @@ static int do_get_part_info(struct blk_desc **dev_desc, const char *name,
/* First try partition names on the default device */
*dev_desc = blk_get_dev("mmc", CONFIG_FASTBOOT_FLASH_MMC_DEV);
if (*dev_desc) {
+ if (!strncmp(name, "all", strlen("all"))) {
+ info->blksz = (*dev_desc)->blksz;
+ info->size = (*dev_desc)->lba;
+ info->start = 0;
+ return 0;
+ }
+
ret = part_get_info_by_name(*dev_desc, name, info);
if (ret >= 0)
return ret;
--
2.25.1
More information about the U-Boot
mailing list