Whamcloud - gitweb
LU-5560 tests: add sanity-selinux.sh
[fs/lustre-release.git] / lustre / llite / namei.c
index 3e6c706..1c17b50 100644 (file)
@@ -716,6 +716,8 @@ static int ll_atomic_open(struct inode *dir, struct dentry *dentry,
        else if (de != NULL)
                dentry = de;
 
+       CFS_FAIL_TIMEOUT(OBD_FAIL_LLITE_CREATE_FILE_PAUSE, cfs_fail_val);
+
        if (!rc) {
                if (it_disposition(it, DISP_OPEN_CREATE)) {
                        /* Dentry instantiated in ll_create_it. */
@@ -1005,7 +1007,9 @@ again:
                goto again;
        }
 
-        ll_update_times(request, dir);
+       ll_update_times(request, dir);
+
+       CFS_FAIL_TIMEOUT(OBD_FAIL_LLITE_NEWNODE_PAUSE, cfs_fail_val);
 
        err = ll_prep_inode(&inode, request, dchild->d_sb, NULL);
        if (err)
@@ -1072,6 +1076,8 @@ static int ll_create_nd(struct inode *dir, struct dentry *dentry,
 {
        int rc;
 
+       CFS_FAIL_TIMEOUT(OBD_FAIL_LLITE_CREATE_FILE_PAUSE, cfs_fail_val);
+
        CDEBUG(D_VFSTRACE, "VFS Op:name=%.*s, dir="DFID"(%p), "
                           "flags=%u, excl=%d\n", dentry->d_name.len,
               dentry->d_name.name, PFID(ll_inode2fid(dir)),
@@ -1092,7 +1098,9 @@ static int ll_create_nd(struct inode *dir, struct dentry *dentry,
 {
        struct ll_dentry_data *lld = ll_d2d(dentry);
        struct lookup_intent *it = NULL;
-        int rc;
+       int rc;
+
+       CFS_FAIL_TIMEOUT(OBD_FAIL_LLITE_CREATE_FILE_PAUSE, cfs_fail_val);
 
        if (lld != NULL)
                it = lld->lld_it;