Whamcloud - gitweb
LU-607 Avoid race between ldlm_pools_shrink and ldlm_namespace_free
authorBobi Jam <bobijam@whamcloud.com>
Tue, 23 Aug 2011 13:23:10 +0000 (21:23 +0800)
committerJohann Lombardi <johann@whamcloud.com>
Fri, 2 Sep 2011 22:16:36 +0000 (18:16 -0400)
commitba79e90a7028e2637e64367535715c81729f4cb2
tree0be67c49cbce64d7297ab7a97733d4d362364ee2
parentb113af75053c721c2540b1e4cac28599ddf84e22
LU-607 Avoid race between ldlm_pools_shrink and ldlm_namespace_free

ldlm_namespace_free removes namespace from list and free memory
without checking namespace's refcount while ldlm_pools_shrink might
get namespace from the list and start ldlm_pool_shrink() for it.

Bugzila: 24419
Author: Vladimir Saveliev <vladimir.saveliev@oracle.com>
Signed-off-by: Bobi Jam <bobijam@whamcloud.com>
Change-Id: I757204ad119927cacdb73db66f5e40ace50eeea8
Reviewed-on: http://review.whamcloud.com/1273
Tested-by: Hudson
Reviewed-by: Johann Lombardi <johann@whamcloud.com>
lustre/ldlm/ldlm_resource.c