lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230929093717.2972367-2-john.g.garry@oracle.com>
Date:   Fri, 29 Sep 2023 09:37:14 +0000
From:   John Garry <john.g.garry@...cle.com>
To:     linux-kernel@...r.kernel.org, linux-api@...r.kernel.org
Cc:     martin.petersen@...cle.com, djwong@...nel.org, david@...morbit.com,
        himanshu.madhani@...cle.com, John Garry <john.g.garry@...cle.com>
Subject: [PATCH 1/4] statx.2: Document STATX_WRITE_ATOMIC

From: Himanshu Madhani <himanshu.madhani@...cle.com>

Add the text to the statx man page.

Signed-off-by: Himanshu Madhani <himanshu.madhani@...cle.com>
Signed-off-by: John Garry <john.g.garry@...cle.com>
---
 man2/statx.2 | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)

diff --git a/man2/statx.2 b/man2/statx.2
index bcc67c8e3bd3..23b9c6953ec5 100644
--- a/man2/statx.2
+++ b/man2/statx.2
@@ -68,6 +68,9 @@ struct statx {
     /* Direct I/O alignment restrictions */
     __u32 stx_dio_mem_align;
     __u32 stx_dio_offset_align;
+\&
+    __u32 stx_atomic_write_unit_max;
+    __u32 stx_atomic_write_unit_min;
 };
 .EE
 .in
@@ -255,6 +258,8 @@ STATX_ALL	The same as STATX_BASIC_STATS | STATX_BTIME.
 STATX_MNT_ID	Want stx_mnt_id (since Linux 5.8)
 STATX_DIOALIGN	Want stx_dio_mem_align and stx_dio_offset_align
 	(since Linux 6.1; support varies by filesystem)
+STATX_WRITE_ATOMIC	Want stx_atomic_write_unit_min and stx_atomic_write_unit_max
+	(since Linux 6.7; support varies by filesystem)
 .TE
 .in
 .PP
@@ -439,6 +444,16 @@ or 0 if direct I/O is not supported on this file.
 This will only be nonzero if
 .I stx_dio_mem_align
 is nonzero, and vice versa.
+.TP
+.I stx_atomic_write_unit_min
+The minimum size (in bytes) supported for direct I/O
+.RB ( O_DIRECT )
+on the file to be written with torn-write protection. This value is guaranteed to be power-of-2.
+.TP
+.I stx_atomic_write_unit_max
+The maximum size (in bytes) supported for direct I/O
+.RB ( O_DIRECT )
+on the file to be written with torn-write protection. This value is guaranteed to be power-of-2.
 .PP
 For further information on the above fields, see
 .BR inode (7).
@@ -492,6 +507,9 @@ It cannot be written to, and all reads from it will be verified
 against a cryptographic hash that covers the
 entire file (e.g., via a Merkle tree).
 .TP
+.BR STATX_ATTR_WRITE_ATOMIC " (since Linux 6.7)"
+The file supports torn-write protection.
+.TP
 .BR STATX_ATTR_DAX " (since Linux 5.8)"
 The file is in the DAX (cpu direct access) state.
 DAX state attempts to
-- 
2.31.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ