diff options
author | Alexandr Nedvedicky <sashan@cvs.openbsd.org> | 2017-10-31 22:05:14 +0000 |
---|---|---|
committer | Alexandr Nedvedicky <sashan@cvs.openbsd.org> | 2017-10-31 22:05:14 +0000 |
commit | 613527dfe49c0c6ea091e60da77c17e56e4f4bd8 (patch) | |
tree | a08aaefaefe22a8dcbf024424de23beba2b00a48 /sys/net/if_pflow.c | |
parent | b64d329b96baa2f1c4581ad8ff98f807d13b1a72 (diff) |
- add one more softnet taskq
NOTE: code still runs with single softnet task. change definition of
SOFTNET_TASKS in net/if.c, if you want to have more than one softnet task
OK mpi@, OK phessler@
Diffstat (limited to 'sys/net/if_pflow.c')
-rw-r--r-- | sys/net/if_pflow.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/net/if_pflow.c b/sys/net/if_pflow.c index 38efb02be7e..9fb8ecf0ade 100644 --- a/sys/net/if_pflow.c +++ b/sys/net/if_pflow.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_pflow.c,v 1.84 2017/09/08 05:36:53 deraadt Exp $ */ +/* $OpenBSD: if_pflow.c,v 1.85 2017/10/31 22:05:12 sashan Exp $ */ /* * Copyright (c) 2011 Florian Obser <florian@narrans.de> @@ -286,7 +286,7 @@ pflow_clone_destroy(struct ifnet *ifp) if (timeout_initialized(&sc->sc_tmo_tmpl)) timeout_del(&sc->sc_tmo_tmpl); pflow_flush(sc); - task_del(softnettq, &sc->sc_outputtask); + task_del(net_tq(ifp->if_index), &sc->sc_outputtask); mq_purge(&sc->sc_outputqueue); m_freem(sc->send_nam); if (sc->so != NULL) { @@ -1087,7 +1087,7 @@ pflow_sendout_v5(struct pflow_softc *sc) h->time_sec = htonl(tv.tv_sec); /* XXX 2038 */ h->time_nanosec = htonl(tv.tv_nsec); if (mq_enqueue(&sc->sc_outputqueue, m) == 0) - task_add(softnettq, &sc->sc_outputtask); + task_add(net_tq(ifp->if_index), &sc->sc_outputtask); return (0); } @@ -1149,7 +1149,7 @@ pflow_sendout_ipfix(struct pflow_softc *sc, sa_family_t af) sc->sc_sequence += count; h10->observation_dom = htonl(PFLOW_ENGINE_TYPE); if (mq_enqueue(&sc->sc_outputqueue, m) == 0) - task_add(softnettq, &sc->sc_outputtask); + task_add(net_tq(ifp->if_index), &sc->sc_outputtask); return (0); } @@ -1191,7 +1191,7 @@ pflow_sendout_ipfix_tmpl(struct pflow_softc *sc) timeout_add_sec(&sc->sc_tmo_tmpl, PFLOW_TMPL_TIMEOUT); if (mq_enqueue(&sc->sc_outputqueue, m) == 0) - task_add(softnettq, &sc->sc_outputtask); + task_add(net_tq(ifp->if_index), &sc->sc_outputtask); return (0); } |