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

Function bpf_wakeup

freebsd/net/bpf.c:1114–1129  ·  view source on GitHub ↗

* If there are processes sleeping on this descriptor, wake them up. */

Source from the content-addressed store, hash-verified

1112 * If there are processes sleeping on this descriptor, wake them up.
1113 */
1114static __inline void
1115bpf_wakeup(struct bpf_d *d)
1116{
1117
1118 BPFD_LOCK_ASSERT(d);
1119 if (d->bd_state == BPF_WAITING) {
1120 callout_stop(&d->bd_callout);
1121 d->bd_state = BPF_IDLE;
1122 }
1123 wakeup(d);
1124 if (d->bd_async && d->bd_sig && d->bd_sigio)
1125 pgsigio(&d->bd_sigio, d->bd_sig, 0);
1126
1127 selwakeuppri(&d->bd_sel, PRINET);
1128 KNOTE_LOCKED(&d->bd_sel.si_note, 0);
1129}
1130
1131static void
1132bpf_timed_out(void *arg)

Callers 3

bpf_detachd_lockedFunction · 0.85
bpf_timed_outFunction · 0.85
catchpacketFunction · 0.85

Calls 3

selwakeuppriFunction · 0.85
wakeupFunction · 0.50
pgsigioFunction · 0.50

Tested by

no test coverage detected