Whamcloud - gitweb
LU-4597 clio: clear nowait flag agl lock re-enqueue 49/9249/1
authorNiu Yawei <yawei.niu@intel.com>
Thu, 13 Feb 2014 07:07:14 +0000 (02:07 -0500)
committerNiu Yawei <yawei.niu@intel.com>
Thu, 13 Feb 2014 07:07:14 +0000 (02:07 -0500)
The LDLM_FL_BLOCK_NOWAIT flag should be cleared when re-enqueue
the agl lock as normal glimpse, otherwise, it won't get size back
if there is conflicting locks on other client.

Signed-off-by: Niu Yawei <yawei.niu@intel.com>
Change-Id: Ifd311606e824d6574bfbf3256841061e8867214a

lustre/osc/osc_lock.c

index e06a900..842686d 100644 (file)
@@ -1284,6 +1284,7 @@ static int osc_lock_wait(const struct lu_env *env,
 
                 LASSERT(olck->ols_agl);
                olck->ols_agl = 0;
+               olck->ols_flags &= ~LDLM_FL_BLOCK_NOWAIT;
                 rc = osc_lock_enqueue(env, slice, NULL, CEF_ASYNC | CEF_MUST);
                 if (rc != 0)
                         return rc;