aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libs/linux-headers/linux/falloc.h
diff options
context:
space:
mode:
authororivej <orivej@yandex-team.ru>2022-02-10 16:44:49 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:44:49 +0300
commit718c552901d703c502ccbefdfc3c9028d608b947 (patch)
tree46534a98bbefcd7b1f3faa5b52c138ab27db75b7 /contrib/libs/linux-headers/linux/falloc.h
parente9656aae26e0358d5378e5b63dcac5c8dbe0e4d0 (diff)
downloadydb-718c552901d703c502ccbefdfc3c9028d608b947.tar.gz
Restoring authorship annotation for <orivej@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'contrib/libs/linux-headers/linux/falloc.h')
-rw-r--r--contrib/libs/linux-headers/linux/falloc.h160
1 files changed, 80 insertions, 80 deletions
diff --git a/contrib/libs/linux-headers/linux/falloc.h b/contrib/libs/linux-headers/linux/falloc.h
index ca3904dd25..589b798bd4 100644
--- a/contrib/libs/linux-headers/linux/falloc.h
+++ b/contrib/libs/linux-headers/linux/falloc.h
@@ -1,80 +1,80 @@
-/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
-#ifndef _FALLOC_H_
-#define _FALLOC_H_
-
-#define FALLOC_FL_KEEP_SIZE 0x01 /* default is extend size */
-#define FALLOC_FL_PUNCH_HOLE 0x02 /* de-allocates range */
-#define FALLOC_FL_NO_HIDE_STALE 0x04 /* reserved codepoint */
-
-/*
- * FALLOC_FL_COLLAPSE_RANGE is used to remove a range of a file
- * without leaving a hole in the file. The contents of the file beyond
- * the range being removed is appended to the start offset of the range
- * being removed (i.e. the hole that was punched is "collapsed"),
- * resulting in a file layout that looks like the range that was
- * removed never existed. As such collapsing a range of a file changes
- * the size of the file, reducing it by the same length of the range
- * that has been removed by the operation.
- *
- * Different filesystems may implement different limitations on the
- * granularity of the operation. Most will limit operations to
- * filesystem block size boundaries, but this boundary may be larger or
- * smaller depending on the filesystem and/or the configuration of the
- * filesystem or file.
- *
- * Attempting to collapse a range that crosses the end of the file is
- * considered an illegal operation - just use ftruncate(2) if you need
- * to collapse a range that crosses EOF.
- */
-#define FALLOC_FL_COLLAPSE_RANGE 0x08
-
-/*
- * FALLOC_FL_ZERO_RANGE is used to convert a range of file to zeros preferably
- * without issuing data IO. Blocks should be preallocated for the regions that
- * span holes in the file, and the entire range is preferable converted to
- * unwritten extents - even though file system may choose to zero out the
- * extent or do whatever which will result in reading zeros from the range
- * while the range remains allocated for the file.
- *
- * This can be also used to preallocate blocks past EOF in the same way as
- * with fallocate. Flag FALLOC_FL_KEEP_SIZE should cause the inode
- * size to remain the same.
- */
-#define FALLOC_FL_ZERO_RANGE 0x10
-
-/*
- * FALLOC_FL_INSERT_RANGE is use to insert space within the file size without
- * overwriting any existing data. The contents of the file beyond offset are
- * shifted towards right by len bytes to create a hole. As such, this
- * operation will increase the size of the file by len bytes.
- *
- * Different filesystems may implement different limitations on the granularity
- * of the operation. Most will limit operations to filesystem block size
- * boundaries, but this boundary may be larger or smaller depending on
- * the filesystem and/or the configuration of the filesystem or file.
- *
- * Attempting to insert space using this flag at OR beyond the end of
- * the file is considered an illegal operation - just use ftruncate(2) or
- * fallocate(2) with mode 0 for such type of operations.
- */
-#define FALLOC_FL_INSERT_RANGE 0x20
-
-/*
- * FALLOC_FL_UNSHARE_RANGE is used to unshare shared blocks within the
- * file size without overwriting any existing data. The purpose of this
- * call is to preemptively reallocate any blocks that are subject to
- * copy-on-write.
- *
- * Different filesystems may implement different limitations on the
- * granularity of the operation. Most will limit operations to filesystem
- * block size boundaries, but this boundary may be larger or smaller
- * depending on the filesystem and/or the configuration of the filesystem
- * or file.
- *
- * This flag can only be used with allocate-mode fallocate, which is
- * to say that it cannot be used with the punch, zero, collapse, or
- * insert range modes.
- */
-#define FALLOC_FL_UNSHARE_RANGE 0x40
-
-#endif /* _FALLOC_H_ */
+/* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
+#ifndef _FALLOC_H_
+#define _FALLOC_H_
+
+#define FALLOC_FL_KEEP_SIZE 0x01 /* default is extend size */
+#define FALLOC_FL_PUNCH_HOLE 0x02 /* de-allocates range */
+#define FALLOC_FL_NO_HIDE_STALE 0x04 /* reserved codepoint */
+
+/*
+ * FALLOC_FL_COLLAPSE_RANGE is used to remove a range of a file
+ * without leaving a hole in the file. The contents of the file beyond
+ * the range being removed is appended to the start offset of the range
+ * being removed (i.e. the hole that was punched is "collapsed"),
+ * resulting in a file layout that looks like the range that was
+ * removed never existed. As such collapsing a range of a file changes
+ * the size of the file, reducing it by the same length of the range
+ * that has been removed by the operation.
+ *
+ * Different filesystems may implement different limitations on the
+ * granularity of the operation. Most will limit operations to
+ * filesystem block size boundaries, but this boundary may be larger or
+ * smaller depending on the filesystem and/or the configuration of the
+ * filesystem or file.
+ *
+ * Attempting to collapse a range that crosses the end of the file is
+ * considered an illegal operation - just use ftruncate(2) if you need
+ * to collapse a range that crosses EOF.
+ */
+#define FALLOC_FL_COLLAPSE_RANGE 0x08
+
+/*
+ * FALLOC_FL_ZERO_RANGE is used to convert a range of file to zeros preferably
+ * without issuing data IO. Blocks should be preallocated for the regions that
+ * span holes in the file, and the entire range is preferable converted to
+ * unwritten extents - even though file system may choose to zero out the
+ * extent or do whatever which will result in reading zeros from the range
+ * while the range remains allocated for the file.
+ *
+ * This can be also used to preallocate blocks past EOF in the same way as
+ * with fallocate. Flag FALLOC_FL_KEEP_SIZE should cause the inode
+ * size to remain the same.
+ */
+#define FALLOC_FL_ZERO_RANGE 0x10
+
+/*
+ * FALLOC_FL_INSERT_RANGE is use to insert space within the file size without
+ * overwriting any existing data. The contents of the file beyond offset are
+ * shifted towards right by len bytes to create a hole. As such, this
+ * operation will increase the size of the file by len bytes.
+ *
+ * Different filesystems may implement different limitations on the granularity
+ * of the operation. Most will limit operations to filesystem block size
+ * boundaries, but this boundary may be larger or smaller depending on
+ * the filesystem and/or the configuration of the filesystem or file.
+ *
+ * Attempting to insert space using this flag at OR beyond the end of
+ * the file is considered an illegal operation - just use ftruncate(2) or
+ * fallocate(2) with mode 0 for such type of operations.
+ */
+#define FALLOC_FL_INSERT_RANGE 0x20
+
+/*
+ * FALLOC_FL_UNSHARE_RANGE is used to unshare shared blocks within the
+ * file size without overwriting any existing data. The purpose of this
+ * call is to preemptively reallocate any blocks that are subject to
+ * copy-on-write.
+ *
+ * Different filesystems may implement different limitations on the
+ * granularity of the operation. Most will limit operations to filesystem
+ * block size boundaries, but this boundary may be larger or smaller
+ * depending on the filesystem and/or the configuration of the filesystem
+ * or file.
+ *
+ * This flag can only be used with allocate-mode fallocate, which is
+ * to say that it cannot be used with the punch, zero, collapse, or
+ * insert range modes.
+ */
+#define FALLOC_FL_UNSHARE_RANGE 0x40
+
+#endif /* _FALLOC_H_ */