gfs2: eliminate gfs2_rsqa_alloc in favor of gfs2_qa_alloc

Before this patch, multiple callers called gfs2_rsqa_alloc to force
the existence of a reservations structure and a quota data structure
if needed. However, now the reservations are handled separately, so
the quota data is only the quota data. So we eliminate the one in
favor of just calling gfs2_qa_alloc directly.

Signed-off-by: Bob Peterson <rpeterso@redhat.com>
This commit is contained in:
Bob Peterson
2020-03-06 10:18:44 -06:00
parent 969183bc68
commit d580712a37
8 changed files with 17 additions and 27 deletions

View File

@@ -458,7 +458,7 @@ static vm_fault_t gfs2_page_mkwrite(struct vm_fault *vmf)
sb_start_pagefault(inode->i_sb);
ret = gfs2_rsqa_alloc(ip);
ret = gfs2_qa_alloc(ip);
if (ret)
goto out;
@@ -849,7 +849,7 @@ static ssize_t gfs2_file_write_iter(struct kiocb *iocb, struct iov_iter *from)
struct gfs2_inode *ip = GFS2_I(inode);
ssize_t ret;
ret = gfs2_rsqa_alloc(ip);
ret = gfs2_qa_alloc(ip);
if (ret)
return ret;
@@ -1149,7 +1149,7 @@ static long gfs2_fallocate(struct file *file, int mode, loff_t offset, loff_t le
if (mode & FALLOC_FL_PUNCH_HOLE) {
ret = __gfs2_punch_hole(file, offset, len);
} else {
ret = gfs2_rsqa_alloc(ip);
ret = gfs2_qa_alloc(ip);
if (ret)
goto out_putw;
@@ -1176,7 +1176,7 @@ static ssize_t gfs2_file_splice_write(struct pipe_inode_info *pipe,
int error;
struct gfs2_inode *ip = GFS2_I(out->f_mapping->host);
error = gfs2_rsqa_alloc(ip);
error = gfs2_qa_alloc(ip);
if (error)
return (ssize_t)error;