Whamcloud - gitweb
LU-6433 quota: handle QUOTA_DQACQ in READPAGE portal 69/14369/4
authorAndriy Skulysh <andriy.skulysh@seagate.com>
Thu, 14 May 2015 11:06:16 +0000 (14:06 +0300)
committerOleg Drokin <oleg.drokin@intel.com>
Fri, 10 Jul 2015 02:53:54 +0000 (02:53 +0000)
MDS sends quota request to quota master, which can be
the same host. Deadlock is possible if all other MDS
threads are waiting for lock taken by first thread.

Lets use MDS_READPAGE portal to avoid the deadlock.

Xyratex-bug-id: MRP-2433
Change-Id: Ib2266a6771cfc5a70bae23206b1144bfd45f9ff3
Signed-off-by: Andriy Skulysh <andriy.skulysh@seagate.com>
Reviewed-on: http://review.whamcloud.com/14369
Reviewed-by: Niu Yawei <yawei.niu@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Ann Koehler <amk@cray.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/quota/qsd_request.c

index 8666cfc..1abc4eb 100644 (file)
@@ -113,6 +113,7 @@ int qsd_send_dqacq(const struct lu_env *env, struct obd_export *exp,
                GOTO(out, rc);
        }
 
+       req->rq_request_portal = MDS_READPAGE_PORTAL;
        req_qbody = req_capsule_client_get(&req->rq_pill, &RMF_QUOTA_BODY);
        *req_qbody = *qbody;
 
@@ -231,6 +232,7 @@ int qsd_intent_lock(const struct lu_env *env, struct obd_export *exp,
                ptlrpc_request_free(req);
                GOTO(out, rc);
        }
+       req->rq_request_portal = MDS_READPAGE_PORTAL;
 
        lit = req_capsule_client_get(&req->rq_pill, &RMF_LDLM_INTENT);
        lit->opc = (__u64)it_op;