Lines Matching refs:cnode

90  * Initialize cnode hash table.
145 * Use the device, inum pair to find the incore cnode.
152 struct cnode *cp;
159 * If a cnode is in the process of being cleaned out or being
168 /* Wait if cnode is being created or reclaimed. */
198 * we need to check with the cnode lock held because
200 * lock on the cnode which would allow the node to be
221 * Use the device, fileid pair to snoop an incore cnode.
223 * A cnode can exists in chash even after it has been
225 * ENOENT if C_NOEXIST is set in the cnode's flag.
232 struct cnode *cp;
237 * If a cnode is in the process of being cleaned out or being
247 * Under normal circumstances, we would want to return ENOENT if a cnode is in
253 * If we didn't do this, then it would be possible for a cnode that is no longer backed
282 * Use the device, fileid pair to find the incore cnode.
283 * If no cnode if found one is created
287 * If the cnode is C_DELETED, then return NULL since that
290 * If the cnode is C_DELETED but also marked C_RENAMED, then that means
291 * the cnode was renamed over and a new entry exists in its place. The caller
293 * return NULL for the cnode, but also return GNV_CHASH_RENAMED in the output flags
296 struct cnode *
300 struct cnode *cp;
301 struct cnode *ncp = NULL;
307 * If a cnode is in the process of being cleaned out or being
318 * Wait if cnode is being created, attached to or reclaimed.
330 * The desired vnode isn't there so tag the cnode.
347 * this cnode and add it to the hash
350 FREE_ZONE(ncp, sizeof(struct cnode), M_HFSNODE);
360 * we need to check with the cnode lock held because
362 * lock on the cnode which would allow the node to be
365 * Don't return a cnode in this case since the inum
398 * Allocate a new cnode
406 MALLOC_ZONE(ncp, struct cnode *, sizeof(struct cnode), M_HFSNODE, M_WAITOK);
417 bzero(ncp, sizeof(struct cnode));
428 /* Insert the new cnode with it's H_ALLOC flag set */
439 hfs_chashwakeup(struct hfsmount *hfsmp, struct cnode *cp, int hflags)
458 hfs_chash_rehash(struct hfsmount *hfsmp, struct cnode *cp1, struct cnode *cp2)
472 * Remove a cnode from the hash table.
476 hfs_chashremove(struct hfsmount *hfsmp, struct cnode *cp)
496 * Remove a cnode from the hash table and wakeup any waiters.
500 hfs_chash_abort(struct hfsmount *hfsmp, struct cnode *cp)
518 * mark a cnode as in transition
522 hfs_chash_mark_in_transit(struct hfsmount *hfsmp, struct cnode *cp)
531 /* Search a cnode in the hash. This function does not return cnode which
533 * does not acquire the cnode hash mutex, and expects the caller to acquire it.
534 * On success, returns pointer to the cnode found. On failure, returns NULL.
537 struct cnode *
540 struct cnode *cp;
548 /* If cnode is being created or reclaimed, return error. */
556 /* Search a cnode corresponding to given device and ID in the hash. If the
557 * found cnode has kHFSHasChildLinkBit cleared, set it. If the cnode is not
558 * found, no new cnode is created and error is returned.
561 * -1 : The cnode was not found.
562 * 0 : The cnode was found, and the kHFSHasChildLinkBit was already set.
563 * 1 : The cnode was found, the kHFSHasChildLinkBit was not set, and the
571 struct cnode *cp;