hc
2024-01-03 2f7c68cb55ecb7331f2381deb497c27155f32faf
kernel/fs/gfs2/acl.c
....@@ -1,10 +1,7 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Copyright (C) Sistina Software, Inc. 1997-2003 All rights reserved.
34 * Copyright (C) 2004-2006 Red Hat, Inc. All rights reserved.
4
- *
5
- * This copyrighted material is made available to anyone wishing to use,
6
- * modify, copy, or redistribute it subject to the terms and conditions
7
- * of the GNU General Public License version 2.
85 */
96
107 #include <linux/sched.h>
....@@ -24,6 +21,7 @@
2421 #include "glock.h"
2522 #include "inode.h"
2623 #include "meta_io.h"
24
+#include "quota.h"
2725 #include "rgrp.h"
2826 #include "trans.h"
2927 #include "util.h"
....@@ -119,14 +117,14 @@
119117 if (acl && acl->a_count > GFS2_ACL_MAX_ENTRIES(GFS2_SB(inode)))
120118 return -E2BIG;
121119
122
- ret = gfs2_rsqa_alloc(ip);
120
+ ret = gfs2_qa_get(ip);
123121 if (ret)
124122 return ret;
125123
126124 if (!gfs2_glock_is_locked_by_me(ip->i_gl)) {
127125 ret = gfs2_glock_nq_init(ip->i_gl, LM_ST_EXCLUSIVE, 0, &gh);
128126 if (ret)
129
- return ret;
127
+ goto out;
130128 need_unlock = true;
131129 }
132130
....@@ -146,5 +144,7 @@
146144 unlock:
147145 if (need_unlock)
148146 gfs2_glock_dq_uninit(&gh);
147
+out:
148
+ gfs2_qa_put(ip);
149149 return ret;
150150 }