diff options
author | Ben Hutchings <bhutchings@solarflare.com> | 2011-04-15 09:47:51 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2011-04-18 02:36:03 -0400 |
commit | 7c89943236750537d26421d9bbb6f6575e2d1e1b (patch) | |
tree | dfbc9b11ddcd20757388b03e9925363c1e1764f3 /net | |
parent | 99606477a5888b0ead0284fecb13417b1da8e3af (diff) |
bonding, ipv4, ipv6, vlan: Handle NETDEV_BONDING_FAILOVER like NETDEV_NOTIFY_PEERS
It is undesirable for the bonding driver to be poking into higher
level protocols, and notifiers provide a way to avoid that. This does
mean removing the ability to configure reptitition of gratuitous ARPs
and unsolicited NAs.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/8021q/vlan.c | 3 | ||||
-rw-r--r-- | net/ipv4/devinet.c | 1 | ||||
-rw-r--r-- | net/ipv6/ndisc.c | 1 |
3 files changed, 4 insertions, 1 deletions
diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c index b2ff70fcf8ea..969e7004cf86 100644 --- a/net/8021q/vlan.c +++ b/net/8021q/vlan.c | |||
@@ -501,13 +501,14 @@ static int vlan_device_event(struct notifier_block *unused, unsigned long event, | |||
501 | return NOTIFY_BAD; | 501 | return NOTIFY_BAD; |
502 | 502 | ||
503 | case NETDEV_NOTIFY_PEERS: | 503 | case NETDEV_NOTIFY_PEERS: |
504 | case NETDEV_BONDING_FAILOVER: | ||
504 | /* Propagate to vlan devices */ | 505 | /* Propagate to vlan devices */ |
505 | for (i = 0; i < VLAN_N_VID; i++) { | 506 | for (i = 0; i < VLAN_N_VID; i++) { |
506 | vlandev = vlan_group_get_device(grp, i); | 507 | vlandev = vlan_group_get_device(grp, i); |
507 | if (!vlandev) | 508 | if (!vlandev) |
508 | continue; | 509 | continue; |
509 | 510 | ||
510 | call_netdevice_notifiers(NETDEV_NOTIFY_PEERS, vlandev); | 511 | call_netdevice_notifiers(event, vlandev); |
511 | } | 512 | } |
512 | break; | 513 | break; |
513 | } | 514 | } |
diff --git a/net/ipv4/devinet.c b/net/ipv4/devinet.c index 5345b0bee6df..acf553f95b5b 100644 --- a/net/ipv4/devinet.c +++ b/net/ipv4/devinet.c | |||
@@ -1203,6 +1203,7 @@ static int inetdev_event(struct notifier_block *this, unsigned long event, | |||
1203 | break; | 1203 | break; |
1204 | /* fall through */ | 1204 | /* fall through */ |
1205 | case NETDEV_NOTIFY_PEERS: | 1205 | case NETDEV_NOTIFY_PEERS: |
1206 | case NETDEV_BONDING_FAILOVER: | ||
1206 | /* Send gratuitous ARP to notify of link change */ | 1207 | /* Send gratuitous ARP to notify of link change */ |
1207 | inetdev_send_gratuitous_arp(dev, in_dev); | 1208 | inetdev_send_gratuitous_arp(dev, in_dev); |
1208 | break; | 1209 | break; |
diff --git a/net/ipv6/ndisc.c b/net/ipv6/ndisc.c index 62cbd15b4cde..01a0ffc7b402 100644 --- a/net/ipv6/ndisc.c +++ b/net/ipv6/ndisc.c | |||
@@ -1747,6 +1747,7 @@ static int ndisc_netdev_event(struct notifier_block *this, unsigned long event, | |||
1747 | fib6_run_gc(~0UL, net); | 1747 | fib6_run_gc(~0UL, net); |
1748 | break; | 1748 | break; |
1749 | case NETDEV_NOTIFY_PEERS: | 1749 | case NETDEV_NOTIFY_PEERS: |
1750 | case NETDEV_BONDING_FAILOVER: | ||
1750 | ndisc_send_unsol_na(dev); | 1751 | ndisc_send_unsol_na(dev); |
1751 | break; | 1752 | break; |
1752 | default: | 1753 | default: |