From: "Darrick J. Wong" <djwong@kernel.org>
To: Christoph Hellwig <hch@lst.de>
Cc: Alexander Viro <viro@zeniv.linux.org.uk>,
Christian Brauner <brauner@kernel.org>, Jan Kara <jack@suse.cz>,
Chandan Babu R <chandan.babu@oracle.com>,
Hongbo Li <lihongbo22@huawei.com>,
Ryusuke Konishi <konishi.ryusuke@gmail.com>,
linux-nilfs@vger.kernel.org, linux-fsdevel@vger.kernel.org,
linux-xfs@vger.kernel.org
Subject: Re: [PATCH 1/3] fs: reformat the statx definition
Date: Wed, 28 Aug 2024 09:20:11 -0700 [thread overview]
Message-ID: <20240828162011.GK1977952@frogsfrogsfrogs> (raw)
In-Reply-To: <20240828051149.1897291-2-hch@lst.de>
On Wed, Aug 28, 2024 at 08:11:01AM +0300, Christoph Hellwig wrote:
> The comments after the declaration are becoming rather unreadable with
> long enough comments. Move them into lines of their own.
>
> Signed-off-by: Christoph Hellwig <hch@lst.de>
Space for full sentences, what luxury! ;)
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
--D
> ---
> include/uapi/linux/stat.h | 95 +++++++++++++++++++++++++++++----------
> 1 file changed, 72 insertions(+), 23 deletions(-)
>
> diff --git a/include/uapi/linux/stat.h b/include/uapi/linux/stat.h
> index 887a2528644168..8b35d7d511a287 100644
> --- a/include/uapi/linux/stat.h
> +++ b/include/uapi/linux/stat.h
> @@ -98,43 +98,92 @@ struct statx_timestamp {
> */
> struct statx {
> /* 0x00 */
> - __u32 stx_mask; /* What results were written [uncond] */
> - __u32 stx_blksize; /* Preferred general I/O size [uncond] */
> - __u64 stx_attributes; /* Flags conveying information about the file [uncond] */
> + /* What results were written [uncond] */
> + __u32 stx_mask;
> +
> + /* Preferred general I/O size [uncond] */
> + __u32 stx_blksize;
> +
> + /* Flags conveying information about the file [uncond] */
> + __u64 stx_attributes;
> +
> /* 0x10 */
> - __u32 stx_nlink; /* Number of hard links */
> - __u32 stx_uid; /* User ID of owner */
> - __u32 stx_gid; /* Group ID of owner */
> - __u16 stx_mode; /* File mode */
> + /* Number of hard links */
> + __u32 stx_nlink;
> +
> + /* User ID of owner */
> + __u32 stx_uid;
> +
> + /* Group ID of owner */
> + __u32 stx_gid;
> +
> + /* File mode */
> + __u16 stx_mode;
> __u16 __spare0[1];
> +
> /* 0x20 */
> - __u64 stx_ino; /* Inode number */
> - __u64 stx_size; /* File size */
> - __u64 stx_blocks; /* Number of 512-byte blocks allocated */
> - __u64 stx_attributes_mask; /* Mask to show what's supported in stx_attributes */
> + /* Inode number */
> + __u64 stx_ino;
> +
> + /* File size */
> + __u64 stx_size;
> +
> + /* Number of 512-byte blocks allocated */
> + __u64 stx_blocks;
> +
> + /* Mask to show what's supported in stx_attributes */
> + __u64 stx_attributes_mask;
> +
> /* 0x40 */
> - struct statx_timestamp stx_atime; /* Last access time */
> - struct statx_timestamp stx_btime; /* File creation time */
> - struct statx_timestamp stx_ctime; /* Last attribute change time */
> - struct statx_timestamp stx_mtime; /* Last data modification time */
> + /* Last access time */
> + struct statx_timestamp stx_atime;
> +
> + /* File creation time */
> + struct statx_timestamp stx_btime;
> +
> + /* Last attribute change time */
> + struct statx_timestamp stx_ctime;
> +
> + /* Last data modification time */
> + struct statx_timestamp stx_mtime;
> +
> /* 0x80 */
> - __u32 stx_rdev_major; /* Device ID of special file [if bdev/cdev] */
> + /* Device ID of special file [if bdev/cdev] */
> + __u32 stx_rdev_major;
> __u32 stx_rdev_minor;
> - __u32 stx_dev_major; /* ID of device containing file [uncond] */
> +
> + /* ID of device containing file [uncond] */
> + __u32 stx_dev_major;
> __u32 stx_dev_minor;
> +
> /* 0x90 */
> __u64 stx_mnt_id;
> - __u32 stx_dio_mem_align; /* Memory buffer alignment for direct I/O */
> - __u32 stx_dio_offset_align; /* File offset alignment for direct I/O */
> +
> + /* Memory buffer alignment for direct I/O */
> + __u32 stx_dio_mem_align;
> +
> + /* File offset alignment for direct I/O */
> + __u32 stx_dio_offset_align;
> +
> /* 0xa0 */
> - __u64 stx_subvol; /* Subvolume identifier */
> - __u32 stx_atomic_write_unit_min; /* Min atomic write unit in bytes */
> - __u32 stx_atomic_write_unit_max; /* Max atomic write unit in bytes */
> + /* Subvolume identifier */
> + __u64 stx_subvol;
> +
> + /* Min atomic write unit in bytes */
> + __u32 stx_atomic_write_unit_min;
> +
> + /* Max atomic write unit in bytes */
> + __u32 stx_atomic_write_unit_max;
> +
> /* 0xb0 */
> - __u32 stx_atomic_write_segments_max; /* Max atomic write segment count */
> + /* Max atomic write segment count */
> + __u32 stx_atomic_write_segments_max;
> +
> __u32 __spare1[1];
> +
> /* 0xb8 */
> __u64 __spare3[9]; /* Spare space for future expansion */
> +
> /* 0x100 */
> };
>
> --
> 2.43.0
>
>
next prev parent reply other threads:[~2024-08-28 16:20 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-28 5:11 RFC: add STATX_DIO_READ_ALIGN Christoph Hellwig
2024-08-28 5:11 ` [PATCH 1/3] fs: reformat the statx definition Christoph Hellwig
2024-08-28 16:20 ` Darrick J. Wong [this message]
2024-08-28 5:11 ` [PATCH 2/3] fs: add STATX_DIO_READ_ALIGN Christoph Hellwig
2024-08-28 16:24 ` Darrick J. Wong
2024-08-28 23:52 ` Eric Biggers
2024-08-29 3:44 ` Christoph Hellwig
2024-08-28 5:11 ` [PATCH 3/3] xfs: report the correct read/write dio alignment for reflinked inodes Christoph Hellwig
2024-08-28 16:23 ` Darrick J. Wong
2024-08-29 1:13 ` Dave Chinner
2024-08-28 13:43 ` RFC: add STATX_DIO_READ_ALIGN Christian Brauner
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=20240828162011.GK1977952@frogsfrogsfrogs \
--to=djwong@kernel.org \
--cc=brauner@kernel.org \
--cc=chandan.babu@oracle.com \
--cc=hch@lst.de \
--cc=jack@suse.cz \
--cc=konishi.ryusuke@gmail.com \
--cc=lihongbo22@huawei.com \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-nilfs@vger.kernel.org \
--cc=linux-xfs@vger.kernel.org \
--cc=viro@zeniv.linux.org.uk \
/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).