linux-pinenote/fs/gfs2
Jan Kara 14bf61ffe6 quota: Switch ->get_dqblk() and ->set_dqblk() to use bytes as space units
Currently ->get_dqblk() and ->set_dqblk() use struct fs_disk_quota which
tracks space limits and usage in 512-byte blocks. However VFS quotas
track usage in bytes (as some filesystems require that) and we need to
somehow pass this information. Upto now it wasn't a problem because we
didn't do any unit conversion (thus VFS quota routines happily stuck
number of bytes into d_bcount field of struct fd_disk_quota). Only if
you tried to use Q_XGETQUOTA or Q_XSETQLIM for VFS quotas (or Q_GETQUOTA
/ Q_SETQUOTA for XFS quotas), you got bogus results. Hardly anyone
tried this but reportedly some Samba users hit the problem in practice.
So when we want interfaces compatible we need to fix this.

We bite the bullet and define another quota structure used for passing
information from/to ->get_dqblk()/->set_dqblk. It's somewhat sad we have
to have more conversion routines in fs/quota/quota.c and another copying
of quota structure slows down getting of quota information by about 2%
but it seems cleaner than overloading e.g. units of d_bcount to bytes.

CC: stable@vger.kernel.org
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jan Kara <jack@suse.cz>
2015-01-28 09:01:40 +01:00
..
acl.c
acl.h
aops.c
bmap.c
bmap.h
dentry.c vfs: Remove unnecessary calls of check_submounts_and_drop 2014-10-09 02:38:56 -04:00
dir.c GFS2: gfs2_dir_get_hash_table(): avoiding deferred vfree() is easy here... 2014-11-20 10:29:44 +00:00
dir.h
export.c vfs: make first argument of dir_context.actor typed 2014-10-31 17:48:54 -04:00
file.c GFS2: Update timestamps on fallocate 2014-11-14 14:16:33 +00:00
gfs2.h
glock.c GFS2: Deletion of unnecessary checks before two function calls 2014-11-18 10:57:58 +00:00
glock.h
glops.c GFS2: update freeze code to use freeze/thaw_super on all nodes 2014-11-17 10:36:39 +00:00
glops.h GFS2: update freeze code to use freeze/thaw_super on all nodes 2014-11-17 10:36:39 +00:00
incore.h GFS2: update freeze code to use freeze/thaw_super on all nodes 2014-11-17 10:36:39 +00:00
inode.c GFS2: gfs2_atomic_open(): simplify the use of finish_no_open() 2014-11-20 11:18:08 +00:00
inode.h
Kconfig
lock_dlm.c
log.c GFS2: update freeze code to use freeze/thaw_super on all nodes 2014-11-17 10:36:39 +00:00
log.h
lops.c
lops.h
main.c GFS2: update freeze code to use freeze/thaw_super on all nodes 2014-11-17 10:36:39 +00:00
Makefile
meta_io.c
meta_io.h
ops_fstype.c Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs 2014-12-10 15:43:30 -08:00
quota.c quota: Switch ->get_dqblk() and ->set_dqblk() to use bytes as space units 2015-01-28 09:01:40 +01:00
quota.h
recovery.c
recovery.h
rgrp.c GFS2: If we use up our block reservation, request more next time 2014-11-03 19:26:54 +00:00
rgrp.h GFS2: If we use up our block reservation, request more next time 2014-11-03 19:26:54 +00:00
super.c GFS2: update freeze code to use freeze/thaw_super on all nodes 2014-11-17 10:36:39 +00:00
super.h GFS2: update freeze code to use freeze/thaw_super on all nodes 2014-11-17 10:36:39 +00:00
sys.c
sys.h
trace_gfs2.h
trans.c GFS2: update freeze code to use freeze/thaw_super on all nodes 2014-11-17 10:36:39 +00:00
trans.h
util.c
util.h
xattr.c
xattr.h