aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatt Dunwoodie <ncon@mail.noconroy.net>2019-09-22 17:18:04 +0200
committerMatt Dunwoodie <ncon@mail.noconroy.net>2019-09-22 17:18:04 +0200
commit1403bbd8d8745bed24aac69a3c9bdde27554cb7b (patch)
tree035df87c0c0638ed34d3947cdcc9d5b0377160cd
parentChange rx queues to use mpq (diff)
downloadwireguard-openbsd-1403bbd8d8745bed24aac69a3c9bdde27554cb7b.tar.xz
wireguard-openbsd-1403bbd8d8745bed24aac69a3c9bdde27554cb7b.zip
Set the number of threads to the ncpus
-rw-r--r--src/if_wg.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/if_wg.c b/src/if_wg.c
index e3512ff..c01ea01 100644
--- a/src/if_wg.c
+++ b/src/if_wg.c
@@ -1069,7 +1069,7 @@ wg_clone_create(struct if_clone * ifc, int unit)
fm_resize(&sc->sc_id_map, 1);
RB_INIT(&sc->sc_peer_tree);
- sc->sc_taskq = taskq_create("wg", 1, IPL_NET, TASKQ_MPSAFE);
+ sc->sc_taskq = taskq_create("wg", ncpus, IPL_NET, TASKQ_MPSAFE);
task_set(&sc->sc_tx_task, wg_tx_task_fn, &sc->sc_tx_queue);
task_set(&sc->sc_tx_slow_task, wg_tx_slow_task_fn, &sc->sc_tx_slow_queue);
task_set(&sc->sc_rx_task, wg_rx_task_fn, &sc->sc_rx_queue);