Skip to contentSkip to conversation

net: ipv6: lower ndisc notifier priority below addrconf

PATCH Applied David Ahern 2 participants 2 messages Aug 8, 2017 – Aug 10, 2017

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net: ipv6: lower ndisc notifier priority below addrconf

ndisc_notify is used to send unsolicited neighbor advertisements (e.g., on a link up). Currently, the ndisc notifier is run before the addrconf notifer which means NA's are not sent for link-local addresses which are added by the addrconf notifier.

Fix by lowering the priority of the ndisc notifier. Setting the priority to ADDRCONF_NOTIFY_PRIORITY - 5 means it runs after addrconf and before the route notifier which is ADDRCONF_NOTIFY_PRIORITY - 10.

---
 net/ipv6/ndisc.c | 1 +
 1 file changed, 1 insertion(+)
net/ipv6/ndisc.c +1 -0
index 0327c1f2e6fc..5e338eb89509 100644
@@ -1779,6 +1779,7 @@ static int ndisc_netdev_event(struct notifier_block *this, unsigned long event,
 
 static struct notifier_block ndisc_netdev_notifier = {
 	.notifier_call = ndisc_netdev_event,
+	.priority = ADDRCONF_NOTIFY_PRIORITY - 5,
 };
 
 #ifdef CONFIG_SYSCTL
Signature · 1 line
2.9.3
maintainer Applied
#1 lore raw

From: David Ahern <[email protected]>
Date: Tue, 8 Aug 2017 15:51:02 -0600

Quoted 10 lines

ndisc_notify is used to send unsolicited neighbor advertisements (e.g., on a link up). Currently, the ndisc notifier is run before the addrconf notifer which means NA's are not sent for link-local addresses which are added by the addrconf notifier.

Fix by lowering the priority of the ndisc notifier. Setting the priority to ADDRCONF_NOTIFY_PRIORITY - 5 means it runs after addrconf and before the route notifier which is ADDRCONF_NOTIFY_PRIORITY - 10.

Applied, thanks David.