staging/lustre/clio: clear nowait flag agl lock re-enqueue
authorNiu Yawei <yawei.niu@intel.com>
Sun, 27 Apr 2014 17:06:32 +0000 (13:06 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 27 Apr 2014 17:21:38 +0000 (10:21 -0700)
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>
Reviewed-on: http://review.whamcloud.com/9249
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-4597
Reviewed-by: Bobi Jam <bobijam@gmail.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Ned Bass <bass6@llnl.gov>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/lustre/lustre/osc/osc_lock.c

index ef7b9c2b208ecb18d67a734a72222685a00c9fcb..1c6cafa3de707c1f559f0ba403351f48db4f6248 100644 (file)
@@ -1192,6 +1192,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;