MCPcopy Create free account
hub / github.com/F-Stack/f-stack / zfs_znode_init

Function zfs_znode_init

freebsd/contrib/openzfs/module/os/linux/zfs/zfs_znode.c:180–197  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

178}
179
180void
181zfs_znode_init(void)
182{
183 /*
184 * Initialize zcache. The KMC_SLAB hint is used in order that it be
185 * backed by kmalloc() when on the Linux slab in order that any
186 * wait_on_bit() operations on the related inode operate properly.
187 */
188 ASSERT(znode_cache == NULL);
189 znode_cache = kmem_cache_create("zfs_znode_cache",
190 sizeof (znode_t), 0, zfs_znode_cache_constructor,
191 zfs_znode_cache_destructor, NULL, NULL, NULL, KMC_SLAB);
192
193 ASSERT(znode_hold_cache == NULL);
194 znode_hold_cache = kmem_cache_create("zfs_znode_hold_cache",
195 sizeof (znode_hold_t), 0, zfs_znode_hold_cache_constructor,
196 zfs_znode_hold_cache_destructor, NULL, NULL, NULL, 0);
197}
198
199void
200zfs_znode_fini(void)

Callers 1

zfs_initFunction · 0.70

Calls 1

kmem_cache_createFunction · 0.85

Tested by

no test coverage detected