Lines Matching defs:secno
81 #define GET_SEG_FROM_SEC(sbi, secno) \
82 ((secno) * SEGS_PER_SEC(sbi))
83 #define GET_ZONE_FROM_SEC(sbi, secno) \
84 (((secno) == -1) ? -1 : (secno) / (sbi)->secs_per_zone)
304 static inline bool is_cursec(struct f2fs_sb_info *sbi, unsigned int secno)
309 if (secno == GET_SEC_FROM_SEG(sbi, CURSEG_I(sbi, i)->segno))
354 unsigned int secno = GET_SEC_FROM_SEG(sbi, segno);
355 unsigned int start_segno = GET_SEG_FROM_SEC(sbi, secno);
371 unsigned int secno = GET_SEC_FROM_SEG(sbi, segno);
372 unsigned int start_segno = GET_SEG_FROM_SEC(sbi, secno);
385 "seg entry(%d) vs sec entry(%d) at secno %d",
386 blocks, get_sec_entry(sbi, segno)->ckpt_valid_blocks, secno);
461 unsigned int secno = GET_SEC_FROM_SEG(sbi, segno);
462 unsigned int start_segno = GET_SEG_FROM_SEC(sbi, secno);
472 clear_bit(secno, free_i->free_secmap);
482 unsigned int secno = GET_SEC_FROM_SEG(sbi, segno);
486 if (!test_and_set_bit(secno, free_i->free_secmap))
494 unsigned int secno = GET_SEC_FROM_SEG(sbi, segno);
495 unsigned int start_segno = GET_SEG_FROM_SEC(sbi, secno);
506 if (!inmem && is_cursec(sbi, secno))
515 ret = test_and_clear_bit(secno, free_i->free_secmap);
521 if (GET_SEC_FROM_SEG(sbi, sbi->next_victim_seg[BG_GC]) == secno)
523 if (GET_SEC_FROM_SEG(sbi, sbi->next_victim_seg[FG_GC]) == secno)
534 unsigned int secno = GET_SEC_FROM_SEG(sbi, segno);
539 if (!test_and_set_bit(secno, free_i->free_secmap))
980 static inline bool sec_usage_check(struct f2fs_sb_info *sbi, unsigned int secno)
982 if (is_cursec(sbi, secno) || (sbi->cur_victim_sec == secno))