From: Landen Date: Mon, 5 Jul 2010 15:34:26 +0000 (+0800) Subject: b=19390 remove unneeded spinlock X-Git-Tag: 2.0.0.51~39 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=d5372f3cd13f5a0b527553c6310057b5d7ed01a6;p=fs%2Flustre-release.git b=19390 remove unneeded spinlock i=landen i=johann --- diff --git a/lustre/obdfilter/filter_io_26.c b/lustre/obdfilter/filter_io_26.c index d6a356e..7b39704 100644 --- a/lustre/obdfilter/filter_io_26.c +++ b/lustre/obdfilter/filter_io_26.c @@ -657,6 +657,7 @@ int filter_commitrw_write(struct obd_export *exp, struct obdo *oa, cleanup_phase = 2; DQUOT_INIT(inode); + fsfilt_check_slow(obd, now, "quota init"); LOCK_INODE_MUTEX(inode); fsfilt_check_slow(obd, now, "i_mutex"); diff --git a/lustre/quota/quota_context.c b/lustre/quota/quota_context.c index 9f9035aa..5a1ebc2 100644 --- a/lustre/quota/quota_context.c +++ b/lustre/quota/quota_context.c @@ -1600,18 +1600,10 @@ lqs_key(cfs_hlist_node_t *hnode) static int lqs_compare(void *key, cfs_hlist_node_t *hnode) { - struct lustre_qunit_size *q; - int rc; - ENTRY; - - LASSERT(key); - q = cfs_hlist_entry(hnode, struct lustre_qunit_size, lqs_hash); - - cfs_spin_lock(&q->lqs_lock); - rc = (q->lqs_key == *((unsigned long long *)key)); - cfs_spin_unlock(&q->lqs_lock); + struct lustre_qunit_size *q = + cfs_hlist_entry(hnode, struct lustre_qunit_size, lqs_hash); - RETURN(rc); + RETURN(q->lqs_key == *((unsigned long long *)key)); } static void *