1
0
Fork 0

[PATCH] fuse: use dentry in statfs

Some filesystems may want to report different values depending on the path
within the filesystem, i.e.  one mount is actually several filesystems.  This
can be the case for a network filesystem exported by an unprivileged server
(e.g.  sshfs).

This is now possible, thanks to David Howells "VFS: Permit filesystem to
perform statfs with a known root dentry" patch.

This change is backward compatible, so no need to change interface version.

Signed-off-by: Miklos Szeredi <miklos@szeredi.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
hifive-unleashed-5.1
Miklos Szeredi 2006-09-29 01:59:34 -07:00 committed by Linus Torvalds
parent d10be6d1bd
commit 5b35e8e58a
1 changed files with 1 additions and 0 deletions

View File

@ -251,6 +251,7 @@ static int fuse_statfs(struct dentry *dentry, struct kstatfs *buf)
memset(&outarg, 0, sizeof(outarg));
req->in.numargs = 0;
req->in.h.opcode = FUSE_STATFS;
req->in.h.nodeid = get_node_id(dentry->d_inode);
req->out.numargs = 1;
req->out.args[0].size =
fc->minor < 4 ? FUSE_COMPAT_STATFS_SIZE : sizeof(outarg);