diff options
author | Vyacheslav Dubeyko <Vyacheslav.Dubeyko@hgst.com> | 2014-08-09 01:20:50 +0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-08-09 02:57:21 +0400 |
commit | a2ecb791a9d6e71a2d37d66034475a92ebc7e02c (patch) | |
tree | f9f5c2d3bd24ef0105786d73561bbcafaca3fb25 /fs/nilfs2/sysfs.h | |
parent | 02a0ba1c60c2ad532322089a60256c8b0f46678c (diff) | |
download | linux-a2ecb791a9d6e71a2d37d66034475a92ebc7e02c.tar.xz |
nilfs2: add /sys/fs/nilfs2/<device>/mounted_snapshots group
This patch adds creation of /sys/fs/nilfs2/<device>/mounted_snapshots
group.
The mounted_snapshots group contains group for every
mounted snapshot.
Signed-off-by: Vyacheslav Dubeyko <Vyacheslav.Dubeyko@hgst.com>
Cc: Vyacheslav Dubeyko <slava@dubeyko.com>
Cc: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
Cc: Michael L. Semon <mlsemon35@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/nilfs2/sysfs.h')
-rw-r--r-- | fs/nilfs2/sysfs.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/fs/nilfs2/sysfs.h b/fs/nilfs2/sysfs.h index 62f0a0dc78ca..4e84e230e9dd 100644 --- a/fs/nilfs2/sysfs.h +++ b/fs/nilfs2/sysfs.h @@ -30,6 +30,8 @@ * @sg_superblock_kobj_unregister: completion state * @sg_segctor_kobj: /sys/fs/<nilfs>/<device>/segctor * @sg_segctor_kobj_unregister: completion state + * @sg_mounted_snapshots_kobj: /sys/fs/<nilfs>/<device>/mounted_snapshots + * @sg_mounted_snapshots_kobj_unregister: completion state * @sg_checkpoints_kobj: /sys/fs/<nilfs>/<device>/checkpoints * @sg_checkpoints_kobj_unregister: completion state * @sg_segments_kobj: /sys/fs/<nilfs>/<device>/segments @@ -44,6 +46,10 @@ struct nilfs_sysfs_dev_subgroups { struct kobject sg_segctor_kobj; struct completion sg_segctor_kobj_unregister; + /* /sys/fs/<nilfs>/<device>/mounted_snapshots */ + struct kobject sg_mounted_snapshots_kobj; + struct completion sg_mounted_snapshots_kobj_unregister; + /* /sys/fs/<nilfs>/<device>/checkpoints */ struct kobject sg_checkpoints_kobj; struct completion sg_checkpoints_kobj_unregister; @@ -75,6 +81,7 @@ struct nilfs_##name##_attr { \ NILFS_DEV_ATTR_STRUCT(dev); NILFS_DEV_ATTR_STRUCT(segments); +NILFS_DEV_ATTR_STRUCT(mounted_snapshots); NILFS_DEV_ATTR_STRUCT(checkpoints); NILFS_DEV_ATTR_STRUCT(superblock); NILFS_DEV_ATTR_STRUCT(segctor); @@ -111,6 +118,9 @@ NILFS_DEV_ATTR_STRUCT(segctor); #define NILFS_SEGMENTS_RW_ATTR(name) \ NILFS_RW_ATTR(segs_info, name) +#define NILFS_MOUNTED_SNAPSHOTS_RO_ATTR(name) \ + NILFS_RO_ATTR(mounted_snapshots, name) + #define NILFS_CHECKPOINTS_RO_ATTR(name) \ NILFS_RO_ATTR(checkpoints, name) #define NILFS_CHECKPOINTS_RW_ATTR(name) \ @@ -134,6 +144,8 @@ NILFS_DEV_ATTR_STRUCT(segctor); (&nilfs_dev_attr_##name.attr) #define NILFS_SEGMENTS_ATTR_LIST(name) \ (&nilfs_segments_attr_##name.attr) +#define NILFS_MOUNTED_SNAPSHOTS_ATTR_LIST(name) \ + (&nilfs_mounted_snapshots_attr_##name.attr) #define NILFS_CHECKPOINTS_ATTR_LIST(name) \ (&nilfs_checkpoints_attr_##name.attr) #define NILFS_SUPERBLOCK_ATTR_LIST(name) \ |