[PATCH] mkfs: fix -l su minval
Eric Sandeen
sandeen at sandeen.net
Mon Jun 6 15:41:23 CDT 2016
On 6/6/16 2:55 AM, Jan Tulak wrote:
> -l su should be in range BBTOB(1) <= L_SU <= XLOG_MAX_RECORD_BSIZE, because the
> upper limit is imposed by kernel on iclogbuf: stripe unit can't be bigger than
> the log buffer, but the log buffer can span multiple stripe units. L_SUNIT is
> changed in the same way.
>
> Signed-off-by: Jan Tulak <jtulak at redhat.com>
Manpage could use documentation on defaults, min, and max I suppose.
But for this code change:
Reviewed-by: Eric Sandeen <sandeen at redhat.com>
Thanks for digging into it :)
> ---
> mkfs/xfs_mkfs.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/mkfs/xfs_mkfs.c b/mkfs/xfs_mkfs.c
> index 955dcfd..ed7800f 100644
> --- a/mkfs/xfs_mkfs.c
> +++ b/mkfs/xfs_mkfs.c
> @@ -462,7 +462,7 @@ struct opt_params lopts = {
> { .index = L_SUNIT,
> .conflicts = { L_SU,
> LAST_CONFLICT },
> - .minval = BTOBB(XLOG_MIN_RECORD_BSIZE),
> + .minval = 1,
> .maxval = BTOBB(XLOG_MAX_RECORD_BSIZE),
> .defaultval = SUBOPT_NEEDS_VAL,
> },
> @@ -470,7 +470,7 @@ struct opt_params lopts = {
> .conflicts = { L_SUNIT,
> LAST_CONFLICT },
> .convert = true,
> - .minval = XLOG_MIN_RECORD_BSIZE,
> + .minval = BBTOB(1),
> .maxval = XLOG_MAX_RECORD_BSIZE,
> .defaultval = SUBOPT_NEEDS_VAL,
> },
>
More information about the xfs
mailing list