Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys Remove unused arguments and the associated code from nd6...
details: https://anonhg.NetBSD.org/src/rev/4af616175560
branches: trunk
changeset: 339343:4af616175560
user: ozaki-r <ozaki-r%NetBSD.org@localhost>
date: Wed Jul 15 09:20:18 2015 +0000
description:
Remove unused arguments and the associated code from nd6_nud_hint()
from OpenBSD
diffstat:
sys/netinet/tcp_input.c | 6 +++---
sys/netinet6/nd6.c | 26 ++++++++------------------
sys/netinet6/nd6.h | 4 ++--
3 files changed, 13 insertions(+), 23 deletions(-)
diffs (102 lines):
diff -r 80e15a8c102f -r 4af616175560 sys/netinet/tcp_input.c
--- a/sys/netinet/tcp_input.c Wed Jul 15 08:49:15 2015 +0000
+++ b/sys/netinet/tcp_input.c Wed Jul 15 09:20:18 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: tcp_input.c,v 1.341 2015/05/24 15:43:45 rtr Exp $ */
+/* $NetBSD: tcp_input.c,v 1.342 2015/07/15 09:20:18 ozaki-r Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -148,7 +148,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: tcp_input.c,v 1.341 2015/05/24 15:43:45 rtr Exp $");
+__KERNEL_RCSID(0, "$NetBSD: tcp_input.c,v 1.342 2015/07/15 09:20:18 ozaki-r Exp $");
#include "opt_inet.h"
#include "opt_ipsec.h"
@@ -264,7 +264,7 @@
if (tp != NULL && tp->t_in6pcb != NULL && tp->t_family == AF_INET6 &&
(rt = rtcache_validate(&tp->t_in6pcb->in6p_route)) != NULL)
- nd6_nud_hint(rt, NULL, 0);
+ nd6_nud_hint(rt);
}
#else
static inline void
diff -r 80e15a8c102f -r 4af616175560 sys/netinet6/nd6.c
--- a/sys/netinet6/nd6.c Wed Jul 15 08:49:15 2015 +0000
+++ b/sys/netinet6/nd6.c Wed Jul 15 09:20:18 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: nd6.c,v 1.163 2015/06/30 08:31:42 ozaki-r Exp $ */
+/* $NetBSD: nd6.c,v 1.164 2015/07/15 09:20:18 ozaki-r Exp $ */
/* $KAME: nd6.c,v 1.279 2002/06/08 11:16:51 itojun Exp $ */
/*
@@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: nd6.c,v 1.163 2015/06/30 08:31:42 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: nd6.c,v 1.164 2015/07/15 09:20:18 ozaki-r Exp $");
#include "opt_net_mpsafe.h"
@@ -1165,20 +1165,12 @@
* XXX cost-effective methods?
*/
void
-nd6_nud_hint(struct rtentry *rt, struct in6_addr *dst6, int force)
+nd6_nud_hint(struct rtentry *rt)
{
struct llinfo_nd6 *ln;
- /*
- * If the caller specified "rt", use that. Otherwise, resolve the
- * routing table by supplied "dst6".
- */
- if (rt == NULL) {
- if (dst6 == NULL)
- return;
- if ((rt = nd6_lookup(dst6, 0, NULL)) == NULL)
- return;
- }
+ if (rt == NULL)
+ return;
if ((rt->rt_flags & RTF_GATEWAY) != 0 ||
(rt->rt_flags & RTF_LLINFO) == 0 ||
@@ -1196,11 +1188,9 @@
* if we get upper-layer reachability confirmation many times,
* it is possible we have false information.
*/
- if (!force) {
- ln->ln_byhint++;
- if (ln->ln_byhint > nd6_maxnudhint)
- return;
- }
+ ln->ln_byhint++;
+ if (ln->ln_byhint > nd6_maxnudhint)
+ return;
ln->ln_state = ND6_LLINFO_REACHABLE;
if (!ND6_LLINFO_PERMANENT(ln)) {
diff -r 80e15a8c102f -r 4af616175560 sys/netinet6/nd6.h
--- a/sys/netinet6/nd6.h Wed Jul 15 08:49:15 2015 +0000
+++ b/sys/netinet6/nd6.h Wed Jul 15 09:20:18 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: nd6.h,v 1.64 2015/02/25 12:45:34 roy Exp $ */
+/* $NetBSD: nd6.h,v 1.65 2015/07/15 09:20:18 ozaki-r Exp $ */
/* $KAME: nd6.h,v 1.95 2002/06/08 11:31:06 itojun Exp $ */
/*
@@ -417,7 +417,7 @@
void nd6_llinfo_settimer(struct llinfo_nd6 *, long);
void nd6_timer(void *);
void nd6_purge(struct ifnet *, struct in6_ifextra *);
-void nd6_nud_hint(struct rtentry *, struct in6_addr *, int);
+void nd6_nud_hint(struct rtentry *);
int nd6_resolve(struct ifnet *, struct rtentry *,
struct mbuf *, struct sockaddr *, u_char *);
void nd6_rtrequest(int, struct rtentry *, const struct rt_addrinfo *);
Home |
Main Index |
Thread Index |
Old Index