static u32 key_hashfn(struct rhashtable *ht, const struct bucket_table *tbl,
const void *key, u32 len)
{
- return ht->p.hashfn(key, len, tbl->hash_rnd) >> HASH_RESERVED_SPACE;
+ return rht_bucket_index(tbl, ht->p.hashfn(key, len, tbl->hash_rnd) >>
+ HASH_RESERVED_SPACE);
}
static u32 head_hashfn(struct rhashtable *ht,
tbl = rht_dereference_rcu(ht->tbl, ht);
hash = key_hashfn(ht, tbl, key, ht->p.key_len);
restart:
- rht_for_each_rcu(he, tbl, rht_bucket_index(tbl, hash)) {
+ rht_for_each_rcu(he, tbl, hash) {
if (!compare(rht_obj(ht, he), arg))
continue;
rcu_read_unlock();