From d34b8991b4c156ff3281558dd8252d3787ae8d8b Mon Sep 17 00:00:00 2001 From: paul Date: Tue, 17 Jan 2006 18:03:04 +0000 Subject: [zebra] Record NEWADDR metric on PF_ROUTE, print CACHEINFO debug on netlink 2006-01-17 Paul Jakma * kernel_socket.c: (ifam_read) Read metric from RTM_NEWADDR. If interface is an alias, pass the alias as a label for connected_add_ipv{4,6}. * rt_netlink.c: (netlink_interface_addr) print out IFA_CACHEINFO info, if present, when debugging kernel messages. --- zebra/rt_netlink.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'zebra/rt_netlink.c') diff --git a/zebra/rt_netlink.c b/zebra/rt_netlink.c index 6e914087..f1c1a300 100644 --- a/zebra/rt_netlink.c +++ b/zebra/rt_netlink.c @@ -628,6 +628,13 @@ netlink_interface_addr (struct sockaddr_nl *snl, struct nlmsghdr *h) buf, BUFSIZ), ifa->ifa_prefixlen); if (tb[IFA_LABEL] && strcmp (ifp->name, RTA_DATA (tb[IFA_LABEL]))) zlog_debug (" IFA_LABEL %s", (char *)RTA_DATA (tb[IFA_LABEL])); + + if (tb[IFA_CACHEINFO]) + { + struct ifa_cacheinfo *ci = RTA_DATA (tb[IFA_CACHEINFO]); + zlog_debug (" IFA_CACHEINFO pref %d, valid %d", + ci->ifa_prefered, ci->ifa_valid); + } } if (tb[IFA_ADDRESS] == NULL) -- cgit v1.2.1