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

Function pfsync_undefer_state

freebsd/netpfil/pf/if_pfsync.c:1847–1868  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1845}
1846
1847static void
1848pfsync_undefer_state(struct pf_state *st, int drop)
1849{
1850 struct pfsync_softc *sc = V_pfsyncif;
1851 struct pfsync_deferral *pd;
1852 struct pfsync_bucket *b = pfsync_get_bucket(sc, st);
1853
1854 PFSYNC_BUCKET_LOCK(b);
1855
1856 TAILQ_FOREACH(pd, &b->b_deferrals, pd_entry) {
1857 if (pd->pd_st == st) {
1858 if (callout_stop(&pd->pd_tmo) > 0)
1859 pfsync_undefer(pd, drop);
1860
1861 PFSYNC_BUCKET_UNLOCK(b);
1862 return;
1863 }
1864 }
1865 PFSYNC_BUCKET_UNLOCK(b);
1866
1867 panic("%s: unable to find deferred state", __func__);
1868}
1869
1870static struct pfsync_bucket*
1871pfsync_get_bucket(struct pfsync_softc *sc, struct pf_state *st)

Callers 5

pfsync_in_iackFunction · 0.85
pfsync_in_updFunction · 0.85
pfsync_in_upd_cFunction · 0.85
pfsync_update_stateFunction · 0.85
pfsync_delete_stateFunction · 0.85

Calls 3

pfsync_get_bucketFunction · 0.85
pfsync_undeferFunction · 0.85
panicFunction · 0.50

Tested by

no test coverage detected