Deleted Added
full compact
if_var.h (200805) if_var.h (201282)
1/*-
2 * Copyright (c) 1982, 1986, 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 * SUCH DAMAGE.
28 *
29 * From: @(#)if.h 8.1 (Berkeley) 6/10/93
1/*-
2 * Copyright (c) 1982, 1986, 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
27 * SUCH DAMAGE.
28 *
29 * From: @(#)if.h 8.1 (Berkeley) 6/10/93
30 * $FreeBSD: head/sys/net/if_var.h 200805 2009-12-21 20:09:19Z jhb $
30 * $FreeBSD: head/sys/net/if_var.h 201282 2009-12-30 21:35:34Z qingli $
31 */
32
33#ifndef _NET_IF_VAR_H_
34#define _NET_IF_VAR_H_
35
36/*
37 * Structures defining a network interface, providing a packet
38 * transport mechanism (ala level 0 of the PUP protocols).

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

705 u_short ifa_flags; /* mostly rt_flags for cloning */
706 u_int ifa_refcnt; /* references to this structure */
707 int ifa_metric; /* cost of going out this interface */
708 int (*ifa_claim_addr) /* check if an addr goes to this if */
709 (struct ifaddr *, struct sockaddr *);
710 struct mtx ifa_mtx;
711};
712#define IFA_ROUTE RTF_UP /* route installed */
31 */
32
33#ifndef _NET_IF_VAR_H_
34#define _NET_IF_VAR_H_
35
36/*
37 * Structures defining a network interface, providing a packet
38 * transport mechanism (ala level 0 of the PUP protocols).

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

705 u_short ifa_flags; /* mostly rt_flags for cloning */
706 u_int ifa_refcnt; /* references to this structure */
707 int ifa_metric; /* cost of going out this interface */
708 int (*ifa_claim_addr) /* check if an addr goes to this if */
709 (struct ifaddr *, struct sockaddr *);
710 struct mtx ifa_mtx;
711};
712#define IFA_ROUTE RTF_UP /* route installed */
713#define IFA_RTSELF RTF_HOST /* loopback route to self installed */
713
714/* for compatibility with other BSDs */
715#define ifa_list ifa_link
716
717#ifdef _KERNEL
718#define IFA_LOCK(ifa) mtx_lock(&(ifa)->ifa_mtx)
719#define IFA_UNLOCK(ifa) mtx_unlock(&(ifa)->ifa_mtx)
720

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

838void if_initname(struct ifnet *, const char *, int);
839void if_link_state_change(struct ifnet *, int);
840int if_printf(struct ifnet *, const char *, ...) __printflike(2, 3);
841void if_qflush(struct ifnet *);
842void if_ref(struct ifnet *);
843void if_rele(struct ifnet *);
844int if_setlladdr(struct ifnet *, const u_char *, int);
845void if_up(struct ifnet *);
714
715/* for compatibility with other BSDs */
716#define ifa_list ifa_link
717
718#ifdef _KERNEL
719#define IFA_LOCK(ifa) mtx_lock(&(ifa)->ifa_mtx)
720#define IFA_UNLOCK(ifa) mtx_unlock(&(ifa)->ifa_mtx)
721

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

839void if_initname(struct ifnet *, const char *, int);
840void if_link_state_change(struct ifnet *, int);
841int if_printf(struct ifnet *, const char *, ...) __printflike(2, 3);
842void if_qflush(struct ifnet *);
843void if_ref(struct ifnet *);
844void if_rele(struct ifnet *);
845int if_setlladdr(struct ifnet *, const u_char *, int);
846void if_up(struct ifnet *);
847/*void ifinit(void);*/ /* declared in systm.h for main() */
846int ifioctl(struct socket *, u_long, caddr_t, struct thread *);
847int ifpromisc(struct ifnet *, int);
848struct ifnet *ifunit(const char *);
849struct ifnet *ifunit_ref(const char *);
850
851void ifq_init(struct ifaltq *, struct ifnet *ifp);
852void ifq_delete(struct ifaltq *);
853

--- 34 unchanged lines hidden ---
848int ifioctl(struct socket *, u_long, caddr_t, struct thread *);
849int ifpromisc(struct ifnet *, int);
850struct ifnet *ifunit(const char *);
851struct ifnet *ifunit_ref(const char *);
852
853void ifq_init(struct ifaltq *, struct ifnet *ifp);
854void ifq_delete(struct ifaltq *);
855

--- 34 unchanged lines hidden ---