commit b98113ec73748007b944a9b5ea5226d4c6d7224a Author: Tomohiro Kusumi <kusumi.tomoh...@gmail.com> Date: Sat Oct 31 19:57:29 2015 +0900
sys/dev/disk/dm: Fix sanity checks for striped target [2/4] Target specific args for striped is redundant in the sense that it has an arg for # of stripes other than the args for actual stripe devices. These two must meet below. ((argc - 2) / 2) == # of stripe devices. e.g. --table '0 100 stripe1 3 10 /dev/da3 0 /dev/da4 0 /dev/da5 0' ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 8 target args ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 6 device args ^ # of stripe devices ((8 - 2) / 2) = 6/2 = 3 -> 3 stripe devices (/dev/da[345]) Summary of changes: sys/dev/disk/dm/targets/striped/dm_target_striped.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/b98113ec73748007b944a9b5ea5226d4c6d7224a -- DragonFly BSD source repository