From 4c02c20c32d8b4e1948a67a0bc069e8ead49a701 Mon Sep 17 00:00:00 2001 From: Gleb Smirnoff Date: Wed, 5 Feb 2020 02:53:40 +0000 Subject: [PATCH] netgraph(4) callouts need to be executed in the network epoch. --- sys/netgraph/ng_base.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/netgraph/ng_base.c b/sys/netgraph/ng_base.c index 698696f1340..a009c33d09c 100644 --- a/sys/netgraph/ng_base.c +++ b/sys/netgraph/ng_base.c @@ -3772,11 +3772,14 @@ ng_send_fn2(node_p node, hook_p hook, item_p pitem, ng_item_fn2 *fn, void *arg1, static void ng_callout_trampoline(void *arg) { + struct epoch_tracker et; item_p item = arg; + NET_EPOCH_ENTER(et); CURVNET_SET(NGI_NODE(item)->nd_vnet); ng_snd_item(item, 0); CURVNET_RESTORE(); + NET_EPOCH_EXIT(et); } int