[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <fb974a33-2192-30ab-9f31-885c3796360b@oracle.com>
Date: Tue, 11 Jun 2019 08:41:06 -0500
From: Dave Kleikamp <dave.kleikamp@...cle.com>
To: "Darrick J. Wong" <darrick.wong@...cle.com>,
matthew.garrett@...ula.com, yuchao0@...wei.com, tytso@....edu,
shaggy@...nel.org, ard.biesheuvel@...aro.org, josef@...icpanda.com,
clm@...com, adilger.kernel@...ger.ca, jk@...abs.org, jack@...e.com,
dsterba@...e.com, jaegeuk@...nel.org, viro@...iv.linux.org.uk
Cc: linux-xfs@...r.kernel.org, jfs-discussion@...ts.sourceforge.net,
linux-efi@...r.kernel.org, linux-kernel@...r.kernel.org,
reiserfs-devel@...r.kernel.org,
linux-f2fs-devel@...ts.sourceforge.net, cluster-devel@...hat.com,
linux-nilfs@...r.kernel.org, linux-mtd@...ts.infradead.org,
linux-btrfs@...r.kernel.org, linux-fsdevel@...r.kernel.org,
linux-ext4@...r.kernel.org, ocfs2-devel@....oracle.com
Subject: Re: [Jfs-discussion] [PATCH 1/4] vfs: create a generic checking
function for FS_IOC_SETFLAGS
On 6/10/19 11:45 PM, Darrick J. Wong wrote:
> From: Darrick J. Wong <darrick.wong@...cle.com>
>
> Create a generic checking function for the incoming FS_IOC_SETFLAGS flag
> values so that we can standardize the implementations that follow ext4's
> flag values.
>
> Signed-off-by: Darrick J. Wong <darrick.wong@...cle.com>
-- clip --
> diff --git a/fs/jfs/ioctl.c b/fs/jfs/ioctl.c
> index ba34dae8bd9f..c8446d2cd0c7 100644
> --- a/fs/jfs/ioctl.c
> +++ b/fs/jfs/ioctl.c
> @@ -98,6 +98,12 @@ long jfs_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
> /* Lock against other parallel changes of flags */
> inode_lock(inode);
>
> + oldflags = jfs_map_ext2(jfs_inode->mode2 & JFS_FL_USER_VISIBLE,
> + 0);
> + err = vfs_ioc_setflags_check(inode, oldflags, flags);
> + if (err)
> + goto setflags_out;
inode_unlock(inode) is not called on the error path.
> +
> oldflags = jfs_inode->mode2;
>
> /*
This patch leaves jfs's open-coded version of the same check.
Thanks,
Shaggy
Powered by blists - more mailing lists