diff --git a/sys/net/if_arcsubr.c b/sys/net/if_arcsubr.c index a22e04ed7ac4..3a2033218985 100644 --- a/sys/net/if_arcsubr.c +++ b/sys/net/if_arcsubr.c @@ -1,4 +1,4 @@ -/* $NetBSD: if_arcsubr.c,v 1.1 1995/02/23 07:19:51 glass Exp $ */ +/* $NetBSD: if_arcsubr.c,v 1.2 1995/04/11 04:32:09 mycroft Exp $ */ /* * Copyright (c) 1994, 1995 Ignatios Souvatzis @@ -61,7 +61,6 @@ #include u_char arcbroadcastaddr = 0; -extern struct ifnet loif; #define senderr(e) { error = (e); goto bad;} diff --git a/sys/netccitt/if_x25subr.c b/sys/netccitt/if_x25subr.c index 763469de4040..09ec91f3906b 100644 --- a/sys/netccitt/if_x25subr.c +++ b/sys/netccitt/if_x25subr.c @@ -1,4 +1,4 @@ -/* $NetBSD: if_x25subr.c,v 1.6 1994/06/29 06:37:19 cgd Exp $ */ +/* $NetBSD: if_x25subr.c,v 1.7 1995/04/11 04:30:47 mycroft Exp $ */ /* * Copyright (c) 1990, 1993 @@ -73,7 +73,6 @@ int tp_incoming(); #include #endif -extern struct ifnet loif; struct llinfo_x25 llinfo_x25 = {&llinfo_x25, &llinfo_x25}; #ifndef _offsetof #define _offsetof(t, m) ((int)((caddr_t)&((t *)0)->m)) diff --git a/sys/netinet/if_arp.c b/sys/netinet/if_arp.c index 8bdc52dc1d96..e5a2b5690836 100644 --- a/sys/netinet/if_arp.c +++ b/sys/netinet/if_arp.c @@ -1,4 +1,4 @@ -/* $NetBSD: if_arp.c,v 1.20 1995/04/07 22:26:04 mycroft Exp $ */ +/* $NetBSD: if_arp.c,v 1.21 1995/04/11 04:30:52 mycroft Exp $ */ /* * Copyright (c) 1982, 1986, 1988, 1993 @@ -224,7 +224,6 @@ arp_rtrequest(req, rt, sa) LLADDR(SDL(gate)), SDL(gate)->sdl_alen = 6); if (useloopback) rt->rt_ifp = &loif; - } break; diff --git a/sys/netinet/if_ether.c b/sys/netinet/if_ether.c index 6bfd18b3d162..388a934e3389 100644 --- a/sys/netinet/if_ether.c +++ b/sys/netinet/if_ether.c @@ -1,4 +1,4 @@ -/* $NetBSD: if_ether.c,v 1.20 1995/04/07 22:26:04 mycroft Exp $ */ +/* $NetBSD: if_ether.c,v 1.21 1995/04/11 04:30:52 mycroft Exp $ */ /* * Copyright (c) 1982, 1986, 1988, 1993 @@ -224,7 +224,6 @@ arp_rtrequest(req, rt, sa) LLADDR(SDL(gate)), SDL(gate)->sdl_alen = 6); if (useloopback) rt->rt_ifp = &loif; - } break; diff --git a/sys/netinet/in.c b/sys/netinet/in.c index e4c0db6a7580..2a0e26bbb3cc 100644 --- a/sys/netinet/in.c +++ b/sys/netinet/in.c @@ -1,4 +1,4 @@ -/* $NetBSD: in.c,v 1.16 1995/04/10 00:06:57 mycroft Exp $ */ +/* $NetBSD: in.c,v 1.17 1995/04/11 04:30:55 mycroft Exp $ */ /* * Copyright (c) 1982, 1986, 1991, 1993 @@ -155,7 +155,6 @@ in_socktrim(ap) } int in_interfaces; /* number of external internet interfaces */ -extern struct ifnet loif; /* * Generic internet control operations (ioctl's). @@ -238,7 +237,7 @@ in_control(so, cmd, data, ifp) ia->ia_broadaddr.sin_family = AF_INET; } ia->ia_ifp = ifp; - if (ifp != &loif) + if ((ifp->if_flags & IFF_LOOPBACK) == 0) in_interfaces++; } break; diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c index 587201a9b002..61f7afd98c18 100644 --- a/sys/netinet/ip_output.c +++ b/sys/netinet/ip_output.c @@ -1,4 +1,4 @@ -/* $NetBSD: ip_output.c,v 1.19 1994/06/29 06:38:27 cgd Exp $ */ +/* $NetBSD: ip_output.c,v 1.20 1995/04/11 04:30:56 mycroft Exp $ */ /* * Copyright (c) 1982, 1986, 1988, 1990, 1993 @@ -159,7 +159,6 @@ ip_output(m0, opt, ro, flags, imo) } if (IN_MULTICAST(ntohl(ip->ip_dst.s_addr))) { struct in_multi *inm; - extern struct ifnet loif; m->m_flags |= M_MCAST; /* @@ -240,7 +239,7 @@ ip_output(m0, opt, ro, flags, imo) * loop back a copy if this host actually belongs to the * destination group on the loopback interface. */ - if (ip->ip_ttl == 0 || ifp == &loif) { + if (ip->ip_ttl == 0 || (ifp->if_flags & IFF_LOOPBACK) != 0) { m_freem(m); goto done; } diff --git a/sys/netiso/iso.c b/sys/netiso/iso.c index ccb490e44ecd..921e34379458 100644 --- a/sys/netiso/iso.c +++ b/sys/netiso/iso.c @@ -1,4 +1,4 @@ -/* $NetBSD: iso.c,v 1.8 1995/03/08 02:16:11 cgd Exp $ */ +/* $NetBSD: iso.c,v 1.9 1995/04/11 04:30:59 mycroft Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -91,7 +91,6 @@ SOFTWARE. #ifdef ISO int iso_interfaces = 0; /* number of external interfaces */ -extern struct ifnet loif; /* loopback interface */ int ether_output(); void llc_rtrequest(); @@ -478,7 +477,7 @@ iso_control(so, cmd, data, ifp) ia->ia_ifa.ifa_netmask = (struct sockaddr *)&ia->ia_sockmask; ia->ia_ifp = ifp; - if (ifp != &loif) + if ((ifp->if_flags & IFF_LOOPBACK) == 0) iso_interfaces++; } break;