f2fs: use list_for_each_entry{_safe} for simplyfying code
[deliverable/linux.git] / fs / f2fs / recovery.c
index bbef4ed157a77bd349c16c1da2c58f9116e546b9..b1ae89f0f44e53878a7e37aea926c4e3a201c2a3 100644 (file)
@@ -27,14 +27,12 @@ bool space_for_roll_forward(struct f2fs_sb_info *sbi)
 static struct fsync_inode_entry *get_fsync_inode(struct list_head *head,
                                                                nid_t ino)
 {
-       struct list_head *this;
        struct fsync_inode_entry *entry;
 
-       list_for_each(this, head) {
-               entry = list_entry(this, struct fsync_inode_entry, list);
+       list_for_each_entry(entry, head, list)
                if (entry->inode->i_ino == ino)
                        return entry;
-       }
+
        return NULL;
 }
 
This page took 0.025403 seconds and 5 git commands to generate.