Deleted Added
full compact
if.h (97024) if.h (97289)
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

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

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)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

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

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)if.h 8.1 (Berkeley) 6/10/93
34 * $FreeBSD: head/sys/net/if.h 97024 2002-05-20 22:48:39Z iedowse $
34 * $FreeBSD: head/sys/net/if.h 97289 2002-05-25 20:17:04Z brooks $
35 */
36
37#ifndef _NET_IF_H_
38#define _NET_IF_H_
39
40#ifdef _KERNEL
41#include <sys/queue.h>
42#endif

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

62#ifdef _KERNEL
63/*
64 * Structure describing a `cloning' interface.
65 */
66struct if_clone {
67 LIST_ENTRY(if_clone) ifc_list; /* on list of cloners */
68 const char *ifc_name; /* name of device, e.g. `gif' */
69 size_t ifc_namelen; /* length of name */
35 */
36
37#ifndef _NET_IF_H_
38#define _NET_IF_H_
39
40#ifdef _KERNEL
41#include <sys/queue.h>
42#endif

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

62#ifdef _KERNEL
63/*
64 * Structure describing a `cloning' interface.
65 */
66struct if_clone {
67 LIST_ENTRY(if_clone) ifc_list; /* on list of cloners */
68 const char *ifc_name; /* name of device, e.g. `gif' */
69 size_t ifc_namelen; /* length of name */
70 int ifc_minifs; /* minimum number of interfaces */
70 int ifc_maxunit; /* maximum unit number */
71 unsigned char *ifc_units; /* bitmap to handle units */
72 int ifc_bmlen; /* bitmap length */
73
74 int (*ifc_create)(struct if_clone *, int);
71 int ifc_maxunit; /* maximum unit number */
72 unsigned char *ifc_units; /* bitmap to handle units */
73 int ifc_bmlen; /* bitmap length */
74
75 int (*ifc_create)(struct if_clone *, int);
75 int (*ifc_destroy)(struct ifnet *);
76 void (*ifc_destroy)(struct ifnet *);
76};
77
77};
78
78#define IF_CLONE_INITIALIZER(name, create, destroy, maxunit) \
79 { { 0 }, name, sizeof(name) - 1, maxunit, NULL, 0, create, destroy }
79#define IF_CLONE_INITIALIZER(name, create, destroy, minifs, maxunit) \
80 { { 0 }, name, sizeof(name) - 1, minifs, maxunit, NULL, 0, create, destroy }
80#endif
81
82/*
83 * Structure used to query names of interface cloners.
84 */
85
86struct if_clonereq {
87 int ifcr_total; /* total cloners (out) */

--- 263 unchanged lines hidden ---
81#endif
82
83/*
84 * Structure used to query names of interface cloners.
85 */
86
87struct if_clonereq {
88 int ifcr_total; /* total cloners (out) */

--- 263 unchanged lines hidden ---