• Home
  • Raw
  • Download

Lines Matching refs:fi

70 	struct f2fs_inode_info *fi = F2FS_I(inode);  in check_extent_cache()  local
75 read_lock(&fi->ext.ext_lock); in check_extent_cache()
76 if (fi->ext.len == 0) { in check_extent_cache()
77 read_unlock(&fi->ext.ext_lock); in check_extent_cache()
82 start_fofs = fi->ext.fofs; in check_extent_cache()
83 end_fofs = fi->ext.fofs + fi->ext.len - 1; in check_extent_cache()
84 start_blkaddr = fi->ext.blk_addr; in check_extent_cache()
100 read_unlock(&fi->ext.ext_lock); in check_extent_cache()
103 read_unlock(&fi->ext.ext_lock); in check_extent_cache()
109 struct f2fs_inode_info *fi = F2FS_I(dn->inode); in update_extent_cache() local
119 write_lock(&fi->ext.ext_lock); in update_extent_cache()
121 start_fofs = fi->ext.fofs; in update_extent_cache()
122 end_fofs = fi->ext.fofs + fi->ext.len - 1; in update_extent_cache()
123 start_blkaddr = fi->ext.blk_addr; in update_extent_cache()
124 end_blkaddr = fi->ext.blk_addr + fi->ext.len - 1; in update_extent_cache()
127 if (fi->ext.len == 1 && fofs == start_fofs) in update_extent_cache()
128 fi->ext.len = 0; in update_extent_cache()
131 if (fi->ext.len == 0) { in update_extent_cache()
133 fi->ext.fofs = fofs; in update_extent_cache()
134 fi->ext.blk_addr = blk_addr; in update_extent_cache()
135 fi->ext.len = 1; in update_extent_cache()
142 fi->ext.fofs--; in update_extent_cache()
143 fi->ext.blk_addr--; in update_extent_cache()
144 fi->ext.len++; in update_extent_cache()
150 fi->ext.len++; in update_extent_cache()
155 if (fi->ext.len > 1 && in update_extent_cache()
157 if ((end_fofs - fofs) < (fi->ext.len >> 1)) { in update_extent_cache()
158 fi->ext.len = fofs - start_fofs; in update_extent_cache()
160 fi->ext.fofs = fofs + 1; in update_extent_cache()
161 fi->ext.blk_addr = start_blkaddr + in update_extent_cache()
163 fi->ext.len -= fofs - start_fofs + 1; in update_extent_cache()
167 write_unlock(&fi->ext.ext_lock); in update_extent_cache()
171 write_unlock(&fi->ext.ext_lock); in update_extent_cache()