aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/nilfs2_fs.h
diff options
context:
space:
mode:
authorRyusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>2009-04-06 22:01:57 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-04-07 11:31:19 -0400
commitc96fa464a567a2a8796009af0e79bc68af73f485 (patch)
tree5467fcdc2a4a64dfad3c5cb627451b6f7e76809b /include/linux/nilfs2_fs.h
parent458c5b0822a669d170fdb7bb16c9145f652ebe06 (diff)
nilfs2: mark minor flag for checkpoint created by internal operation
Nilfs creates checkpoints even for garbage collection or metadata updates such as checkpoint mode change. So, user often sees checkpoints created only by such internal operations. This is inconvenient in some situations. For example, application that monitors checkpoints and changes them to snapshots, will fall into an infinite loop because it cannot distinguish internally created checkpoints. This patch solves this sort of problem by adding a flag to checkpoint for identification. Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/nilfs2_fs.h')
-rw-r--r--include/linux/nilfs2_fs.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/nilfs2_fs.h b/include/linux/nilfs2_fs.h
index e9c84aa4a8e1..cbce6647f7fd 100644
--- a/include/linux/nilfs2_fs.h
+++ b/include/linux/nilfs2_fs.h
@@ -470,6 +470,7 @@ enum {
470 NILFS_CHECKPOINT_SNAPSHOT, 470 NILFS_CHECKPOINT_SNAPSHOT,
471 NILFS_CHECKPOINT_INVALID, 471 NILFS_CHECKPOINT_INVALID,
472 NILFS_CHECKPOINT_SKETCH, 472 NILFS_CHECKPOINT_SKETCH,
473 NILFS_CHECKPOINT_MINOR,
473}; 474};
474 475
475#define NILFS_CHECKPOINT_FNS(flag, name) \ 476#define NILFS_CHECKPOINT_FNS(flag, name) \
@@ -494,6 +495,7 @@ nilfs_checkpoint_##name(const struct nilfs_checkpoint *cp) \
494 495
495NILFS_CHECKPOINT_FNS(SNAPSHOT, snapshot) 496NILFS_CHECKPOINT_FNS(SNAPSHOT, snapshot)
496NILFS_CHECKPOINT_FNS(INVALID, invalid) 497NILFS_CHECKPOINT_FNS(INVALID, invalid)
498NILFS_CHECKPOINT_FNS(MINOR, minor)
497 499
498/** 500/**
499 * struct nilfs_cpinfo - checkpoint information 501 * struct nilfs_cpinfo - checkpoint information
@@ -526,6 +528,7 @@ nilfs_cpinfo_##name(const struct nilfs_cpinfo *cpinfo) \
526 528
527NILFS_CPINFO_FNS(SNAPSHOT, snapshot) 529NILFS_CPINFO_FNS(SNAPSHOT, snapshot)
528NILFS_CPINFO_FNS(INVALID, invalid) 530NILFS_CPINFO_FNS(INVALID, invalid)
531NILFS_CPINFO_FNS(MINOR, minor)
529 532
530 533
531/** 534/**