From c0d6657c26f8a6ee4115c0f79221f51fe50488db Mon Sep 17 00:00:00 2001 From: Joris Vink Date: Fri, 26 Aug 2022 10:19:26 +0200 Subject: [PATCH] Fix a log message regarding worker count. The worker_count is incremented by 2 earlier to account for keymgr/acme but aren't actually workers that should count towards CPU pinning. So adjust the count when comparing to cpu_count when logging that there are more workers than cpus. --- src/worker.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/worker.c b/src/worker.c index 8ce7ea5..41539a9 100644 --- a/src/worker.c +++ b/src/worker.c @@ -132,7 +132,7 @@ kore_worker_init(void) sizeof(*accept_lock)); memset(kore_workers, 0, sizeof(struct kore_worker) * worker_count); - if (worker_count > cpu_count) + if ((worker_count - 2) > cpu_count) kore_log(LOG_NOTICE, "more worker processes than cpu cores"); /* Setup log buffers. */