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

Function kqueue_fo_release

freebsd/kern/kern_event.c:1356–1371  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1354}
1355
1356static void
1357kqueue_fo_release(int filt)
1358{
1359
1360 if (filt > 0 || filt + EVFILT_SYSCOUNT < 0)
1361 return;
1362
1363 if (sysfilt_ops[~filt].for_nolock)
1364 return;
1365
1366 mtx_lock(&filterops_lock);
1367 KASSERT(sysfilt_ops[~filt].for_refcnt > 0,
1368 ("filter object refcount not valid on release"));
1369 sysfilt_ops[~filt].for_refcnt--;
1370 mtx_unlock(&filterops_lock);
1371}
1372
1373/*
1374 * A ref to kq (obtained via kqueue_acquire) must be held.

Callers 2

kqueue_registerFunction · 0.85
knote_drop_detachedFunction · 0.85

Calls 2

mtx_lockFunction · 0.70
mtx_unlockFunction · 0.70

Tested by

no test coverage detected