Lines Matching refs:hash
196 static inline void free_hash_table(struct eth_hash_t *hash)
201 if (hash) {
202 if (hash->lsts) {
203 for (i = 0; i < hash->size; i++) {
205 dequeue_addr_from_hash_entry(&hash->lsts[i]);
209 dequeue_addr_from_hash_entry(&hash->
214 kfree(hash->lsts);
217 kfree(hash);
224 struct eth_hash_t *hash;
226 /* Allocate address hash table */
227 hash = kmalloc(sizeof(*hash), GFP_KERNEL);
228 if (!hash)
231 hash->size = size;
233 hash->lsts = kmalloc_array(hash->size, sizeof(struct list_head),
235 if (!hash->lsts) {
236 kfree(hash);
240 for (i = 0; i < hash->size; i++)
241 INIT_LIST_HEAD(&hash->lsts[i]);
243 return hash;