arm: stm32mp: stm32prog: add support rootfs-a for OTA
authorPatrick Delaunay <patrick.delaunay@foss.st.com>
Thu, 16 Jan 2025 09:54:34 +0000 (10:54 +0100)
committerPatrice Chotard <patrice.chotard@foss.st.com>
Fri, 25 Apr 2025 14:00:23 +0000 (16:00 +0200)
Add support of "rootfs-a" name to allow support of A/B mechanism for OTA
on rootfs.

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Signed-off-by: Patrice Chotard <patrice.chotard@foss.st.com>
arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.c

index f6395ba..5b027fa 100644 (file)
@@ -1157,7 +1157,8 @@ static int create_gpt_partitions(struct stm32prog_data *data)
 
                        /* partition UUID */
                        uuid_bin = NULL;
-                       if (!rootfs_found && !strcmp(part->name, "rootfs")) {
+                       if (!rootfs_found && (!strcmp(part->name, "rootfs") ||
+                                             !strcmp(part->name, "rootfs-a"))) {
                                mmc_id = part->dev_id;
                                rootfs_found = true;
                                if (mmc_id < ARRAY_SIZE(uuid_mmc))