Whamcloud - gitweb
LU-2490 mdd: mdd_links_rename() be quiet in regular cases
[fs/lustre-release.git] / lustre / quota / qsd_lock.c
index f49abb6..d62ea86 100644 (file)
@@ -126,6 +126,8 @@ static int qsd_common_glimpse_ast(struct ptlrpc_request *req,
                RETURN(-EFAULT);
 
        /* prepare reply */
+       req_capsule_set_size(&req->rq_pill, &RMF_DLM_LVB, RCL_SERVER,
+                            sizeof(struct lquota_lvb));
        rc = req_capsule_server_pack(&req->rq_pill);
        if (rc != 0) {
                CERROR("Can't pack response, rc %d\n", rc);
@@ -175,12 +177,12 @@ static int qsd_glb_blocking_ast(struct ldlm_lock *lock,
 
                /* we are losing the global index lock, so let's mark the
                 * global & slave indexes as not up-to-date any more */
-               cfs_write_lock(&qqi->qqi_qsd->qsd_lock);
+               write_lock(&qqi->qqi_qsd->qsd_lock);
                qqi->qqi_glb_uptodate = false;
                qqi->qqi_slv_uptodate = false;
                if (lock->l_handle.h_cookie == qqi->qqi_lockh.cookie)
                        memset(&qqi->qqi_lockh, 0, sizeof(qqi->qqi_lockh));
-               cfs_write_unlock(&qqi->qqi_qsd->qsd_lock);
+               write_unlock(&qqi->qqi_qsd->qsd_lock);
 
                CDEBUG(D_QUOTA, "%s: losing global index lock for %s type\n",
                       qqi->qqi_qsd->qsd_svname, QTYPE_NAME((qqi->qqi_qtype)));
@@ -241,7 +243,7 @@ static int qsd_glb_glimpse_ast(struct ldlm_lock *lock, void *data)
        /* extract new hard & soft limits from the glimpse descriptor */
        rec.qbr_hardlimit = desc->gl_hardlimit;
        rec.qbr_softlimit = desc->gl_softlimit;
-       rec.qbr_time      = 0;
+       rec.qbr_time      = desc->gl_time;
        rec.qbr_granted   = 0;
 
        /* We can't afford disk io in the context of glimpse callback handling