summaryrefslogtreecommitdiffstats
path: root/sys/netinet/in.c
diff options
context:
space:
mode:
authorwollman <wollman@FreeBSD.org>1997-02-13 19:46:45 +0000
committerwollman <wollman@FreeBSD.org>1997-02-13 19:46:45 +0000
commit8f1bd632d4528e09dc9ca0ed45397ded3364d354 (patch)
tree754e6568b416e501652bc6bb3e1c72d391ec0257 /sys/netinet/in.c
parent1f8c9c194a905535c832a0021936cf4734355267 (diff)
downloadFreeBSD-src-8f1bd632d4528e09dc9ca0ed45397ded3364d354.zip
FreeBSD-src-8f1bd632d4528e09dc9ca0ed45397ded3364d354.tar.gz
Provide PRC_IFDOWN and PRC_IFUP support for IP. Now, when an interface
is administratively downed, all routes to that interface (including the interface route itself) which are not static will be deleted. When it comes back up, and addresses remaining will have their interface routes re-added. This solves the problem where, for example, an Ethernet interface is downed by traffic continues to flow by way of ARP entries.
Diffstat (limited to 'sys/netinet/in.c')
-rw-r--r--sys/netinet/in.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/netinet/in.c b/sys/netinet/in.c
index a52ec77..60bf97a 100644
--- a/sys/netinet/in.c
+++ b/sys/netinet/in.c
@@ -58,7 +58,6 @@
static void in_socktrim __P((struct sockaddr_in *));
static int in_ifinit __P((struct ifnet *,
struct in_ifaddr *, struct sockaddr_in *, int));
-static void in_ifscrub __P((struct ifnet *, struct in_ifaddr *));
static int subnetsarelocal = 0;
SYSCTL_INT(_net_inet_ip, OID_AUTO, subnets_are_local, CTLFLAG_RW,
@@ -366,7 +365,7 @@ in_control(so, cmd, data, ifp)
/*
* Delete any existing route for an interface.
*/
-static void
+void
in_ifscrub(ifp, ia)
register struct ifnet *ifp;
register struct in_ifaddr *ia;
OpenPOWER on IntegriCloud