From: Lai Jiangshan Date: Wed, 21 Dec 2011 14:29:12 +0000 (-0500) Subject: rculfhash: remove unneeded conversion X-Git-Tag: v0.7.0~43^2~5 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=709bacf9834b5007ec04aad9195ec060b9e27b67;p=userspace-rcu.git rculfhash: remove unneeded conversion Signed-off-by: Lai Jiangshan Signed-off-by: Mathieu Desnoyers --- diff --git a/rculfhash.c b/rculfhash.c index c1ff314..958982b 100644 --- a/rculfhash.c +++ b/rculfhash.c @@ -1471,7 +1471,7 @@ void cds_lfht_add(struct cds_lfht *ht, unsigned long hash, { unsigned long size; - node->reverse_hash = bit_reverse_ulong((unsigned long) hash); + node->reverse_hash = bit_reverse_ulong(hash); size = rcu_dereference(ht->size); _cds_lfht_add(ht, NULL, NULL, size, node, NULL, 0); ht_count_add(ht, size, hash); @@ -1486,7 +1486,7 @@ struct cds_lfht_node *cds_lfht_add_unique(struct cds_lfht *ht, unsigned long size; struct cds_lfht_iter iter; - node->reverse_hash = bit_reverse_ulong((unsigned long) hash); + node->reverse_hash = bit_reverse_ulong(hash); size = rcu_dereference(ht->size); _cds_lfht_add(ht, match, key, size, node, &iter, 0); if (iter.node == node) @@ -1503,7 +1503,7 @@ struct cds_lfht_node *cds_lfht_add_replace(struct cds_lfht *ht, unsigned long size; struct cds_lfht_iter iter; - node->reverse_hash = bit_reverse_ulong((unsigned long) hash); + node->reverse_hash = bit_reverse_ulong(hash); size = rcu_dereference(ht->size); for (;;) { _cds_lfht_add(ht, match, key, size, node, &iter, 0); @@ -1526,7 +1526,7 @@ int cds_lfht_replace(struct cds_lfht *ht, { unsigned long size; - new_node->reverse_hash = bit_reverse_ulong((unsigned long) hash); + new_node->reverse_hash = bit_reverse_ulong(hash); if (!old_iter->node) return -ENOENT; if (caa_unlikely(old_iter->node->reverse_hash != new_node->reverse_hash))