From 2bca1e2388a8a9e8a3db0daf54fcc124516a3e83 Mon Sep 17 00:00:00 2001 From: Jaegeuk Kim Date: Wed, 25 Feb 2015 19:25:01 -0800 Subject: f2fs: clear page's up-to-date if block was deallocated If page's on-disk block was deallocated, let's remove up-to-date flag to avoid further access with wrong contents. Signed-off-by: Jaegeuk Kim --- fs/f2fs/dir.c | 1 + 1 file changed, 1 insertion(+) (limited to 'fs/f2fs/dir.c') diff --git a/fs/f2fs/dir.c b/fs/f2fs/dir.c index 583896cb5346..590aeef6f85e 100644 --- a/fs/f2fs/dir.c +++ b/fs/f2fs/dir.c @@ -682,6 +682,7 @@ void f2fs_delete_entry(struct f2fs_dir_entry *dentry, struct page *page, if (bit_pos == NR_DENTRY_IN_BLOCK) { truncate_hole(dir, page->index, page->index + 1); clear_page_dirty_for_io(page); + ClearPagePrivate(page); ClearPageUptodate(page); inode_dec_dirty_pages(dir); } -- cgit v1.2.3