From: "Darrick J. Wong" <darrick.wong@oracle.com>
To: Eric Sandeen <sandeen@sandeen.net>
Cc: linux-xfs <linux-xfs@vger.kernel.org>
Subject: Re: [PATCH 1/3] mkfs: un-document removed logarithm based CLI options
Date: Tue, 2 Jan 2018 09:40:20 -0800 [thread overview]
Message-ID: <20180102174020.GA4857@magnolia> (raw)
In-Reply-To: <c518f87e-78ae-d83b-f714-d86a70d8049c@sandeen.net>
On Sun, Dec 24, 2017 at 11:09:01AM -0800, Eric Sandeen wrote:
> Remove logarithm-based options from usage() and manpage.
>
> Fixes: 70f72d5 "mkfs: remove logarithm based CLI options"
> Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
Looks ok, though /me hates reading manpage sources: :)
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
--D
> ---
>
> diff --git a/man/man8/mkfs.xfs.8 b/man/man8/mkfs.xfs.8
> index bbbe1c5..4b8c78c 100644
> --- a/man/man8/mkfs.xfs.8
> +++ b/man/man8/mkfs.xfs.8
> @@ -5,7 +5,7 @@ mkfs.xfs \- construct an XFS filesystem
> .B mkfs.xfs
> [
> .B \-b
> -.I block_size
> +.I block_size_options
> ] [
> .B \-m
> .I global_metadata_options
> @@ -33,7 +33,7 @@ mkfs.xfs \- construct an XFS filesystem
> .I realtime_section_options
> ] [
> .B \-s
> -.I sector_size
> +.I sector_size_options
> ] [
> .B \-L
> .I label
> @@ -126,17 +126,14 @@ disable or enable the functionality.
> .BI \-b " block_size_options"
> This option specifies the fundamental block size of the filesystem.
> The valid
> -.I block_size_options
> -are:
> -.BI log= value
> -or
> +.I block_size_option
> +is:
> +.RS 1.2i
> +.TP
> .BI size= value
> -and only one can be supplied.
> -The block size is specified either as a base two logarithm value with
> -.BR log= ,
> -or in bytes with
> -.BR size= .
> -The default value is 4096 bytes (4 KiB), the minimum is 512, and the
> +The filesystem block size is specified with a
> +.I value
> +in bytes. The default value is 4096 bytes (4 KiB), the minimum is 512, and the
> maximum is 65536 (64 KiB).
> .IP
> To specify any options on the command line in units of filesystem blocks, this
> @@ -147,6 +144,7 @@ Although
> .B mkfs.xfs
> will accept any of these values and create a valid filesystem,
> XFS on Linux can only mount filesystems with pagesize or smaller blocks.
> +.RE
> .TP
> .BI \-m " global_metadata_options"
> These options specify metadata format options that either apply to the entire
> @@ -419,15 +417,11 @@ The valid
> are:
> .RS 1.2i
> .TP
> -.BI size= value " | log=" value " | perblock=" value
> +.BI size= value " | perblock=" value
> The inode size is specified either as a
> .I value
> in bytes with
> -.BR size= ,
> -a base two logarithm
> -.I value
> -with
> -.BR log= ,
> +.BR size=
> or as the number fitting in a filesystem block with
> .BR perblock= .
> The minimum (and default)
> @@ -648,15 +642,10 @@ These options specify the version and size parameters for the naming
> are:
> .RS 1.2i
> .TP
> -.BI size= value " | log=" value
> -The block size is specified either as a
> -.I value
> -in bytes with
> -.BR size= ,
> -or as a base two logarithm
> +.BI size= value
> +The directory block size is specified with a
> .I value
> -.RB "with " log= .
> -The block size must be a power of 2 and cannot be less than the
> +in bytes. The block size must be a power of 2 and cannot be less than the
> filesystem block size.
> The default size
> .I value
> @@ -888,15 +877,17 @@ This option disables stripe size detection, enforcing a realtime device with no
> stripe geometry.
> .RE
> .TP
> -.BI \-s " sector_size"
> +.BI \-s " sector_size_options"
> This option specifies the fundamental sector size of the filesystem.
> -The
> -.I sector_size
> -is specified either as a value in bytes with
> +The valid
> +.I sector_size_option
> +is:
> +.RS 1.2i
> +.TP
> .BI size= value
> -or as a base two logarithm value with
> -.BI log= value.
> -The default
> +The sector size is specified with a
> +.I value
> +in bytes. The default
> .I sector_size
> is 512 bytes. The minimum value for sector size is
> 512; the maximum is 32768 (32 KiB). The
> @@ -907,6 +898,7 @@ filesystem block size.
> To specify any options on the command line in units of sectors, this
> option must be specified first so that the sector size is
> applied consistently to all options.
> +.RE
> .TP
> .BI \-L " label"
> Set the filesystem
> diff --git a/mkfs/xfs_mkfs.c b/mkfs/xfs_mkfs.c
> index f3d57cf..1f3494c 100644
> --- a/mkfs/xfs_mkfs.c
> +++ b/mkfs/xfs_mkfs.c
> @@ -860,25 +860,24 @@ static void __attribute__((noreturn))
> usage( void )
> {
> fprintf(stderr, _("Usage: %s\n\
> -/* blocksize */ [-b log=n|size=num]\n\
> +/* blocksize */ [-b size=num]\n\
> /* metadata */ [-m crc=0|1,finobt=0|1,uuid=xxx,rmapbt=0|1,reflink=0|1]\n\
> /* data subvol */ [-d agcount=n,agsize=n,file,name=xxx,size=num,\n\
> (sunit=value,swidth=value|su=num,sw=num|noalign),\n\
> - sectlog=n|sectsize=num\n\
> + sectsize=num\n\
> /* force overwrite */ [-f]\n\
> /* inode size */ [-i log=n|perblock=n|size=num,maxpct=n,attr=0|1|2,\n\
> projid32bit=0|1,sparse=0|1]\n\
> /* no discard */ [-K]\n\
> /* log subvol */ [-l agnum=n,internal,size=num,logdev=xxx,version=n\n\
> - sunit=value|su=num,sectlog=n|sectsize=num,\n\
> - lazy-count=0|1]\n\
> + sunit=value|su=num,sectsize=num,lazy-count=0|1]\n\
> /* label */ [-L label (maximum 12 characters)]\n\
> -/* naming */ [-n log=n|size=num,version=2|ci,ftype=0|1]\n\
> +/* naming */ [-n size=num,version=2|ci,ftype=0|1]\n\
> /* no-op info only */ [-N]\n\
> /* prototype file */ [-p fname]\n\
> /* quiet */ [-q]\n\
> /* realtime subvol */ [-r extsize=num,size=num,rtdev=xxx]\n\
> -/* sectorsize */ [-s log=n|size=num]\n\
> +/* sectorsize */ [-s size=num]\n\
> /* version */ [-V]\n\
> devicename\n\
> <devicename> is required unless -d name=xxx is given.\n\
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2018-01-02 17:48 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-24 19:05 [PATCH 0/3] xfsprogs: misc xfsprogs cleanups Eric Sandeen
2017-12-24 19:09 ` [PATCH 1/3] mkfs: un-document removed logarithm based CLI options Eric Sandeen
2018-01-02 17:40 ` Darrick J. Wong [this message]
2017-12-24 19:10 ` [PATCH 2/3] mkfs: pass switch case value directly into getnum/getstr Eric Sandeen
2018-01-02 17:41 ` Darrick J. Wong
2017-12-24 19:12 ` [PATCH 3/3] mkfs: do not allow both "dev" and "name" subopts for log or realtime Eric Sandeen
2018-01-02 17:44 ` Darrick J. Wong
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180102174020.GA4857@magnolia \
--to=darrick.wong@oracle.com \
--cc=linux-xfs@vger.kernel.org \
--cc=sandeen@sandeen.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).