* [PATCH] ipv4 addr: Send netlink notification for address label changes
@ 2008-06-05 0:02 Thomas Graf
2008-06-10 22:40 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Thomas Graf @ 2008-06-05 0:02 UTC (permalink / raw)
To: davem; +Cc: netdev
Makes people happy who try to keep a list of addresses up to date
by listening to notifications.
Signed-off-by: Thomas Graf <tgraf@suug.ch>
Index: net-2.6/net/ipv4/devinet.c
===================================================================
--- net-2.6.orig/net/ipv4/devinet.c 2008-06-04 23:14:26.000000000 +0200
+++ net-2.6/net/ipv4/devinet.c 2008-06-05 01:56:41.000000000 +0200
@@ -1013,7 +1013,7 @@
memcpy(old, ifa->ifa_label, IFNAMSIZ);
memcpy(ifa->ifa_label, dev->name, IFNAMSIZ);
if (named++ == 0)
- continue;
+ goto skip;
dot = strchr(old, ':');
if (dot == NULL) {
sprintf(old, ":%d", named);
@@ -1024,6 +1024,8 @@
} else {
strcpy(ifa->ifa_label + (IFNAMSIZ - strlen(dot) - 1), dot);
}
+skip:
+ rtmsg_ifa(RTM_NEWADDR, ifa, NULL, 0);
}
}
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] ipv4 addr: Send netlink notification for address label changes
2008-06-05 0:02 [PATCH] ipv4 addr: Send netlink notification for address label changes Thomas Graf
@ 2008-06-10 22:40 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2008-06-10 22:40 UTC (permalink / raw)
To: tgraf; +Cc: netdev
From: Thomas Graf <tgraf@suug.ch>
Date: Thu, 5 Jun 2008 02:02:03 +0200
> Makes people happy who try to keep a list of addresses up to date
> by listening to notifications.
>
> Signed-off-by: Thomas Graf <tgraf@suug.ch>
Applied to net-next-2.6, thanks!
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-06-10 22:41 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-05 0:02 [PATCH] ipv4 addr: Send netlink notification for address label changes Thomas Graf
2008-06-10 22:40 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).