svn commit: r223355 - head/sbin/geom/class/part
Andrey V. Elsukov
ae at FreeBSD.org
Tue Jun 21 04:06:39 UTC 2011
Author: ae
Date: Tue Jun 21 04:06:39 2011
New Revision: 223355
URL: http://svn.freebsd.org/changeset/base/223355
Log:
The "size" param needs no adjusting to stripeoffset.
Reported by: Kris Moore
Modified:
head/sbin/geom/class/part/geom_part.c
Modified: head/sbin/geom/class/part/geom_part.c
==============================================================================
--- head/sbin/geom/class/part/geom_part.c Tue Jun 21 03:42:00 2011 (r223354)
+++ head/sbin/geom/class/part/geom_part.c Tue Jun 21 04:06:39 2011 (r223355)
@@ -499,8 +499,8 @@ gpart_autofill(struct gctl_req *req)
/* Adjust parameters to stripeoffset */
offset = pp->lg_stripeoffset / pp->lg_sectorsize;
start = ALIGNUP(start + offset, alignment);
- if (size + offset > alignment)
- size = ALIGNDOWN(size + offset, alignment);
+ if (size > alignment)
+ size = ALIGNDOWN(size, alignment);
first = (off_t)strtoimax(find_geomcfg(gp, "first"), NULL, 0);
last = (off_t)strtoimax(find_geomcfg(gp, "last"), NULL, 0);
More information about the svn-src-all
mailing list