mirror of
https://github.com/torvalds/linux.git
synced 2025-12-01 07:26:02 +07:00
vfs: switch ->show_stats to struct dentry *
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
@@ -183,12 +183,13 @@ static int show_vfsstat(struct seq_file *m, struct vfsmount *mnt)
|
||||
{
|
||||
struct mount *r = real_mount(mnt);
|
||||
struct path mnt_path = { .dentry = mnt->mnt_root, .mnt = mnt };
|
||||
struct super_block *sb = mnt_path.dentry->d_sb;
|
||||
int err = 0;
|
||||
|
||||
/* device */
|
||||
if (mnt->mnt_sb->s_op->show_devname) {
|
||||
if (sb->s_op->show_devname) {
|
||||
seq_puts(m, "device ");
|
||||
err = mnt->mnt_sb->s_op->show_devname(m, mnt);
|
||||
err = sb->s_op->show_devname(m, mnt);
|
||||
} else {
|
||||
if (r->mnt_devname) {
|
||||
seq_puts(m, "device ");
|
||||
@@ -204,13 +205,13 @@ static int show_vfsstat(struct seq_file *m, struct vfsmount *mnt)
|
||||
|
||||
/* file system type */
|
||||
seq_puts(m, "with fstype ");
|
||||
show_type(m, mnt->mnt_sb);
|
||||
show_type(m, sb);
|
||||
|
||||
/* optional statistics */
|
||||
if (mnt->mnt_sb->s_op->show_stats) {
|
||||
if (sb->s_op->show_stats) {
|
||||
seq_putc(m, ' ');
|
||||
if (!err)
|
||||
err = mnt->mnt_sb->s_op->show_stats(m, mnt);
|
||||
err = sb->s_op->show_stats(m, mnt_path.dentry);
|
||||
}
|
||||
|
||||
seq_putc(m, '\n');
|
||||
|
||||
Reference in New Issue
Block a user