Lines Matching refs:dirhash
38 #include <sys/dirhash.h>
54 * The locking protocol of the dirhash structures is fairly simple:
60 * The dirhash structure is considered part of the vnode/inode structure and
63 * The dirhash entries are considered part of the dirhash structure and thus
74 static TAILQ_HEAD(_dirhash, dirhash) dirhash_queue;
84 /* initialise dirhash queue */
87 /* init dirhash pools */
88 sz = sizeof(struct dirhash);
105 CTLTYPE_NODE, "dirhash", NULL,
111 SYSCTL_DESCR("current dirhash memory usage"),
117 SYSCTL_DESCR("maximum dirhash memory usage"),
137 * generic dirhash implementation
141 dirhash_purge_entries(struct dirhash *dirh)
174 dirhash_purge(struct dirhash **dirhp)
176 struct dirhash *dirh = *dirhp;
194 dirhash_get(struct dirhash **dirhp)
196 struct dirhash *dirh;
199 /* if no dirhash was given, allocate one */
208 /* implement LRU on the dirhash queue */
222 dirhash_put(struct dirhash *dirh)
231 dirhash_enter(struct dirhash *dirh,
234 struct dirhash *del_dirh, *prev_dirh;
239 /* make sure we have a dirhash to work on */
265 DPRINTF(("dirhash enter %"PRIu64", %d, %d for `%*.*s`\n",
279 /* ensure we are not passing the dirhash limit */
313 dirhash_enter_freed(struct dirhash *dirh, uint64_t offset, uint32_t entry_size)
317 /* make sure we have a dirhash to work on */
326 DPRINTF(("dirhash enter FREED %"PRIu64", %d\n",
342 dirhash_remove(struct dirhash *dirh, struct dirent *dirent,
348 DPRINTF(("dirhash remove %"PRIu64", %d for `%*.*s`\n",
352 /* make sure we have a dirhash to work on */
391 dirhash_lookup(struct dirhash *dirh, const char *d_name, int d_namlen,
397 /* make sure we have a dirhash to work on */
435 dirhash_lookup_freed(struct dirhash *dirh, uint32_t min_entrysize,
440 /* make sure we have a dirhash to work on */
466 dirhash_dir_isempty(struct dirhash *dirh)