mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-27 06:34:11 +08:00
UBI: bugfix: calculate data offset properly
Data offset is VID header offset + VID header size aligned to the min. I/O unit size up. Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
This commit is contained in:
parent
ddc4939161
commit
d536058752
@ -562,7 +562,7 @@ static int io_init(struct ubi_device *ubi)
|
||||
}
|
||||
|
||||
/* Similar for the data offset */
|
||||
ubi->leb_start = ubi->vid_hdr_offset + ubi->vid_hdr_alsize;
|
||||
ubi->leb_start = ubi->vid_hdr_offset + UBI_EC_HDR_SIZE;
|
||||
ubi->leb_start = ALIGN(ubi->leb_start, ubi->min_io_size);
|
||||
|
||||
dbg_msg("vid_hdr_offset %d", ubi->vid_hdr_offset);
|
||||
|
Loading…
Reference in New Issue
Block a user