]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
ipv6: make addrconf_wq single threaded
authorEric Dumazet <edumazet@google.com>
Thu, 1 Feb 2024 17:30:31 +0000 (17:30 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 24 Jul 2025 06:53:20 +0000 (08:53 +0200)
commit dfd2ee086a63c730022cb095576a8b3a5a752109 upstream.

Both addrconf_verify_work() and addrconf_dad_work() acquire rtnl,
there is no point trying to have one thread per cpu.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: David Ahern <dsahern@kernel.org>
Link: https://lore.kernel.org/r/20240201173031.3654257-1-edumazet@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Brett A C Sheffield <bacs@librecast.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/ipv6/addrconf.c

index 74f7f3e8d9608385c2d267345b36795686fc645e..f6188bd9f55ba6460481a502a58f5063d4fe6733 100644 (file)
@@ -7383,7 +7383,8 @@ int __init addrconf_init(void)
        if (err < 0)
                goto out_addrlabel;
 
-       addrconf_wq = create_workqueue("ipv6_addrconf");
+       /* All works using addrconf_wq need to lock rtnl. */
+       addrconf_wq = create_singlethread_workqueue("ipv6_addrconf");
        if (!addrconf_wq) {
                err = -ENOMEM;
                goto out_nowq;