Lines Matching defs:dirh_e

143 	struct dirhash_entry *dirh_e;
153 while ((dirh_e = LIST_FIRST(&dirh->entries[hashline]))
155 LIST_REMOVE(dirh_e, next);
156 pool_put(&dirhash_entry_pool, dirh_e);
160 while ((dirh_e = LIST_FIRST(&dirh->free_entries)) != NULL) {
161 LIST_REMOVE(dirh_e, next);
162 pool_put(&dirhash_entry_pool, dirh_e);
235 struct dirhash_entry *dirh_e;
253 LIST_FOREACH(dirh_e, &dirh->entries[hashline], next) {
255 if (dirh_e->hashvalue != hashvalue)
257 if (dirh_e->offset != offset)
260 KASSERT(dirh_e->d_namlen == dirent->d_namlen);
261 KASSERT(dirh_e->entry_size == entry_size);
270 LIST_FOREACH(dirh_e, &dirh->free_entries, next) {
271 if (dirh_e->offset == offset) {
273 LIST_REMOVE(dirh_e, next);
274 pool_put(&dirhash_entry_pool, dirh_e);
299 dirh_e = pool_get(&dirhash_entry_pool, PR_WAITOK | PR_ZERO);
301 dirh_e->hashvalue = hashvalue;
302 dirh_e->offset = offset;
303 dirh_e->d_namlen = dirent->d_namlen;
304 dirh_e->entry_size = entry_size;
309 LIST_INSERT_HEAD(&dirh->entries[hashline], dirh_e, next);
315 struct dirhash_entry *dirh_e;
322 LIST_FOREACH(dirh_e, &dirh->free_entries, next) {
323 KASSERT(dirh_e->offset != offset);
328 dirh_e = pool_get(&dirhash_entry_pool, PR_WAITOK | PR_ZERO);
330 dirh_e->hashvalue = 0; /* not relevant */
331 dirh_e->offset = offset;
332 dirh_e->d_namlen = 0; /* not relevant */
333 dirh_e->entry_size = entry_size;
336 LIST_INSERT_HEAD(&dirh->free_entries, dirh_e, next);
345 struct dirhash_entry *dirh_e;
362 LIST_FOREACH(dirh_e, &dirh->entries[hashline], next) {
364 if (dirh_e->hashvalue != hashvalue)
366 if (dirh_e->offset != offset)
370 KASSERT(dirh_e->d_namlen == dirent->d_namlen);
371 KASSERT(dirh_e->entry_size == entry_size);
372 LIST_REMOVE(dirh_e, next);
394 struct dirhash_entry *dirh_e;
403 dirh_e = *result;
406 hashvalue = dirh_e->hashvalue;
407 dirh_e = LIST_NEXT(*result, next);
412 dirh_e = LIST_FIRST(&dirh->entries[hashline]);
415 for (; dirh_e; dirh_e = LIST_NEXT(dirh_e, next)) {
417 if (dirh_e->hashvalue != hashvalue)
419 if (dirh_e->d_namlen != d_namlen)
422 *result = dirh_e;
438 struct dirhash_entry *dirh_e;
446 dirh_e = LIST_NEXT(*result, next);
449 dirh_e = LIST_FIRST(&dirh->free_entries);
452 for (; dirh_e; dirh_e = LIST_NEXT(dirh_e, next)) {
454 if (dirh_e->entry_size < min_entrysize)
457 *result = dirh_e;
469 struct dirhash_entry *dirh_e;
474 LIST_FOREACH(dirh_e, &dirh->entries[hashline], next) {