Make some functions static

This commit is contained in:
ozaki-r 2016-12-11 07:36:55 +00:00
parent a205694d0a
commit 100c447a96
2 changed files with 17 additions and 14 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: nd6.h,v 1.73 2016/12/11 07:36:20 ozaki-r Exp $ */
/* $NetBSD: nd6.h,v 1.74 2016/12/11 07:36:55 ozaki-r Exp $ */
/* $KAME: nd6.h,v 1.95 2002/06/08 11:31:06 itojun Exp $ */
/*
@ -434,18 +434,12 @@ void nd6_dad_duplicated(struct ifaddr *);
/* nd6_rtr.c */
void nd6_rs_input(struct mbuf *, int, int);
void nd6_ra_input(struct mbuf *, int, int);
void defrouter_addreq(struct nd_defrouter *);
void defrouter_reset(void);
void defrouter_select(void);
void defrtrlist_del(struct nd_defrouter *, struct in6_ifextra *);
void prelist_remove(struct nd_prefix *);
int nd6_prelist_add(struct nd_prefixctl *, struct nd_defrouter *,
struct nd_prefix **);
int nd6_prefix_onlink(struct nd_prefix *);
int nd6_prefix_offlink(struct nd_prefix *);
void pfxlist_onlink_check(void);
struct nd_defrouter *defrouter_lookup(const struct in6_addr *, struct ifnet *);
struct nd_prefix *nd6_prefix_lookup(struct nd_prefixctl *);
void rt6_flush(struct in6_addr *, struct ifnet *);
int nd6_setdefaultiface(int);
int in6_tmpifadd(const struct in6_ifaddr *, int, int);

View File

@ -1,4 +1,4 @@
/* $NetBSD: nd6_rtr.c,v 1.120 2016/11/15 01:50:06 ozaki-r Exp $ */
/* $NetBSD: nd6_rtr.c,v 1.121 2016/12/11 07:36:55 ozaki-r Exp $ */
/* $KAME: nd6_rtr.c,v 1.95 2001/02/07 08:09:47 itojun Exp $ */
/*
@ -31,7 +31,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: nd6_rtr.c,v 1.120 2016/11/15 01:50:06 ozaki-r Exp $");
__KERNEL_RCSID(0, "$NetBSD: nd6_rtr.c,v 1.121 2016/12/11 07:36:55 ozaki-r Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -73,6 +73,8 @@ static void pfxrtr_add(struct nd_prefix *, struct nd_defrouter *);
static void pfxrtr_del(struct nd_pfxrouter *);
static struct nd_pfxrouter *find_pfxlist_reachable_router
(struct nd_prefix *);
static void defrouter_addreq(struct nd_defrouter *);
static void defrouter_delreq(struct nd_defrouter *);
static int in6_init_prefix_ltimes(struct nd_prefix *);
@ -82,6 +84,12 @@ static void purge_detached(struct ifnet *);
static int rt6_deleteroute_matcher(struct rtentry *, void *);
static int nd6_prelist_add(struct nd_prefixctl *, struct nd_defrouter *,
struct nd_prefix **);
static int nd6_prefix_onlink(struct nd_prefix *);
static int nd6_prefix_offlink(struct nd_prefix *);
static struct nd_prefix *nd6_prefix_lookup(struct nd_prefixctl *);
extern int nd6_recalc_reachtm_interval;
static struct ifnet *nd6_defifp;
@ -444,7 +452,7 @@ nd6_ra_input(struct mbuf *m, int off, int icmp6len)
/*
* default router list processing sub routines
*/
void
static void
defrouter_addreq(struct nd_defrouter *newdr)
{
union {
@ -873,7 +881,7 @@ pfxrtr_del(struct nd_pfxrouter *pfr)
free(pfr, M_IP6NDP);
}
struct nd_prefix *
static struct nd_prefix *
nd6_prefix_lookup(struct nd_prefixctl *key)
{
struct nd_prefix *search;
@ -934,7 +942,8 @@ purge_detached(struct ifnet *ifp)
prelist_remove(pr);
}
}
int
static int
nd6_prelist_add(struct nd_prefixctl *prc, struct nd_defrouter *dr,
struct nd_prefix **newp)
{
@ -1649,7 +1658,7 @@ pfxlist_onlink_check(void)
}
}
int
static int
nd6_prefix_onlink(struct nd_prefix *pr)
{
struct ifaddr *ifa;
@ -1760,7 +1769,7 @@ nd6_prefix_onlink(struct nd_prefix *pr)
return (error);
}
int
static int
nd6_prefix_offlink(struct nd_prefix *pr)
{
int error = 0;