Lines Matching refs:hash
74 ht_find(struct ht *h, uint32_t hash) in ht_find() argument
79 result = ht_find_locked(h, hash); in ht_find()
85 ht_find_locked(struct ht *h, uint32_t hash) in ht_find_locked() argument
90 entry = &h->ht_entries[hash % h->ht_nentries]; in ht_find_locked()
93 if (item->hti_hash == hash) in ht_find_locked()
101 ht_add(struct ht *h, uint32_t hash, void *value) in ht_add() argument
107 entry = &h->ht_entries[hash % h->ht_nentries]; in ht_add()
110 if (item->hti_hash == hash) { in ht_add()
118 item->hti_hash = hash; in ht_add()
127 ht_remove(struct ht *h, uint32_t hash) in ht_remove() argument
132 result = ht_remove_locked(h, hash); in ht_remove()
138 ht_remove_locked(struct ht *h, uint32_t hash) in ht_remove_locked() argument
142 ssize_t slot = hash % h->ht_nentries; in ht_remove_locked()
147 if (item->hti_hash == hash) { in ht_remove_locked()