summaryrefslogtreecommitdiff
path: root/disk
diff options
context:
space:
mode:
authorGary Bisson <gary.bisson@boundarydevices.com>2021-01-28 11:10:07 +0300
committerTom Rini <trini@konsulko.com>2021-02-02 00:32:06 +0300
commitf14c5ee5ab8bfac0fdbae1143170d8390867479d (patch)
treed34229698eaf0a4504d207defd6c0d429cbe78c1 /disk
parent7a01882eb37e7504e2450f474d0cc8db60ed26c2 (diff)
downloadu-boot-f14c5ee5ab8bfac0fdbae1143170d8390867479d.tar.xz
disk: part_dos: update partition table entries after write
Fixes issues when switching from GPT to MBR partition tables. Signed-off-by: Gary Bisson <gary.bisson@boundarydevices.com> Acked-by: Marek Szyprowski <m.szyprowski@samsung.com>
Diffstat (limited to 'disk')
-rw-r--r--disk/part_dos.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/disk/part_dos.c b/disk/part_dos.c
index f431925745..60addc6e00 100644
--- a/disk/part_dos.c
+++ b/disk/part_dos.c
@@ -423,6 +423,9 @@ int write_mbr_partitions(struct blk_desc *dev,
ext_part_sect = next_ebr;
}
+ /* Update the partition table entries*/
+ part_init(dev_desc);
+
return 0;
}
@@ -499,6 +502,9 @@ int write_mbr_sector(struct blk_desc *dev_desc, void *buf)
return 1;
}
+ /* Update the partition table entries*/
+ part_init(dev_desc);
+
return 0;
}