summaryrefslogtreecommitdiff
path: root/sys/net
diff options
context:
space:
mode:
authorKlemens Nanni <kn@cvs.openbsd.org>2022-11-08 17:57:48 +0000
committerKlemens Nanni <kn@cvs.openbsd.org>2022-11-08 17:57:48 +0000
commit5905d045fae279bffca84cbca31003f02d7d8a2c (patch)
treeab9683706c6b89707925a160c6602b81d04f57ab /sys/net
parent737f2a5c9e4de8948635de3e4dfc88869eb0a958 (diff)
Unlock SIOCIFGCLONERS
ifconfig(8) -C is the only user in base and the if_clone_attach() comment explains how this list is being built during autoconf(9). After that it is only ever read. Multiple threads may traverse the list in parallel and reading the `int' count is atomic. OK mvs
Diffstat (limited to 'sys/net')
-rw-r--r--sys/net/if.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/sys/net/if.c b/sys/net/if.c
index 74c97ecdeb4..99c19721a74 100644
--- a/sys/net/if.c
+++ b/sys/net/if.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if.c,v 1.668 2022/11/08 17:57:14 kn Exp $ */
+/* $OpenBSD: if.c,v 1.669 2022/11/08 17:57:47 kn Exp $ */
/* $NetBSD: if.c,v 1.35 1996/05/07 05:26:04 thorpej Exp $ */
/*
@@ -2435,9 +2435,7 @@ ifioctl_get(u_long cmd, caddr_t data)
KERNEL_UNLOCK();
return (error);
case SIOCIFGCLONERS:
- KERNEL_LOCK();
error = if_clone_list((struct if_clonereq *)data);
- KERNEL_UNLOCK();
return (error);
case SIOCGIFGMEMB:
KERNEL_LOCK();