@@ -526,7 +526,8 @@
ddf1_sboffset) || !is_ddf1(lc, di, ddf1))
goto bad;
- ddf1->anchor_offset = ddf1_sboffset;
+ /* ddf1_sboffset is in bytes. */
+ ddf1->anchor_offset = ddf1_sboffset >> 9;
/* Convert endianness */
ddf1->in_cpu_format = 0;
@@ -962,6 +963,7 @@
ma[i].offset = ddf1->primary->primary_table_lba;
ma->offset = ddf1->anchor_offset;
+ ma->size = DDF1_BLKSIZE;
(ma++)->area = &ddf1->anchor;
(ma++)->area = ddf1->primary;
@@ -60,7 +60,7 @@
{
log_print(lc, "%s (%s):", di->path, handler);
log_print(lc, "DDF1 anchor at %llu with tables in %s-endian format.",
- ddf1->anchor_offset / DDF1_BLKSIZE,
+ ddf1->anchor_offset,
(ddf1->disk_format == LITTLE_ENDIAN ? "little" : "big"));
}