]> git.baikalelectronics.ru Git - kernel.git/commit
quota: fill in Q_XGETQSTAT inode information for inactive quotas
authorEric Sandeen <sandeen@redhat.com>
Fri, 12 Aug 2016 22:40:09 +0000 (17:40 -0500)
committerJan Kara <jack@suse.cz>
Mon, 15 Aug 2016 15:43:31 +0000 (17:43 +0200)
commitb5d698aeffdaa27b5deac8504978b0fbd3eaa1ff
tree3e378fb00b74d19750f1fc530216e84898b20be3
parent604bd75f28fb725e396edfc17f44f62bb6d17bd8
quota: fill in Q_XGETQSTAT inode information for inactive quotas

The manpage for quotactl says that the Q_XGETQSTAT command is
"useful in finding out how much space is spent to store quota
information," but the current implementation does not report this
info if the inode is allocated, but its quota type is not enabled.

This is a change from the earlier XFS implementation, which
reported information about allocated quota inodes even if their
quota type was not currently active.

Change quota_getstate() and quota_getstatev() to copy out the inode
information if the filesystem has provided it, even if the quota
type for that inode is not currently active.

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Reviewed-by: Bill O'Donnell <billodo@redhat.com>
Signed-off-by: Jan Kara <jack@suse.cz>
fs/quota/quota.c