summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--disk/part.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/disk/part.c b/disk/part.c
index d73625c..9400a97 100644
--- a/disk/part.c
+++ b/disk/part.c
@@ -548,6 +548,8 @@ int get_device_and_partition(const char *ifname, const char *dev_part_str,
goto cleanup;
}
+ (*dev_desc)->log2blksz = LOG2((*dev_desc)->blksz);
+
info->start = 0;
info->size = (*dev_desc)->lba;
info->blksz = (*dev_desc)->blksz;
@@ -631,6 +633,8 @@ int get_device_and_partition(const char *ifname, const char *dev_part_str,
goto cleanup;
}
+ (*dev_desc)->log2blksz = LOG2((*dev_desc)->blksz);
+
ret = part;
goto cleanup;