[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1362195663-20751-1-git-send-email-linkinjeon@gmail.com>
Date: Sat, 2 Mar 2013 12:41:03 +0900
From: Namjae Jeon <linkinjeon@...il.com>
To: jaegeuk.kim@...sung.com
Cc: linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-f2fs-devel@...ts.sourceforge.net,
Namjae Jeon <linkinjeon@...il.com>,
Namjae Jeon <namjae.jeon@...sung.com>,
Amit Sahrawat <a.sahrawat@...sung.com>
Subject: [PATCH 3/5] f2fs: move f2fs_balance_fs to correct place in unlink
From: Namjae Jeon <namjae.jeon@...sung.com>
Actual dirty of pages will occur in f2fs_delete_entry so move the
f2fs_balance_fs just before deletion.
Signed-off-by: Namjae Jeon <namjae.jeon@...sung.com>
Signed-off-by: Amit Sahrawat <a.sahrawat@...sung.com>
---
fs/f2fs/namei.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/f2fs/namei.c b/fs/f2fs/namei.c
index 1a49b88..eaa86f5 100644
--- a/fs/f2fs/namei.c
+++ b/fs/f2fs/namei.c
@@ -223,8 +223,6 @@ static int f2fs_unlink(struct inode *dir, struct dentry *dentry)
struct page *page;
int err = -ENOENT;
- f2fs_balance_fs(sbi);
-
de = f2fs_find_entry(dir, &dentry->d_name, &page);
if (!de)
goto fail;
@@ -236,6 +234,8 @@ static int f2fs_unlink(struct inode *dir, struct dentry *dentry)
goto fail;
}
+ f2fs_balance_fs(sbi);
+
f2fs_delete_entry(de, page, inode);
/* In order to evict this inode, we set it dirty */
--
1.7.9.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists