summaryrefslogtreecommitdiff
path: root/sys/netinet6
diff options
context:
space:
mode:
authorMartin Pieuchot <mpi@cvs.openbsd.org>2017-06-08 13:28:04 +0000
committerMartin Pieuchot <mpi@cvs.openbsd.org>2017-06-08 13:28:04 +0000
commit5fc5a3462c63d5310e4f3753d20d578b621c875c (patch)
treeae222496b6ee058a93cbfd4976f006c5e3e7f7db /sys/netinet6
parentcab67ace0d6b1ee2288f2cb6c0534158963a9584 (diff)
Notify userland when a new ND is reachable.
The same notification is already present in ARP. From Jan Klemkow, ok bluhm@
Diffstat (limited to 'sys/netinet6')
-rw-r--r--sys/netinet6/nd6_nbr.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/sys/netinet6/nd6_nbr.c b/sys/netinet6/nd6_nbr.c
index b44bc83de5d..fa8d3ed1472 100644
--- a/sys/netinet6/nd6_nbr.c
+++ b/sys/netinet6/nd6_nbr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: nd6_nbr.c,v 1.116 2017/05/16 12:24:04 mpi Exp $ */
+/* $OpenBSD: nd6_nbr.c,v 1.117 2017/06/08 13:28:03 mpi Exp $ */
/* $KAME: nd6_nbr.c,v 1.61 2001/02/10 16:06:14 jinmei Exp $ */
/*
@@ -715,6 +715,10 @@ nd6_na_input(struct mbuf *m, int off, int icmp6len)
if (is_solicited) {
ln->ln_state = ND6_LLINFO_REACHABLE;
ln->ln_byhint = 0;
+ /* Notify userland that a new ND entry is reachable. */
+ KERNEL_LOCK();
+ rtm_send(rt, RTM_RESOLVE, ifp->if_rdomain);
+ KERNEL_UNLOCK();
if (!ND6_LLINFO_PERMANENT(ln)) {
nd6_llinfo_settimer(ln,
ND_IFINFO(ifp)->reachable);