Lines Matching refs:hash
74 ht_find(struct ht *h, uint32_t hash) in ht_find() argument
80 result = ht_find_locked(h, hash); in ht_find()
86 ht_find_locked(struct ht *h, uint32_t hash) in ht_find_locked() argument
91 entry = &h->ht_entries[hash % h->ht_nentries]; in ht_find_locked()
94 if (item->hti_hash == hash) in ht_find_locked()
102 ht_add(struct ht *h, uint32_t hash, void *value) in ht_add() argument
111 entry = &h->ht_entries[hash % h->ht_nentries]; in ht_add()
114 if (item->hti_hash == hash) { in ht_add()
122 item->hti_hash = hash; in ht_add()
131 ht_remove(struct ht *h, uint32_t hash) in ht_remove() argument
138 result = ht_remove_locked(h, hash); in ht_remove()
144 ht_remove_locked(struct ht *h, uint32_t hash) in ht_remove_locked() argument
148 ssize_t slot = hash % h->ht_nentries; in ht_remove_locked()
153 if (item->hti_hash == hash) { in ht_remove_locked()