Skip to content
Snippets Groups Projects
Commit 35b38cc1 authored by Yury Umanets's avatar Yury Umanets
Browse files

b=15440

- missed part of 15440. Do not forget to call ldlm_pool_fini() before removing ns proc dir;

- call ldlm_namespace_unregister() namespace _before_ __ldlm_namespace_free() which is waiting for refc == 0 as ldlm_namespace_unregister() drops refc.
parent 39a7c4ac
No related branches found
No related tags found
No related merge requests found
......@@ -553,6 +553,9 @@ void ldlm_namespace_free_prior(struct ldlm_namespace *ns,
return;
}
/* Remove @ns from list. */
ldlm_namespace_unregister(ns, ns->ns_client);
/* Can fail with -EINTR when force == 0 in which case try harder */
rc = __ldlm_namespace_free(ns, force);
if (rc != ELDLM_OK) {
......@@ -577,8 +580,12 @@ void ldlm_namespace_free_post(struct ldlm_namespace *ns)
return;
}
/* Remove @ns from list. */
ldlm_namespace_unregister(ns, ns->ns_client);
/*
* Fini pool _before_ parent proc dir is removed. This is important as
* ldlm_pool_fini() removes own proc dir which is child to @dir. Removing
* it after @dir may cause oops.
*/
ldlm_pool_fini(&ns->ns_pool);
#ifdef LPROCFS
{
struct proc_dir_entry *dir;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment