Re: [PATCH 2/8] VFS: per inode statfs (core)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> > > > This patch adds a statfs method to inode operations.  This is invoked
> > > > whenever the dentry is available (not called from sys_ustat()) and the
> > > > filesystem implements this method.  Otherwise the normal
> > > > s_op->statfs() will be called.
> > > > 
> > > > This change is backward compatible, but calls to vfs_statfs() should
> > > > be changed to vfs_dentry_statfs() whenever possible.
> > > 
> > > What the fuck for?  statfs() returns data that by definition should
> > > not depend on inode within a filesystem.
> > 
> > Exactly.  But it's specified nowhere that there has to be a one-one
> > mapping between remote filesystem - local filesystem.
> 
> Unfortunately making statfs alone aware of them does not help. Most useful
> tools that use statfs go to /proc/mouts, read all the entries and invoke
> statfs for each path. So if for some non-root path different values are
> returned, these tools won't see them anyway. So try to think about how to
> provide the info about subfilesystems first.

'df .': tried it and it did not do what was expected, but that can
definitely be fixed

'stat -f .': actually works

foo-filemanager: before copying a file or directory tree, checks for
free space in destination directory

None of the above examples need (and use) /etc/mtab or /proc/mounts.

Just because the info is not available about the placement of the
subfilesystems, doesn't mean that the subfilesystems don't actually
exist.

Miklos
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux