Added in 2017 to
Reduce contention on the NET_LOCK() by moving the nd6 address expiration
task to the `softnettq`.
This should no longer be needed thanks to sys/net/if.c r1.652 in 2022:
Activate parallel IP forwarding. Start 4 softnet tasks. Limit the
usage to the number of CPUs.
Nothing in nd6_expire() or nd6_expire_timer_update() requires protection by
the kernel lock.
The interface list and per-interface address lists remain protected by the
net lock.
Tests by Hrvoje
OK mpi
-/* $OpenBSD: nd6.c,v 1.248 2022/09/09 12:05:52 kn Exp $ */
+/* $OpenBSD: nd6.c,v 1.249 2022/11/07 10:45:39 kn Exp $ */
/* $KAME: nd6.c,v 1.280 2002/06/08 19:52:07 itojun Exp $ */
/*
time_t expire_time = INT64_MAX;
int secs;
- KERNEL_ASSERT_LOCKED();
-
if (ia6->ia6_lifetime.ia6t_vltime != ND6_INFINITE_LIFETIME)
expire_time = ia6->ia6_lifetime.ia6t_expire;
{
struct ifnet *ifp;
- KERNEL_LOCK();
NET_LOCK();
TAILQ_FOREACH(ifp, &ifnetlist, if_list) {
}
NET_UNLOCK();
- KERNEL_UNLOCK();
}
void