From mboxrd@z Thu Jan 1 00:00:00 1970 From: Sahitya Tummala Subject: Re: [f2fs-dev] [PATCH 1/2] f2fs: report ENOENT correct in f2fs_rename Date: Wed, 19 Sep 2018 06:17:32 +0530 Message-ID: <20180919004732.GF22939@codeaurora.org> References: <20180918021805.85032-1-jaegeuk@kernel.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: <20180918021805.85032-1-jaegeuk@kernel.org> Sender: linux-kernel-owner@vger.kernel.org To: Jaegeuk Kim Cc: linux-kernel@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net List-Id: linux-f2fs-devel.lists.sourceforge.net On Mon, Sep 17, 2018 at 07:18:04PM -0700, Jaegeuk Kim wrote: > This fixes wrong error report in f2fs_rename. I think f2fs_cross_rename() path also needs the same fix? > > Signed-off-by: Jaegeuk Kim > --- > fs/f2fs/namei.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/fs/f2fs/namei.c b/fs/f2fs/namei.c > index 98d3ab7c3ce6..d653be777529 100644 > --- a/fs/f2fs/namei.c > +++ b/fs/f2fs/namei.c > @@ -833,7 +833,7 @@ static int f2fs_rename(struct inode *old_dir, struct dentry *old_dentry, > struct f2fs_dir_entry *old_entry; > struct f2fs_dir_entry *new_entry; > bool is_old_inline = f2fs_has_inline_dentry(old_dir); > - int err = -ENOENT; > + int err; > > if (unlikely(f2fs_cp_error(sbi))) > return -EIO; > @@ -854,6 +854,7 @@ static int f2fs_rename(struct inode *old_dir, struct dentry *old_dentry, > if (err) > goto out; > > + err = -ENOENT; > if (new_inode) { > err = dquot_initialize(new_inode); > if (err) > -- > 2.17.0.441.gb46fe60e1d-goog > > > > _______________________________________________ > Linux-f2fs-devel mailing list > Linux-f2fs-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel -- -- Sent by a consultant of the Qualcomm Innovation Center, Inc. The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.