mirror_zfs/lib/libzfs
LOLi ff61d1a495 Check ashift validity in 'zpool add'
df83110 added the ability to specify a custom "ashift" value from the command
line in 'zpool add' and 'zpool attach'. This commit adds additional checks to
the provided ashift to prevent invalid values from being used, which could
result in disastrous consequences for the whole pool.

Additionally provide ASHIFT_MAX and ASHIFT_MIN definitions in spa.h.

Reviewed-by: Giuseppe Di Natale <dinatale2@llnl.gov>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: loli10K <ezomori.nozomu@gmail.com>
Closes #5878
2017-03-28 17:21:11 -07:00
..
.gitignore Add a pkgconfig file 2014-08-28 07:59:43 -07:00
libzfs_changelist.c OpenZFS 6931 - lib/libzfs: cleanup gcc warnings 2017-02-07 14:02:27 -08:00
libzfs_config.c OpenZFS 4521 - zfstest is trying to execute evil "zfs unmount -a" 2017-02-03 13:24:44 -08:00
libzfs_core.pc.in Add a pkgconfig file 2014-08-28 07:59:43 -07:00
libzfs_dataset.c OpenZFS 6931 - lib/libzfs: cleanup gcc warnings 2017-02-07 14:02:27 -08:00
libzfs_diff.c OpenZFS 6931 - lib/libzfs: cleanup gcc warnings 2017-02-07 14:02:27 -08:00
libzfs_fru.c Fix undefined reference to `libzfs_fru_compare' 2017-03-23 18:24:09 -07:00
libzfs_import.c Clear enclosure sysfs path from VDEV label when sysfs path isn't present 2017-02-10 15:18:31 -08:00
libzfs_iter.c OpenZFS 6328 - Fix cstyle errors in zfs codebase 2017-01-12 09:42:11 -08:00
libzfs_mount.c OpenZFS 6931 - lib/libzfs: cleanup gcc warnings 2017-02-07 14:02:27 -08:00
libzfs_pool.c Check ashift validity in 'zpool add' 2017-03-28 17:21:11 -07:00
libzfs_sendrecv.c Fix checksumflags assignment in cksummer 2017-02-24 11:29:47 -08:00
libzfs_status.c Read spl_hostid module parameter before gethostid() 2015-02-04 16:44:53 -08:00
libzfs_util.c OpenZFS 6931 - lib/libzfs: cleanup gcc warnings 2017-02-07 14:02:27 -08:00
libzfs.pc.in Add a pkgconfig file 2014-08-28 07:59:43 -07:00
Makefile.am Add -c to zpool iostat & status to run command 2016-11-29 14:45:38 -07:00