Deleted Added
full compact
bpfdesc.h (153151) bpfdesc.h (159180)
1/*-
2 * Copyright (c) 1990, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from the Stanford/CMU enet packet filter,
6 * (net/enet.c) distributed as part of 4.3BSD, and code contributed
7 * to Berkeley by Steven McCanne and Van Jacobson both of Lawrence
8 * Berkeley Laboratory.

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

28 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
29 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 * SUCH DAMAGE.
33 *
34 * @(#)bpfdesc.h 8.1 (Berkeley) 6/10/93
35 *
1/*-
2 * Copyright (c) 1990, 1991, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from the Stanford/CMU enet packet filter,
6 * (net/enet.c) distributed as part of 4.3BSD, and code contributed
7 * to Berkeley by Steven McCanne and Van Jacobson both of Lawrence
8 * Berkeley Laboratory.

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

28 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
29 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
30 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
31 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
32 * SUCH DAMAGE.
33 *
34 * @(#)bpfdesc.h 8.1 (Berkeley) 6/10/93
35 *
36 * $FreeBSD: head/sys/net/bpfdesc.h 153151 2005-12-06 02:58:12Z jkim $
36 * $FreeBSD: head/sys/net/bpfdesc.h 159180 2006-06-02 19:59:33Z csjp $
37 */
38
39#ifndef _NET_BPFDESC_H_
40#define _NET_BPFDESC_H_
41
42#include <sys/callout.h>
43#include <sys/selinfo.h>
44#include <sys/queue.h>

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

115
116/* Test whether a BPF is ready for read(). */
117#define bpf_ready(bd) \
118 ((bd)->bd_hlen != 0 || \
119 (((bd)->bd_immediate || (bd)->bd_state == BPF_TIMED_OUT) && \
120 (bd)->bd_slen != 0))
121
122/*
37 */
38
39#ifndef _NET_BPFDESC_H_
40#define _NET_BPFDESC_H_
41
42#include <sys/callout.h>
43#include <sys/selinfo.h>
44#include <sys/queue.h>

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

115
116/* Test whether a BPF is ready for read(). */
117#define bpf_ready(bd) \
118 ((bd)->bd_hlen != 0 || \
119 (((bd)->bd_immediate || (bd)->bd_state == BPF_TIMED_OUT) && \
120 (bd)->bd_slen != 0))
121
122/*
123 * Descriptor associated with each attached hardware interface.
124 */
125struct bpf_if {
126 LIST_ENTRY(bpf_if) bif_next; /* list of all interfaces */
127 LIST_HEAD(, bpf_d) bif_dlist; /* descriptor list */
128 struct bpf_if **bif_driverp; /* pointer into softc */
129 u_int bif_dlt; /* link layer type */
130 u_int bif_hdrlen; /* length of header (with padding) */
131 struct ifnet *bif_ifp; /* corresponding interface */
132 struct mtx bif_mtx; /* mutex for interface */
133};
134
135/*
136 * External representation of the bpf descriptor
137 */
138struct xbpf_d {
139 u_char bd_promisc;
140 u_char bd_immediate;
141 int bd_hdrcmplt;
142 int bd_seesent;
143 int bd_async;

--- 16 unchanged lines hidden ---
123 * External representation of the bpf descriptor
124 */
125struct xbpf_d {
126 u_char bd_promisc;
127 u_char bd_immediate;
128 int bd_hdrcmplt;
129 int bd_seesent;
130 int bd_async;

--- 16 unchanged lines hidden ---