Commit 78901cfa authored by Chao Yu's avatar Chao Yu Committed by Jaegeuk Kim
Browse files

f2fs: avoid unneeded error handling for revoke_entry_slab allocation



In __f2fs_commit_atomic_write(), we will guarantee success of
revoke_entry_slab allocation, so let's avoid unneeded error handling.

Signed-off-by: default avatarChao Yu <chao.yu@oppo.com>
Signed-off-by: default avatarJaegeuk Kim <jaegeuk@kernel.org>
parent 66d34fcb
Loading
Loading
Loading
Loading
+0 −5
Original line number Diff line number Diff line
@@ -315,11 +315,6 @@ static int __f2fs_commit_atomic_write(struct inode *inode)

			new = f2fs_kmem_cache_alloc(revoke_entry_slab, GFP_NOFS,
							true, NULL);
			if (!new) {
				f2fs_put_dnode(&dn);
				ret = -ENOMEM;
				goto out;
			}

			ret = __replace_atomic_write_block(inode, index, blkaddr,
							&new->old_addr, false);