summaryrefslogtreecommitdiffstats
path: root/net/ipv4/devinet.c
diff options
context:
space:
mode:
authorIan Campbell <Ian.Campbell@citrix.com>2010-05-26 00:09:42 +0000
committerDavid S. Miller <davem@davemloft.net>2010-05-31 00:27:44 -0700
commit06c4648d46d1b757d6b9591a86810be79818b60c (patch)
tree96f6e09a23071157d5b446853294b4564155ffee /net/ipv4/devinet.c
parent3f8dc2362fd43a0adee2f6f05bf1ac4d619675b6 (diff)
downloadop-kernel-dev-06c4648d46d1b757d6b9591a86810be79818b60c.zip
op-kernel-dev-06c4648d46d1b757d6b9591a86810be79818b60c.tar.gz
arp_notify: allow drivers to explicitly request a notification event.
Currently such notifications are only generated when the device comes up or the address changes. However one use case for these notifications is to enable faster network recovery after a virtual machine migration (by causing switches to relearn their MAC tables). A migration appears to the network stack as a temporary loss of carrier and therefore does not trigger either of the current conditions. Rather than adding carrier up as a trigger (which can cause issues when interfaces a flapping) simply add an interface which the driver can use to explicitly trigger the notification. Signed-off-by: Ian Campbell <ian.campbell@citrix.com> Cc: Stephen Hemminger <shemminger@linux-foundation.org> Cc: Jeremy Fitzhardinge <jeremy@goop.org> Cc: David S. Miller <davem@davemloft.net> Cc: netdev@vger.kernel.org Cc: stable@kernel.org Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/devinet.c')
-rw-r--r--net/ipv4/devinet.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/ipv4/devinet.c b/net/ipv4/devinet.c
index 382bc76..da14c49 100644
--- a/net/ipv4/devinet.c
+++ b/net/ipv4/devinet.c
@@ -1081,6 +1081,7 @@ static int inetdev_event(struct notifier_block *this, unsigned long event,
}
ip_mc_up(in_dev);
/* fall through */
+ case NETDEV_NOTIFY_PEERS:
case NETDEV_CHANGEADDR:
/* Send gratuitous ARP to notify of link change */
if (IN_DEV_ARP_NOTIFY(in_dev)) {
OpenPOWER on IntegriCloud