diff options
author | Karel Zak | 2012-12-05 14:32:20 +0100 |
---|---|---|
committer | Karel Zak | 2013-03-11 11:20:40 +0100 |
commit | 9475cc78ff5318fb659a7b90bb181f9c9522de02 (patch) | |
tree | 5a084b4eb71dfd2fad97d51b879fde061d9e0209 /fdisks/fdiskdoslabel.c | |
parent | libfdisk: add parttype code (diff) | |
download | kernel-qcow2-util-linux-9475cc78ff5318fb659a7b90bb181f9c9522de02.tar.gz kernel-qcow2-util-linux-9475cc78ff5318fb659a7b90bb181f9c9522de02.tar.xz kernel-qcow2-util-linux-9475cc78ff5318fb659a7b90bb181f9c9522de02.zip |
libfdisk: add alignment code
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'fdisks/fdiskdoslabel.c')
-rw-r--r-- | fdisks/fdiskdoslabel.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fdisks/fdiskdoslabel.c b/fdisks/fdiskdoslabel.c index ab940a010..45343c838 100644 --- a/fdisks/fdiskdoslabel.c +++ b/fdisks/fdiskdoslabel.c @@ -590,7 +590,7 @@ static int add_partition(struct fdisk_context *cxt, int n, struct fdisk_parttype /* the default sector should be aligned and unused */ do { - aligned = align_lba_in_range(cxt, dflt, dflt, limit); + aligned = fdisk_align_lba_in_range(cxt, dflt, dflt, limit); dflt = get_unused_start(cxt, n, aligned, first, last); } while (dflt != aligned && dflt > aligned && dflt < limit); @@ -664,7 +664,7 @@ static int add_partition(struct fdisk_context *cxt, int n, struct fdisk_parttype * and align the end of the partition. The next * partition will start at phy.block boundary. */ - stop = align_lba_in_range(cxt, stop, start, limit) - 1; + stop = fdisk_align_lba_in_range(cxt, stop, start, limit) - 1; if (stop > limit) stop = limit; } @@ -721,7 +721,7 @@ static int dos_verify_disklabel(struct fdisk_context *cxt) p = pe->part_table; if (p->sys_ind && !IS_EXTENDED (p->sys_ind)) { check_consistency(cxt, p, i); - check_alignment(cxt, get_partition_start(pe), i); + fdisk_warn_alignment(cxt, get_partition_start(pe), i); if (get_partition_start(pe) < first[i]) printf(_("Warning: bad start-of-data in " "partition %d\n"), i + 1); |