summaryrefslogtreecommitdiffstats
path: root/fs/f2fs/node.h
diff options
context:
space:
mode:
authorChao Yu <yuchao0@huawei.com>2017-01-07 11:49:42 +0100
committerJaegeuk Kim <jaegeuk@kernel.org>2017-02-23 03:48:47 +0100
commit939afa943c5290a3b92f01612a792af17bc98115 (patch)
treeafc43ca858904e231a5033800ae9c41c9f98027e /fs/f2fs/node.h
parentf2fs: return fs_trim if there is no candidate (diff)
downloadlinux-939afa943c5290a3b92f01612a792af17bc98115.tar.xz
linux-939afa943c5290a3b92f01612a792af17bc98115.zip
f2fs: clean up with list_{first, last}_entry
Signed-off-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/node.h')
-rw-r--r--fs/f2fs/node.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/f2fs/node.h b/fs/f2fs/node.h
index e7997e240366..9278b21ee073 100644
--- a/fs/f2fs/node.h
+++ b/fs/f2fs/node.h
@@ -174,7 +174,7 @@ static inline void next_free_nid(struct f2fs_sb_info *sbi, nid_t *nid)
spin_unlock(&nm_i->nid_list_lock);
return;
}
- fnid = list_entry(nm_i->nid_list[FREE_NID_LIST].next,
+ fnid = list_first_entry(&nm_i->nid_list[FREE_NID_LIST],
struct free_nid, list);
*nid = fnid->nid;
spin_unlock(&nm_i->nid_list_lock);