Lines Matching defs:f2fs_sb_info
1171 struct f2fs_sb_info { struct
1172 struct super_block *sb; /* pointer to VFS super block */
1173 struct proc_dir_entry *s_proc; /* proc entry */
1174 struct f2fs_super_block *raw_super; /* raw super block pointer */
1175 struct rw_semaphore sb_lock; /* lock for raw super block */
1176 int valid_super_block; /* valid super block no */
1177 unsigned long s_flag; /* flags for sbi */
1178 struct mutex writepages; /* mutex for writepages() */
1180 struct unicode_map *s_encoding;
1181 __u16 s_encoding_flags;
1185 unsigned int blocks_per_blkz; /* F2FS blocks per zone */
1186 unsigned int log_blocks_per_blkz; /* log2 F2FS blocks per zone */
1190 struct f2fs_nm_info *nm_info; /* node manager */
1191 struct inode *node_inode; /* cache node blocks */
1194 struct f2fs_sm_info *sm_info; /* segment manager */
1197 struct f2fs_bio_info *write_io[NR_PAGE_TYPE]; /* for write bios */
1199 struct rw_semaphore io_order_lock;
1200 mempool_t *write_io_dummy; /* Dummy pages */
1203 struct f2fs_checkpoint *ckpt; /* raw checkpoint pointer */
1204 int cur_cp_pack; /* remain current cp pack */
1205 spinlock_t cp_lock; /* for flag in ckpt */
1206 struct inode *meta_inode; /* cache meta blocks */
1207 struct mutex cp_mutex; /* checkpoint procedure lock */
1208 struct rw_semaphore cp_rwsem; /* blocking FS operations */
1209 struct rw_semaphore node_write; /* locking node writes */
1210 struct rw_semaphore node_change; /* locking node change */
1211 wait_queue_head_t cp_wait;
1212 unsigned long last_time[MAX_TIME]; /* to store time in jiffies */
1213 long interval_time[MAX_TIME]; /* to store thresholds */
1215 struct inode_management im[MAX_INO_ENTRY]; /* manage inode cache */
1217 spinlock_t fsync_node_lock; /* for node entry lock */
1218 struct list_head fsync_node_list; /* node list head */
1219 unsigned int fsync_seg_id; /* sequence id */
1220 unsigned int fsync_node_num; /* number of node entries */
1223 unsigned int max_orphans; /* max orphan inodes */
1226 struct list_head inode_list[NR_INODE_TYPE]; /* dirty inode list */
1227 spinlock_t inode_lock[NR_INODE_TYPE]; /* for dirty inode list lock */
1228 struct mutex flush_lock; /* for flush exclusion */
1231 struct radix_tree_root extent_tree_root;/* cache extent cache entries */
1232 struct mutex extent_tree_lock; /* locking extent radix tree */
1233 struct list_head extent_list; /* lru list for shrinker */
1234 spinlock_t extent_lock; /* locking extent lru list */
1235 atomic_t total_ext_tree; /* extent tree count */
1236 struct list_head zombie_list; /* extent zombie tree list */
1237 atomic_t total_zombie_tree; /* extent zombie tree count */
1238 atomic_t total_ext_node; /* extent info count */
1241 unsigned int log_sectors_per_block; /* log2 sectors per block */
1242 unsigned int log_blocksize; /* log2 block size */
1243 unsigned int blocksize; /* block size */
1244 unsigned int root_ino_num; /* root inode number*/
1245 unsigned int node_ino_num; /* node inode number*/
1246 unsigned int meta_ino_num; /* meta inode number*/
1247 unsigned int log_blocks_per_seg; /* log2 blocks per segment */
1248 unsigned int blocks_per_seg; /* blocks per segment */
1249 unsigned int segs_per_sec; /* segments per section */
1250 unsigned int secs_per_zone; /* sections per zone */
1251 unsigned int total_sections; /* total section count */
1252 struct mutex resize_mutex; /* for resize exclusion */
1253 unsigned int total_node_count; /* total node block count */
1254 unsigned int total_valid_node_count; /* valid node block count */
1255 loff_t max_file_blocks; /* max block index of file */
1256 int dir_level; /* directory level */
1257 int readdir_ra; /* readahead inode in readdir */
1259 block_t user_block_count; /* # of user blocks */
1260 block_t total_valid_block_count; /* # of valid blocks */
1261 block_t discard_blks; /* discard command candidats */
1262 block_t last_valid_block_count; /* for recovery */
1263 block_t reserved_blocks; /* configurable reserved blocks */
1264 block_t current_reserved_blocks; /* current reserved blocks */
1267 block_t unusable_block_count; /* # of blocks saved by last cp */
1269 unsigned int nquota_files; /* # of quota sysfile */
1270 struct rw_semaphore quota_sem; /* blocking cp for flags */
1273 atomic_t nr_pages[NR_COUNT_TYPE];
1275 struct percpu_counter alloc_valid_block_count;
1278 atomic_t wb_sync_req[META]; /* count # of WB_SYNC threads */
1281 struct percpu_counter total_valid_inode_count;
1283 struct f2fs_mount_info mount_opt; /* mount options */
1286 struct mutex gc_mutex; /* mutex for GC */
1287 struct f2fs_gc_kthread *gc_thread; /* GC thread */
1288 unsigned int cur_victim_sec; /* current victim section num */
1289 unsigned int gc_mode; /* current GC state */
1290 unsigned int next_victim_seg[2]; /* next segment in victim section */
1292 unsigned long long skipped_atomic_files[2]; /* FG_GC and BG_GC */
1293 unsigned long long skipped_gc_rwsem; /* FG_GC only */
1296 u64 gc_pin_file_threshold;
1299 unsigned int max_victim_search;
1301 unsigned int migration_granularity;
1308 struct f2fs_stat_info *stat_info; /* FS status information */
1309 atomic_t meta_count[META_MAX]; /* # of meta blocks */
1310 unsigned int segment_count[2]; /* # of allocated segments */
1311 unsigned int block_count[2]; /* # of allocated blocks */
1312 atomic_t inplace_count; /* # of inplace update */
1313 atomic64_t total_hit_ext; /* # of lookup extent cache */
1314 atomic64_t read_hit_rbtree; /* # of hit rbtree extent node */
1315 atomic64_t read_hit_largest; /* # of hit largest extent node */
1316 atomic64_t read_hit_cached; /* # of hit cached extent node */
1317 atomic_t inline_xattr; /* # of inline_xattr inodes */
1318 atomic_t inline_inode; /* # of inline_data inodes */
1319 atomic_t inline_dir; /* # of inline_dentry inodes */
1320 atomic_t aw_cnt; /* # of atomic writes */
1321 atomic_t vw_cnt; /* # of volatile writes */
1322 atomic_t max_aw_cnt; /* max # of atomic writes */
1323 atomic_t max_vw_cnt; /* max # of volatile writes */
1324 int bg_gc; /* background gc calls */
1325 unsigned int io_skip_bggc; /* skip background gc for in-flight IO */
1326 unsigned int other_skip_bggc; /* skip background gc for other reasons */
1327 unsigned int ndirty_inode[NR_INODE_TYPE]; /* # of dirty inodes */
1329 spinlock_t stat_lock; /* lock for stat operations */
1332 spinlock_t iostat_lock;
1333 unsigned long long write_iostat[NR_IO_TYPE];
1334 bool iostat_enable;
1337 struct kobject s_kobj;
1338 struct completion s_kobj_unregister;
1341 struct list_head s_list;
1342 int s_ndevs; /* number of devices */
1343 struct f2fs_dev_info *devs; /* for device list */
1344 unsigned int dirty_device; /* for checkpoint data flush */
1345 spinlock_t dev_lock; /* protect dirty_device */
1346 struct mutex umount_mutex;
1347 unsigned int shrinker_run_no;
1372 static inline bool time_to_inject(struct f2fs_sb_info *sbi, int type) in time_to_inject() argument