[Devel] [VZ10 v2 21/21] ve/sunrpc: Use kthread_create_on_node when !CONFIG_VE

Vladimir Riabchun vladimir.riabchun at virtuozzo.com
Fri May 15 23:02:01 MSK 2026


https://virtuozzo.atlassian.net/browse/VSTOR-130116

Feature: !CONFIG_VE build
Fixes: e1d796511194 ("ve/sunrpc/nfsd: containerize kthreads")
Signed-off-by: Vladimir Riabchun <vladimir.riabchun at virtuozzo.com>
---
 net/sunrpc/svc.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/net/sunrpc/svc.c b/net/sunrpc/svc.c
index bdafff0fb085..1a36491114c4 100644
--- a/net/sunrpc/svc.c
+++ b/net/sunrpc/svc.c
@@ -811,6 +811,7 @@ svc_start_kthreads(struct svc_serv *serv, struct svc_pool *pool, int nrservs)
 		if (!rqstp)
 			return -ENOMEM;
 
+#ifdef CONFIG_VE
 		if (serv->ve_virtualized) {
 			task = kthread_create_on_node_ve_flags(get_exec_env(),
 					0, serv->sv_threadfn, rqstp,
@@ -820,6 +821,11 @@ svc_start_kthreads(struct svc_serv *serv, struct svc_pool *pool, int nrservs)
 					serv->sv_threadfn, rqstp,
 					node, "%s", serv->sv_name);
 		}
+#else
+		task = kthread_create_on_node(
+				serv->sv_threadfn, rqstp,
+				node, "%s", serv->sv_name);
+#endif
 		if (IS_ERR(task)) {
 			svc_exit_thread(rqstp);
 			return PTR_ERR(task);
-- 
2.43.0



More information about the Devel mailing list