summaryrefslogtreecommitdiffstats
path: root/sys/netinet/in.c
diff options
context:
space:
mode:
authormelifaro <melifaro@FreeBSD.org>2015-09-27 04:54:29 +0000
committermelifaro <melifaro@FreeBSD.org>2015-09-27 04:54:29 +0000
commit4fed811000ba5b64a4b7fba73ed6c0590038ab48 (patch)
treeb8bd529bc94d7864472e3eae47cfdc76698c9f0b /sys/netinet/in.c
parent5d0f31382ff2eb2e0ef0a1e21c6edd686c7132a2 (diff)
downloadFreeBSD-src-4fed811000ba5b64a4b7fba73ed6c0590038ab48.zip
FreeBSD-src-4fed811000ba5b64a4b7fba73ed6c0590038ab48.tar.gz
rtsock requests for deleting interface address lles started to return EPERM
instead of old "ignore-and-return 0" in r287789. This broke arp -da / ndp -cn behavior (they exit on rtsock command failure). Fix this by translating LLE_IFADDR to RTM_PINNED flag, passing it to userland and making arp/ndp ignore these entries in batched delete. MFC after: 2 weeks
Diffstat (limited to 'sys/netinet/in.c')
-rw-r--r--sys/netinet/in.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/netinet/in.c b/sys/netinet/in.c
index b582ba1..1441936 100644
--- a/sys/netinet/in.c
+++ b/sys/netinet/in.c
@@ -1333,6 +1333,8 @@ in_lltable_dump_entry(struct lltable *llt, struct llentry *lle,
arpc.rtm.rtm_flags |= (RTF_HOST | RTF_LLDATA);
if (lle->la_flags & LLE_STATIC)
arpc.rtm.rtm_flags |= RTF_STATIC;
+ if (lle->la_flags & LLE_IFADDR)
+ arpc.rtm.rtm_flags |= RTF_PINNED;
arpc.rtm.rtm_index = ifp->if_index;
error = SYSCTL_OUT(wr, &arpc, sizeof(arpc));
OpenPOWER on IntegriCloud