• Home
  • Raw
  • Download

Lines Matching refs:cno

41 nilfs_cpfile_get_blkoff(const struct inode *cpfile, __u64 cno)  in nilfs_cpfile_get_blkoff()  argument
43 __u64 tcno = cno + NILFS_MDT(cpfile)->mi_first_entry_offset - 1; in nilfs_cpfile_get_blkoff()
50 nilfs_cpfile_get_offset(const struct inode *cpfile, __u64 cno) in nilfs_cpfile_get_offset() argument
52 __u64 tcno = cno + NILFS_MDT(cpfile)->mi_first_entry_offset - 1; in nilfs_cpfile_get_offset()
68 __u64 cno) in nilfs_cpfile_is_in_first() argument
70 return nilfs_cpfile_get_blkoff(cpfile, cno) == 0; in nilfs_cpfile_is_in_first()
111 nilfs_cpfile_block_get_checkpoint(const struct inode *cpfile, __u64 cno, in nilfs_cpfile_block_get_checkpoint() argument
115 return kaddr + bh_offset(bh) + nilfs_cpfile_get_offset(cpfile, cno) * in nilfs_cpfile_block_get_checkpoint()
140 __u64 cno, in nilfs_cpfile_get_checkpoint_block() argument
145 nilfs_cpfile_get_blkoff(cpfile, cno), in nilfs_cpfile_get_checkpoint_block()
150 __u64 cno) in nilfs_cpfile_delete_checkpoint_block() argument
153 nilfs_cpfile_get_blkoff(cpfile, cno)); in nilfs_cpfile_delete_checkpoint_block()
182 __u64 cno, in nilfs_cpfile_get_checkpoint() argument
193 if (unlikely(cno < 1 || cno > nilfs_mdt_cno(cpfile) || in nilfs_cpfile_get_checkpoint()
194 (cno < nilfs_mdt_cno(cpfile) && create))) in nilfs_cpfile_get_checkpoint()
202 ret = nilfs_cpfile_get_checkpoint_block(cpfile, cno, create, &cp_bh); in nilfs_cpfile_get_checkpoint()
206 cp = nilfs_cpfile_block_get_checkpoint(cpfile, cno, cp_bh, kaddr); in nilfs_cpfile_get_checkpoint()
216 if (!nilfs_cpfile_is_in_first(cpfile, cno)) in nilfs_cpfile_get_checkpoint()
252 void nilfs_cpfile_put_checkpoint(struct inode *cpfile, __u64 cno, in nilfs_cpfile_put_checkpoint() argument
286 __u64 cno; in nilfs_cpfile_delete_checkpoints() local
305 for (cno = start; cno < end; cno += ncps) { in nilfs_cpfile_delete_checkpoints()
306 ncps = nilfs_cpfile_checkpoints_in_block(cpfile, cno, end); in nilfs_cpfile_delete_checkpoints()
307 ret = nilfs_cpfile_get_checkpoint_block(cpfile, cno, 0, &cp_bh); in nilfs_cpfile_delete_checkpoints()
318 cpfile, cno, cp_bh, kaddr); in nilfs_cpfile_delete_checkpoints()
331 if (!nilfs_cpfile_is_in_first(cpfile, cno)) { in nilfs_cpfile_delete_checkpoints()
341 cpfile, cno); in nilfs_cpfile_delete_checkpoints()
393 __u64 cur_cno = nilfs_mdt_cno(cpfile), cno = *cnop; in nilfs_cpfile_do_get_cpinfo() local
398 if (cno == 0) in nilfs_cpfile_do_get_cpinfo()
402 for (n = 0; cno < cur_cno && n < nci; cno += ncps) { in nilfs_cpfile_do_get_cpinfo()
403 ncps = nilfs_cpfile_checkpoints_in_block(cpfile, cno, cur_cno); in nilfs_cpfile_do_get_cpinfo()
404 ret = nilfs_cpfile_get_checkpoint_block(cpfile, cno, 0, &bh); in nilfs_cpfile_do_get_cpinfo()
412 cp = nilfs_cpfile_block_get_checkpoint(cpfile, cno, bh, kaddr); in nilfs_cpfile_do_get_cpinfo()
540 int nilfs_cpfile_delete_checkpoint(struct inode *cpfile, __u64 cno) in nilfs_cpfile_delete_checkpoint() argument
543 __u64 tcno = cno; in nilfs_cpfile_delete_checkpoint()
549 else if (nci == 0 || ci.ci_cno != cno) in nilfs_cpfile_delete_checkpoint()
554 return nilfs_cpfile_delete_checkpoints(cpfile, cno, cno + 1); in nilfs_cpfile_delete_checkpoint()
559 __u64 cno, in nilfs_cpfile_block_get_snapshot_list() argument
567 if (cno != 0) { in nilfs_cpfile_block_get_snapshot_list()
568 cp = nilfs_cpfile_block_get_checkpoint(cpfile, cno, bh, kaddr); in nilfs_cpfile_block_get_snapshot_list()
577 static int nilfs_cpfile_set_snapshot(struct inode *cpfile, __u64 cno) in nilfs_cpfile_set_snapshot() argument
588 if (cno == 0) in nilfs_cpfile_set_snapshot()
592 ret = nilfs_cpfile_get_checkpoint_block(cpfile, cno, 0, &cp_bh); in nilfs_cpfile_set_snapshot()
596 cp = nilfs_cpfile_block_get_checkpoint(cpfile, cno, cp_bh, kaddr); in nilfs_cpfile_set_snapshot()
620 while (prev > cno) { in nilfs_cpfile_set_snapshot()
653 list->ssl_prev = cpu_to_le64(cno); in nilfs_cpfile_set_snapshot()
657 cp = nilfs_cpfile_block_get_checkpoint(cpfile, cno, cp_bh, kaddr); in nilfs_cpfile_set_snapshot()
666 list->ssl_next = cpu_to_le64(cno); in nilfs_cpfile_set_snapshot()
696 static int nilfs_cpfile_clear_snapshot(struct inode *cpfile, __u64 cno) in nilfs_cpfile_clear_snapshot() argument
706 if (cno == 0) in nilfs_cpfile_clear_snapshot()
710 ret = nilfs_cpfile_get_checkpoint_block(cpfile, cno, 0, &cp_bh); in nilfs_cpfile_clear_snapshot()
714 cp = nilfs_cpfile_block_get_checkpoint(cpfile, cno, cp_bh, kaddr); in nilfs_cpfile_clear_snapshot()
766 cp = nilfs_cpfile_block_get_checkpoint(cpfile, cno, cp_bh, kaddr); in nilfs_cpfile_clear_snapshot()
816 int nilfs_cpfile_is_snapshot(struct inode *cpfile, __u64 cno) in nilfs_cpfile_is_snapshot() argument
825 if (cno == 0 || cno >= nilfs_mdt_cno(cpfile)) in nilfs_cpfile_is_snapshot()
829 ret = nilfs_cpfile_get_checkpoint_block(cpfile, cno, 0, &bh); in nilfs_cpfile_is_snapshot()
833 cp = nilfs_cpfile_block_get_checkpoint(cpfile, cno, bh, kaddr); in nilfs_cpfile_is_snapshot()
864 int nilfs_cpfile_change_cpmode(struct inode *cpfile, __u64 cno, int mode) in nilfs_cpfile_change_cpmode() argument
870 if (nilfs_checkpoint_is_mounted(cpfile->i_sb, cno)) in nilfs_cpfile_change_cpmode()
879 ret = nilfs_cpfile_clear_snapshot(cpfile, cno); in nilfs_cpfile_change_cpmode()
882 return nilfs_cpfile_set_snapshot(cpfile, cno); in nilfs_cpfile_change_cpmode()