diff options
author | Eric W. Biederman <ebiederm@xmission.com> | 2012-09-16 05:07:49 -0400 |
---|---|---|
committer | Eric W. Biederman <ebiederm@xmission.com> | 2012-09-18 04:01:39 -0400 |
commit | 74a8a103789465c4e67f38d1abb5cea770002601 (patch) | |
tree | ac650aebb368b353226651a74361d9ecc3da0d11 /include/linux/quotaops.h | |
parent | e8a3e4719b7ec19288c56f22623f537cb78885c1 (diff) |
userns: Convert qutoactl
Update the quotactl user space interface to successfull compile with
user namespaces support enabled and to hand off quota identifiers to
lower layers of the kernel in struct kqid instead of type and qid
pairs.
The quota on function is not converted because while it takes a quota
type and an id. The id is the on disk quota format to use, which
is something completely different.
The signature of two struct quotactl_ops methods were changed to take
struct kqid argumetns get_dqblk and set_dqblk.
The dquot, xfs, and ocfs2 implementations of get_dqblk and set_dqblk
are minimally changed so that the code continues to work with
the change in parameter type.
This is the first in a series of changes to always store quota
identifiers in the kernel in struct kqid and only use raw type and qid
values when interacting with on disk structures or userspace. Always
using struct kqid internally makes it hard to miss places that need
conversion to or from the kernel internal values.
Cc: Jan Kara <jack@suse.cz>
Cc: Dave Chinner <david@fromorbit.com>
Cc: Mark Fasheh <mfasheh@suse.com>
Cc: Joel Becker <jlbec@evilplan.org>
Cc: Ben Myers <bpm@sgi.com>
Cc: Alex Elder <elder@kernel.org>
Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Diffstat (limited to 'include/linux/quotaops.h')
-rw-r--r-- | include/linux/quotaops.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/quotaops.h b/include/linux/quotaops.h index ec6b65feaaba..bd3730d76fd9 100644 --- a/include/linux/quotaops.h +++ b/include/linux/quotaops.h | |||
@@ -87,9 +87,9 @@ int dquot_writeback_dquots(struct super_block *sb, int type); | |||
87 | int dquot_quota_sync(struct super_block *sb, int type); | 87 | int dquot_quota_sync(struct super_block *sb, int type); |
88 | int dquot_get_dqinfo(struct super_block *sb, int type, struct if_dqinfo *ii); | 88 | int dquot_get_dqinfo(struct super_block *sb, int type, struct if_dqinfo *ii); |
89 | int dquot_set_dqinfo(struct super_block *sb, int type, struct if_dqinfo *ii); | 89 | int dquot_set_dqinfo(struct super_block *sb, int type, struct if_dqinfo *ii); |
90 | int dquot_get_dqblk(struct super_block *sb, int type, qid_t id, | 90 | int dquot_get_dqblk(struct super_block *sb, struct kqid id, |
91 | struct fs_disk_quota *di); | 91 | struct fs_disk_quota *di); |
92 | int dquot_set_dqblk(struct super_block *sb, int type, qid_t id, | 92 | int dquot_set_dqblk(struct super_block *sb, struct kqid id, |
93 | struct fs_disk_quota *di); | 93 | struct fs_disk_quota *di); |
94 | 94 | ||
95 | int __dquot_transfer(struct inode *inode, struct dquot **transfer_to); | 95 | int __dquot_transfer(struct inode *inode, struct dquot **transfer_to); |