In the f2fs_unlink we do not add trace end for some
error paths, just add.

Signed-off-by: Lihong Kou <koulih...@huawei.com>
---
 fs/f2fs/namei.c | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/fs/f2fs/namei.c b/fs/f2fs/namei.c
index e94e02c6580a..a15a2831d43b 100644
--- a/fs/f2fs/namei.c
+++ b/fs/f2fs/namei.c
@@ -569,15 +569,17 @@ static int f2fs_unlink(struct inode *dir, struct dentry 
*dentry)
 
        trace_f2fs_unlink_enter(dir, dentry);
 
-       if (unlikely(f2fs_cp_error(sbi)))
-               return -EIO;
+       if (unlikely(f2fs_cp_error(sbi))) {
+               err = -EIO;
+               goto fail;
+       }
 
        err = dquot_initialize(dir);
        if (err)
-               return err;
+               goto fail;
        err = dquot_initialize(inode);
        if (err)
-               return err;
+               goto fail;
 
        de = f2fs_find_entry(dir, &dentry->d_name, &page);
        if (!de) {
-- 
2.17.1



_______________________________________________
Linux-f2fs-devel mailing list
Linux-f2fs-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Reply via email to