aboutsummaryrefslogtreecommitdiffstats
path: root/fs/nilfs2/the_nilfs.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/nilfs2/the_nilfs.c')
-rw-r--r--fs/nilfs2/the_nilfs.c21
1 files changed, 0 insertions, 21 deletions
diff --git a/fs/nilfs2/the_nilfs.c b/fs/nilfs2/the_nilfs.c
index 4d6763e28eb5..4cc705a1d135 100644
--- a/fs/nilfs2/the_nilfs.c
+++ b/fs/nilfs2/the_nilfs.c
@@ -769,24 +769,3 @@ void nilfs_put_root(struct nilfs_root *root)
769 kfree(root); 769 kfree(root);
770 } 770 }
771} 771}
772
773int nilfs_checkpoint_is_mounted(struct the_nilfs *nilfs, __u64 cno,
774 int snapshot_mount)
775{
776 struct nilfs_root *root;
777 int ret;
778
779 if (cno < 0 || cno > nilfs->ns_cno)
780 return false;
781
782 if (cno >= nilfs_last_cno(nilfs))
783 return true; /* protect recent checkpoints */
784
785 ret = false;
786 root = nilfs_lookup_root(nilfs, cno);
787 if (root) {
788 ret = true;
789 nilfs_put_root(root);
790 }
791 return ret;
792}