- fix from 1_5 branch in ldlm_lock_cancel(). There was race possible when we ask client to return lock back and client does it by itself.
/* If some clients haven't connected in time, evict them */
if (obd->obd_abort_recovery) {
int stale;
- CDEBUG(D_ERROR, "few clients haven't connect in time (%d/%d),"
- "evict them ...\n", obd->obd_connected_clients,
+ CDEBUG(D_ERROR, "Some clients haven't connect in time (%d/%d),"
+ "evict them\n", obd->obd_connected_clients,
obd->obd_max_recoverable_clients);
obd->obd_abort_recovery = 0;
stale = class_disconnect_stale_exports(obd, connect_done);
spin_lock_bh(&obd->obd_processing_task_lock);
if (obd->obd_recovery_data.trd_processing_task > 0) {
struct target_recovery_data *trd = &obd->obd_recovery_data;
- CERROR("%s: aborting recovery\n", obd->obd_name);
+ CERROR("%s: Aborting recovery\n", obd->obd_name);
obd->obd_abort_recovery = 1;
wake_up(&obd->obd_next_transno_waitq);
spin_unlock_bh(&obd->obd_processing_task_lock);
struct ldlm_namespace *ns;
ENTRY;
- ldlm_del_waiting_lock(lock);
lock_res_and_lock(lock);
res = lock->l_resource;
LBUG();
}
+ ldlm_del_waiting_lock(lock);
+
+ /* Releases cancel callback. */
ldlm_cancel_callback(lock);
+ /* Yes, second time, just in case it was added again while we were
+ * running with no res lock in ldlm_cancel_callback */
+ ldlm_del_waiting_lock(lock);
ldlm_resource_unlink_lock(lock);
+ ldlm_lock_destroy_nolock(lock);
unlock_res_and_lock(lock);
- ldlm_lock_destroy(lock);
-
EXIT;
}
* sys_getcwd() could return -ENOENT -bzzz */
#ifdef LUSTRE_KERNEL_VERSION
dentry->d_flags |= DCACHE_LUSTRE_INVALID;
-
- /*
- * XXX: Try to drop negative not directory dentries to check if
- * this is source of OOM on clients on big numbers of created
- * files. --umka
- */
- if (!dentry->d_inode || !S_ISDIR(dentry->d_inode->i_mode))
- __d_drop(dentry);
#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
__d_drop(dentry);
if (dentry->d_inode) {
list_add(&dentry->d_hash,
&ll_i2sbi(dentry->d_inode)->ll_orphan_dentry_list);
}
+#else
+ if (!dentry->d_inode || !S_ISDIR(dentry->d_inode->i_mode))
+ __d_drop(dentry);
#endif
#else
if (!dentry->d_inode || !S_ISDIR(dentry->d_inode->i_mode))
case OBD_IOC_SYNC:
rc = dt->dd_ops->dt_sync(&env, dt);
break;
-
case OBD_IOC_SET_READONLY:
rc = dt->dd_ops->dt_sync(&env, dt);
dt->dd_ops->dt_ro(&env, dt);
break;
-
case OBD_IOC_ABORT_RECOVERY:
- CERROR("aborting recovery for device %s\n", obd->obd_name);
+ CERROR("Aborting recovery for device %s\n", obd->obd_name);
target_stop_recovery_thread(obd);
+ rc = 0;
break;
-
default:
- CERROR("not supported cmd = %d for device %s\n",
+ CERROR("Not supported cmd = %d for device %s\n",
cmd, obd->obd_name);
rc = -EOPNOTSUPP;
}