summaryrefslogtreecommitdiff
path: root/fs/ceph/super.h
diff options
context:
space:
mode:
authorLuis Henriques <lhenriques@suse.com>2018-01-05 10:47:22 +0000
committerIlya Dryomov <idryomov@gmail.com>2018-04-02 11:17:52 +0200
commit1ab302a0cb1455631646aa66b7fc02afd617ea4f (patch)
tree73686da6a5aef8ef0190bd8498d3591fc766ddee /fs/ceph/super.h
parent2b83845f8bd711e66e1c367a9bd56c9df3410236 (diff)
ceph: quota: update MDS when max_bytes is approaching
When we're reaching the ceph.quota.max_bytes limit, i.e., when writing more than 1/16th of the space left in a quota realm, update the MDS with the new file size. This mirrors the fuse-client approach with commit 122c50315ed1 ("client: Inform mds file size when approaching quota limit"), in the ceph git tree. Signed-off-by: Luis Henriques <lhenriques@suse.com> Reviewed-by: "Yan, Zheng" <zyan@redhat.com> Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'fs/ceph/super.h')
-rw-r--r--fs/ceph/super.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/ceph/super.h b/fs/ceph/super.h
index 5870c225c2fc..e4ff485d24c7 100644
--- a/fs/ceph/super.h
+++ b/fs/ceph/super.h
@@ -1081,5 +1081,7 @@ extern bool ceph_quota_is_max_files_exceeded(struct inode *inode);
extern bool ceph_quota_is_same_realm(struct inode *old, struct inode *new);
extern bool ceph_quota_is_max_bytes_exceeded(struct inode *inode,
loff_t newlen);
+extern bool ceph_quota_is_max_bytes_approaching(struct inode *inode,
+ loff_t newlen);
#endif /* _FS_CEPH_SUPER_H */