Deleted Added
full compact
if_faith.c (83934) if_faith.c (85074)
1/* $KAME: if_faith.c,v 1.21 2001/02/20 07:59:26 itojun Exp $ */
2
3/*
4 * Copyright (c) 1982, 1986, 1993
5 * The Regents of the University of California. All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions

--- 18 unchanged lines hidden (view full) ---

27 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
28 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
29 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
30 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
31 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
32 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
33 * SUCH DAMAGE.
34 *
1/* $KAME: if_faith.c,v 1.21 2001/02/20 07:59:26 itojun Exp $ */
2
3/*
4 * Copyright (c) 1982, 1986, 1993
5 * The Regents of the University of California. All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions

--- 18 unchanged lines hidden (view full) ---

27 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
28 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
29 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
30 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
31 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
32 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
33 * SUCH DAMAGE.
34 *
35 * $FreeBSD: head/sys/net/if_faith.c 83934 2001-09-25 18:40:52Z brooks $
35 * $FreeBSD: head/sys/net/if_faith.c 85074 2001-10-17 18:07:05Z ru $
36 */
37/*
38 * derived from
39 * @(#)if_loop.c 8.1 (Berkeley) 6/10/93
40 * Id: if_loop.c,v 1.22 1996/06/19 16:24:10 wollman Exp
41 */
42
43/*

--- 47 unchanged lines hidden (view full) ---

91 struct ifnet sc_if; /* must be first */
92 struct resource *r_unit;
93 LIST_ENTRY(faith_softc) sc_list;
94};
95
96static int faithioctl __P((struct ifnet *, u_long, caddr_t));
97int faithoutput __P((struct ifnet *, struct mbuf *, struct sockaddr *,
98 struct rtentry *));
36 */
37/*
38 * derived from
39 * @(#)if_loop.c 8.1 (Berkeley) 6/10/93
40 * Id: if_loop.c,v 1.22 1996/06/19 16:24:10 wollman Exp
41 */
42
43/*

--- 47 unchanged lines hidden (view full) ---

91 struct ifnet sc_if; /* must be first */
92 struct resource *r_unit;
93 LIST_ENTRY(faith_softc) sc_list;
94};
95
96static int faithioctl __P((struct ifnet *, u_long, caddr_t));
97int faithoutput __P((struct ifnet *, struct mbuf *, struct sockaddr *,
98 struct rtentry *));
99static void faithrtrequest __P((int, struct rtentry *, struct sockaddr *));
99static void faithrtrequest __P((int, struct rtentry *, struct rt_addrinfo *));
100static int faithprefix __P((struct in6_addr *));
101
102static int faithmodevent __P((module_t, int, void *));
103
104static MALLOC_DEFINE(M_FAITH, FAITHNAME, "Firewall Assisted Tunnel Interface");
105static struct rman faithunits[1];
106LIST_HEAD(, faith_softc) faith_softc_list;
107

--- 198 unchanged lines hidden (view full) ---

306 ifp->if_ibytes += m->m_pkthdr.len;
307 (void) IF_HANDOFF(ifq, m, NULL);
308 schednetisr(isr);
309 return (0);
310}
311
312/* ARGSUSED */
313static void
100static int faithprefix __P((struct in6_addr *));
101
102static int faithmodevent __P((module_t, int, void *));
103
104static MALLOC_DEFINE(M_FAITH, FAITHNAME, "Firewall Assisted Tunnel Interface");
105static struct rman faithunits[1];
106LIST_HEAD(, faith_softc) faith_softc_list;
107

--- 198 unchanged lines hidden (view full) ---

306 ifp->if_ibytes += m->m_pkthdr.len;
307 (void) IF_HANDOFF(ifq, m, NULL);
308 schednetisr(isr);
309 return (0);
310}
311
312/* ARGSUSED */
313static void
314faithrtrequest(cmd, rt, sa)
314faithrtrequest(cmd, rt, info)
315 int cmd;
316 struct rtentry *rt;
315 int cmd;
316 struct rtentry *rt;
317 struct sockaddr *sa;
317 struct rt_addrinfo *info;
318{
319 if (rt) {
320 rt->rt_rmx.rmx_mtu = rt->rt_ifp->if_mtu; /* for ISO */
321 /*
322 * For optimal performance, the send and receive buffers
323 * should be at least twice the MTU plus a little more for
324 * overhead.
325 */

--- 98 unchanged lines hidden ---
318{
319 if (rt) {
320 rt->rt_rmx.rmx_mtu = rt->rt_ifp->if_mtu; /* for ISO */
321 /*
322 * For optimal performance, the send and receive buffers
323 * should be at least twice the MTU plus a little more for
324 * overhead.
325 */

--- 98 unchanged lines hidden ---