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

Function gbincore_unlocked

freebsd/kern/vfs_subr.c:2436–2446  ·  view source on GitHub ↗

* Look up a buf using the buffer tries, without the bufobj lock. This relies * on SMR for safe lookup, and bufs being in a no-free zone to provide type * stability of the result. Like other lockless lookups, the found buf may * already be invalid by the time this function returns. */

Source from the content-addressed store, hash-verified

2434 * already be invalid by the time this function returns.
2435 */
2436struct buf *
2437gbincore_unlocked(struct bufobj *bo, daddr_t lblkno)
2438{
2439 struct buf *bp;
2440
2441 ASSERT_BO_UNLOCKED(bo);
2442 bp = BUF_PCTRIE_LOOKUP_UNLOCKED(&bo->bo_clean.bv_root, lblkno);
2443 if (bp != NULL)
2444 return (bp);
2445 return (BUF_PCTRIE_LOOKUP_UNLOCKED(&bo->bo_dirty.bv_root, lblkno));
2446}
2447
2448/*
2449 * Associate a buffer with a vnode.

Callers 2

incoreFunction · 0.85
getblkxFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected