From: "Darrick J. Wong" <darrick.wong@oracle.com>
To: Eric Sandeen <sandeen@redhat.com>
Cc: linux-xfs <linux-xfs@vger.kernel.org>
Subject: Re: [PATCH V2 1/5] fs: copy BTRFS_IOC_[SG]ET_FSLABEL to vfs
Date: Mon, 14 May 2018 10:37:45 -0700 [thread overview]
Message-ID: <20180514173745.GD4933@magnolia> (raw)
In-Reply-To: <4d21659d-5b21-81ff-e759-b1f1519f526c@redhat.com>
On Mon, May 14, 2018 at 12:35:18PM -0500, Eric Sandeen wrote:
> This retains 256 chars as the maximum size through the interface, which
> is the btrfs limit and AFAIK exceeds any other filesystem's maximum
> label size.
>
> This just copies the ioctl for now and leaves it in place for btrfs
> for the time being. A later patch will allow btrfs to use the new
> common ioctl definition, but it may be sent after this is merged.
>
> (Note, Reviewed-by's were originally given for the combined vfs+btrfs
> patch, some license taken here.)
>
> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
> Reviewed-by: Andreas Dilger <adilger@dilger.ca>
> Reviewed-by: David Sterba <dsterba@suse.com>
Looks ok, having decided not to fuss about whitespace this time:
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
--D
> ---
> Documentation/ioctl/ioctl-number.txt | 3 ++-
> include/uapi/linux/fs.h | 8 ++++++--
> 2 files changed, 8 insertions(+), 3 deletions(-)
>
> diff --git a/Documentation/ioctl/ioctl-number.txt b/Documentation/ioctl/ioctl-number.txt
> index 7f7413e597f3..27c1b7b78504 100644
> --- a/Documentation/ioctl/ioctl-number.txt
> +++ b/Documentation/ioctl/ioctl-number.txt
> @@ -296,7 +296,8 @@ Code Seq#(hex) Include File Comments
> 0x90 00 drivers/cdrom/sbpcd.h
> 0x92 00-0F drivers/usb/mon/mon_bin.c
> 0x93 60-7F linux/auto_fs.h
> -0x94 all fs/btrfs/ioctl.h
> +0x94 all fs/btrfs/ioctl.h Btrfs filesystem
> + and linux/fs.h some lifted to vfs/generic
> 0x97 00-7F fs/ceph/ioctl.h Ceph file system
> 0x99 00-0F 537-Addinboard driver
> <mailto:buk@buks.ipn.de>
> diff --git a/include/uapi/linux/fs.h b/include/uapi/linux/fs.h
> index d2a8313fabd7..9d132f8f2df8 100644
> --- a/include/uapi/linux/fs.h
> +++ b/include/uapi/linux/fs.h
> @@ -242,6 +242,8 @@ struct fsxattr {
> #define FICLONERANGE _IOW(0x94, 13, struct file_clone_range)
> #define FIDEDUPERANGE _IOWR(0x94, 54, struct file_dedupe_range)
>
> +#define FSLABEL_MAX 256 /* Max chars for the interface; each fs may differ */
> +
> #define FS_IOC_GETFLAGS _IOR('f', 1, long)
> #define FS_IOC_SETFLAGS _IOW('f', 2, long)
> #define FS_IOC_GETVERSION _IOR('v', 1, long)
> @@ -251,8 +253,10 @@ struct fsxattr {
> #define FS_IOC32_SETFLAGS _IOW('f', 2, int)
> #define FS_IOC32_GETVERSION _IOR('v', 1, int)
> #define FS_IOC32_SETVERSION _IOW('v', 2, int)
> -#define FS_IOC_FSGETXATTR _IOR ('X', 31, struct fsxattr)
> -#define FS_IOC_FSSETXATTR _IOW ('X', 32, struct fsxattr)
> +#define FS_IOC_FSGETXATTR _IOR('X', 31, struct fsxattr)
> +#define FS_IOC_FSSETXATTR _IOW('X', 32, struct fsxattr)
> +#define FS_IOC_GETFSLABEL _IOR(0x94, 49, char[FSLABEL_MAX])
> +#define FS_IOC_SETFSLABEL _IOW(0x94, 50, char[FSLABEL_MAX])
>
> /*
> * File system encryption support
> --
> 2.17.0
>
> --
> 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-05-14 17:38 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-14 17:30 [PATCH V2 0/5] xfs: online label Eric Sandeen
2018-05-14 17:35 ` [PATCH V2 1/5] fs: copy BTRFS_IOC_[SG]ET_FSLABEL to vfs Eric Sandeen
2018-05-14 17:37 ` Darrick J. Wong [this message]
2018-05-14 17:36 ` [PATCH 2/4] xfs: New function for secondary superblock updates Eric Sandeen
2018-05-15 20:17 ` Darrick J. Wong
2018-05-14 17:39 ` [PATCH 3/5 V2] xfs: implement online get/set fs label Eric Sandeen
2018-05-15 1:07 ` Darrick J. Wong
2018-05-16 1:04 ` Darrick J. Wong
2018-05-14 17:42 ` [PATCH 4/5] btrfs: use common label ioctl definitions Eric Sandeen
2018-05-14 21:41 ` Darrick J. Wong
2018-05-14 17:43 ` [PATCH 5/5] xfs_io: add label command Eric Sandeen
2018-05-15 4:32 ` Dave Chinner
2018-05-15 15:06 ` Eric Sandeen
2018-05-16 0:57 ` Dave Chinner
2018-05-15 15:32 ` [PATCH 5/5 V2] " Eric Sandeen
2018-05-15 20:12 ` Darrick J. Wong
2018-05-17 15:22 ` [PATCH 5/5 V3] " Eric Sandeen
2018-05-17 21:56 ` Dave Chinner
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=20180514173745.GD4933@magnolia \
--to=darrick.wong@oracle.com \
--cc=linux-xfs@vger.kernel.org \
--cc=sandeen@redhat.com \
/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).