Message ID | 20241211085636.1380516-43-hch@lst.de (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | [01/43] xfs: constify feature checks | expand |
On Wed, Dec 11, 2024 at 09:55:07AM +0100, Christoph Hellwig wrote: > The show_stats option allows a file system to dump plain text statistic > on a per-mount basis into /proc/*/mountstats. Wire up a no-op version > which will grow useful information for zoned file systems later. > > Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: "Darrick J. Wong" <djwong@kernel.org> --D > --- > fs/xfs/xfs_super.c | 9 +++++++++ > 1 file changed, 9 insertions(+) > > diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c > index d2f2fa26c487..47468623fdc6 100644 > --- a/fs/xfs/xfs_super.c > +++ b/fs/xfs/xfs_super.c > @@ -1238,6 +1238,14 @@ xfs_fs_shutdown( > xfs_force_shutdown(XFS_M(sb), SHUTDOWN_DEVICE_REMOVED); > } > > +static int > +xfs_fs_show_stats( > + struct seq_file *m, > + struct dentry *root) > +{ > + return 0; > +} > + > static const struct super_operations xfs_super_operations = { > .alloc_inode = xfs_fs_alloc_inode, > .destroy_inode = xfs_fs_destroy_inode, > @@ -1252,6 +1260,7 @@ static const struct super_operations xfs_super_operations = { > .nr_cached_objects = xfs_fs_nr_cached_objects, > .free_cached_objects = xfs_fs_free_cached_objects, > .shutdown = xfs_fs_shutdown, > + .show_stats = xfs_fs_show_stats, > }; > > static int > -- > 2.45.2 > >
diff --git a/fs/xfs/xfs_super.c b/fs/xfs/xfs_super.c index d2f2fa26c487..47468623fdc6 100644 --- a/fs/xfs/xfs_super.c +++ b/fs/xfs/xfs_super.c @@ -1238,6 +1238,14 @@ xfs_fs_shutdown( xfs_force_shutdown(XFS_M(sb), SHUTDOWN_DEVICE_REMOVED); } +static int +xfs_fs_show_stats( + struct seq_file *m, + struct dentry *root) +{ + return 0; +} + static const struct super_operations xfs_super_operations = { .alloc_inode = xfs_fs_alloc_inode, .destroy_inode = xfs_fs_destroy_inode, @@ -1252,6 +1260,7 @@ static const struct super_operations xfs_super_operations = { .nr_cached_objects = xfs_fs_nr_cached_objects, .free_cached_objects = xfs_fs_free_cached_objects, .shutdown = xfs_fs_shutdown, + .show_stats = xfs_fs_show_stats, }; static int
The show_stats option allows a file system to dump plain text statistic on a per-mount basis into /proc/*/mountstats. Wire up a no-op version which will grow useful information for zoned file systems later. Signed-off-by: Christoph Hellwig <hch@lst.de> --- fs/xfs/xfs_super.c | 9 +++++++++ 1 file changed, 9 insertions(+)