From: Benno Schulenberg Date: Thu, 18 Sep 2025 08:57:07 +0000 (+0200) Subject: fallocate: (man,usage) correct the alphabetical sorting of the options X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=04c6b3327741fb5e64ea4125ebdbaaeaa9c53469;p=thirdparty%2Futil-linux.git fallocate: (man,usage) correct the alphabetical sorting of the options Signed-off-by: Benno Schulenberg --- diff --git a/sys-utils/fallocate.1.adoc b/sys-utils/fallocate.1.adoc index 0b7ea39db..4a96d009d 100644 --- a/sys-utils/fallocate.1.adoc +++ b/sys-utils/fallocate.1.adoc @@ -64,6 +64,13 @@ Supported for XFS (since Linux 2.6.38), ext4 (since Linux 3.0), Btrfs (since Lin *-v*, *--verbose*:: Enable verbose mode. +*-w*, *--write-zeroes*:: +Zeroes space in the byte range starting at _offset_ and continuing for _length_ bytes. Within the specified range, written blocks are preallocated for the regions that span the holes in the file. After a successful call, subsequent reads from this range will return zeroes and subsequent writes to that range do not require further changes to the file mapping metadata. ++ +Zeroing is done within the filesystem. The filesystem may use a hardware-accelerated zeroing command or may submit regular writes. The behavior depends on the filesystem design and the available hardware. ++ +Option *--keep-size* cannot be specified for the write-zeroes operation because allocating written blocks beyond the inode size is not permitted. + *-x*, *--posix*:: Enable POSIX operation mode. In that mode allocation operation always completes, but it may take longer time when fast allocation is not supported by the underlying filesystem. @@ -76,13 +83,6 @@ Option *--keep-size* can be specified to prevent file length modification. + Available since Linux 3.14 for ext4 (only for extent-based files) and XFS. -*-w*, *--write-zeroes*:: -Zeroes space in the byte range starting at _offset_ and continuing for _length_ bytes. Within the specified range, written blocks are preallocated for the regions that span the holes in the file. After a successful call, subsequent reads from this range will return zeroes and subsequent writes to that range do not require further changes to the file mapping metadata. -+ -Zeroing is done within the filesystem. The filesystem may use a hardware-accelerated zeroing command or may submit regular writes. The behavior depends on the filesystem design and the available hardware. -+ -Option *--keep-size* cannot be specified for the write-zeroes operation because allocating written blocks beyond the inode size is not permitted. - include::man-common/help-version.adoc[] == AUTHORS diff --git a/sys-utils/fallocate.c b/sys-utils/fallocate.c index afd615537..f06009483 100644 --- a/sys-utils/fallocate.c +++ b/sys-utils/fallocate.c @@ -97,12 +97,12 @@ static void __attribute__((__noreturn__)) usage(void) fputs(_(" -n, --keep-size maintain the apparent size of the file\n"), out); fputs(_(" -o, --offset offset for range operations, in bytes\n"), out); fputs(_(" -p, --punch-hole replace a range with a hole (implies -n)\n"), out); - fputs(_(" -z, --zero-range zero and ensure allocation of a range\n"), out); + fputs(_(" -v, --verbose verbose mode\n"), out); fputs(_(" -w, --write-zeroes write zeroes and ensure allocation of a range\n"), out); #ifdef HAVE_POSIX_FALLOCATE fputs(_(" -x, --posix use posix_fallocate(3) instead of fallocate(2)\n"), out); #endif - fputs(_(" -v, --verbose verbose mode\n"), out); + fputs(_(" -z, --zero-range zero and ensure allocation of a range\n"), out); fputs(USAGE_SEPARATOR, out); fprintf(out, USAGE_HELP_OPTIONS(22));