Loading fs/f2fs/extent_cache.c +7 −5 Original line number Diff line number Diff line Loading @@ -243,9 +243,10 @@ static bool f2fs_lookup_extent_tree(struct inode *inode, pgoff_t pgofs, if (en) { *ei = en->ei; spin_lock(&sbi->extent_lock); if (!list_empty(&en->list)) if (!list_empty(&en->list)) { list_move_tail(&en->list, &sbi->extent_list); et->cached_en = en; } spin_unlock(&sbi->extent_lock); ret = true; } Loading Loading @@ -364,11 +365,12 @@ static struct extent_node *__try_merge_extent_node(struct f2fs_sb_info *sbi, return NULL; __try_update_largest_extent(et, en); et->cached_en = en; spin_lock(&sbi->extent_lock); if (!list_empty(&en->list)) if (!list_empty(&en->list)) { list_move_tail(&en->list, &sbi->extent_list); et->cached_en = en; } spin_unlock(&sbi->extent_lock); return en; } Loading Loading @@ -405,11 +407,11 @@ static struct extent_node *__insert_extent_tree(struct f2fs_sb_info *sbi, return NULL; __try_update_largest_extent(et, en); et->cached_en = en; /* update in global extent list */ spin_lock(&sbi->extent_lock); list_add_tail(&en->list, &sbi->extent_list); et->cached_en = en; spin_unlock(&sbi->extent_lock); return en; } Loading Loading
fs/f2fs/extent_cache.c +7 −5 Original line number Diff line number Diff line Loading @@ -243,9 +243,10 @@ static bool f2fs_lookup_extent_tree(struct inode *inode, pgoff_t pgofs, if (en) { *ei = en->ei; spin_lock(&sbi->extent_lock); if (!list_empty(&en->list)) if (!list_empty(&en->list)) { list_move_tail(&en->list, &sbi->extent_list); et->cached_en = en; } spin_unlock(&sbi->extent_lock); ret = true; } Loading Loading @@ -364,11 +365,12 @@ static struct extent_node *__try_merge_extent_node(struct f2fs_sb_info *sbi, return NULL; __try_update_largest_extent(et, en); et->cached_en = en; spin_lock(&sbi->extent_lock); if (!list_empty(&en->list)) if (!list_empty(&en->list)) { list_move_tail(&en->list, &sbi->extent_list); et->cached_en = en; } spin_unlock(&sbi->extent_lock); return en; } Loading Loading @@ -405,11 +407,11 @@ static struct extent_node *__insert_extent_tree(struct f2fs_sb_info *sbi, return NULL; __try_update_largest_extent(et, en); et->cached_en = en; /* update in global extent list */ spin_lock(&sbi->extent_lock); list_add_tail(&en->list, &sbi->extent_list); et->cached_en = en; spin_unlock(&sbi->extent_lock); return en; } Loading