From 9b29d4543b0a589f5866aaf1ab753be91c4edd8d Mon Sep 17 00:00:00 2001 From: Johann Lombardi Date: Wed, 27 Jan 2010 15:27:07 +0100 Subject: [PATCH] b=21815 move assertion under write lock --- lustre/obdclass/class_hash.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lustre/obdclass/class_hash.c b/lustre/obdclass/class_hash.c index 6164f47..1af2c0f 100644 --- a/lustre/obdclass/class_hash.c +++ b/lustre/obdclass/class_hash.c @@ -350,9 +350,9 @@ lustre_hash_del(lustre_hash_t *lh, void *key, struct hlist_node *hnode) i = lh_hash(lh, key, lh->lh_cur_mask); lhb = lh->lh_buckets[i]; LASSERT(i <= lh->lh_cur_mask); - LASSERT(!hlist_unhashed(hnode)); write_lock(&lhb->lhb_rwlock); + LASSERT(!hlist_unhashed(hnode)); obj = __lustre_hash_bucket_del(lh, lhb, hnode); write_unlock(&lhb->lhb_rwlock); lh_read_unlock(lh); -- 1.8.3.1