Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
b=23185 use resolve_arch() in the test too
[fs/lustre-release.git]
/
lustre
/
quota
/
lproc_quota.c
diff --git
a/lustre/quota/lproc_quota.c
b/lustre/quota/lproc_quota.c
index
6f0114a
..
d7aefe6
100644
(file)
--- a/
lustre/quota/lproc_quota.c
+++ b/
lustre/quota/lproc_quota.c
@@
-26,7
+26,7
@@
* GPL HEADER END
*/
/*
* GPL HEADER END
*/
/*
- * Copyright
2008 Sun Microsystems, Inc. All rights reserved
+ * Copyright
(c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
* Use is subject to license terms.
*/
/*
* Use is subject to license terms.
*/
/*
@@
-215,6
+215,7
@@
int generic_quota_on(struct obd_device *obd, struct obd_quotactl *oqctl, int glo
int id, is_master, rc = 0, local; /* means we need a local quotaon */
cfs_down(&obt->obt_quotachecking);
int id, is_master, rc = 0, local; /* means we need a local quotaon */
cfs_down(&obt->obt_quotachecking);
+ push_ctxt(&saved, &obd->obd_lvfs_ctxt, NULL);
id = UGQUOTA2LQC(oqctl->qc_type);
local = (obt->obt_qctxt.lqc_flags & id) != id;
id = UGQUOTA2LQC(oqctl->qc_type);
local = (obt->obt_qctxt.lqc_flags & id) != id;
@@
-223,12
+224,10
@@
int generic_quota_on(struct obd_device *obd, struct obd_quotactl *oqctl, int glo
is_master = !strcmp(obd->obd_type->typ_name, LUSTRE_MDS_NAME);
if (is_master) {
is_master = !strcmp(obd->obd_type->typ_name, LUSTRE_MDS_NAME);
if (is_master) {
- cfs_down(&obd->u.mds.mds_qonoff_sem);
+ cfs_down
_write
(&obd->u.mds.mds_qonoff_sem);
if (local) {
if (local) {
- push_ctxt(&saved, &obd->obd_lvfs_ctxt, NULL);
/* turn on cluster wide quota */
rc = mds_admin_quota_on(obd, oqctl);
/* turn on cluster wide quota */
rc = mds_admin_quota_on(obd, oqctl);
- pop_ctxt(&saved, &obd->obd_lvfs_ctxt, NULL);
if (rc && rc != -ENOENT)
CERROR("%s: %s admin quotaon failed. rc=%d\n",
obd->obd_name, global ? "global":"local",
if (rc && rc != -ENOENT)
CERROR("%s: %s admin quotaon failed. rc=%d\n",
obd->obd_name, global ? "global":"local",
@@
-238,7
+237,6
@@
int generic_quota_on(struct obd_device *obd, struct obd_quotactl *oqctl, int glo
if (rc == 0) {
if (local) {
if (rc == 0) {
if (local) {
- push_ctxt(&saved, &obd->obd_lvfs_ctxt, NULL);
rc = fsfilt_quotactl(obd, obt->obt_sb, oqctl);
if (rc) {
if (rc != -ENOENT)
rc = fsfilt_quotactl(obd, obt->obt_sb, oqctl);
if (rc) {
if (rc != -ENOENT)
@@
-249,16
+247,16
@@
int generic_quota_on(struct obd_device *obd, struct obd_quotactl *oqctl, int glo
obt->obt_qctxt.lqc_flags |= UGQUOTA2LQC(oqctl->qc_type);
build_lqs(obd);
}
obt->obt_qctxt.lqc_flags |= UGQUOTA2LQC(oqctl->qc_type);
build_lqs(obd);
}
- pop_ctxt(&saved, &obd->obd_lvfs_ctxt, NULL);
}
if (rc == 0 && global && is_master)
}
if (rc == 0 && global && is_master)
- rc = obd_quotactl(obd->u.mds.mds_
osc
_exp, oqctl);
+ rc = obd_quotactl(obd->u.mds.mds_
lov
_exp, oqctl);
}
if (is_master)
}
if (is_master)
- cfs_up(&obd->u.mds.mds_qonoff_sem);
+ cfs_up
_write
(&obd->u.mds.mds_qonoff_sem);
+ pop_ctxt(&saved, &obd->obd_lvfs_ctxt, NULL);
cfs_up(&obt->obt_quotachecking);
return rc;
cfs_up(&obt->obt_quotachecking);
return rc;