Whamcloud - gitweb
LU-3677 mdt: Set HSM dirty open-for-write file when evicted.
[fs/lustre-release.git] / lustre / include / lustre_mdc.h
index 27441f9..6cb5f01 100644 (file)
@@ -28,7 +28,7 @@
  * Use is subject to license terms.
  */
 /*
- * Copyright (c) 2012 Whamcloud, Inc.
+ * Copyright (c) 2011, 2012, Intel Corporation.
  */
 /*
  * This file is part of Lustre, http://www.lustre.org/
@@ -88,7 +88,8 @@ static inline void mdc_get_rpc_lock(struct mdc_rpc_lock *lck,
 {
        ENTRY;
 
-       if (it != NULL && (it->it_op == IT_GETATTR || it->it_op == IT_LOOKUP))
+       if (it != NULL && (it->it_op == IT_GETATTR || it->it_op == IT_LOOKUP ||
+                          it->it_op == IT_LAYOUT))
                return;
 
        /* This would normally block until the existing request finishes.
@@ -125,7 +126,8 @@ static inline void mdc_get_rpc_lock(struct mdc_rpc_lock *lck,
 static inline void mdc_put_rpc_lock(struct mdc_rpc_lock *lck,
                                    struct lookup_intent *it)
 {
-       if (it != NULL && (it->it_op == IT_GETATTR || it->it_op == IT_LOOKUP))
+       if (it != NULL && (it->it_op == IT_GETATTR || it->it_op == IT_LOOKUP ||
+                          it->it_op == IT_LAYOUT))
                goto out;
 
        if (lck->rpcl_it == MDC_FAKE_RPCL_IT) { /* OBD_FAIL_MDC_RPCS_SEM */