Deleted Added
full compact
bpf.c (212757) bpf.c (225177)
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.

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

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 * @(#)bpf.c 8.4 (Berkeley) 1/9/95
35 */
36
37#include <sys/cdefs.h>
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.

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

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 * @(#)bpf.c 8.4 (Berkeley) 1/9/95
35 */
36
37#include <sys/cdefs.h>
38__FBSDID("$FreeBSD: head/sys/net/bpf.c 212757 2010-09-16 18:37:33Z jkim $");
38__FBSDID("$FreeBSD: head/sys/net/bpf.c 225177 2011-08-25 15:51:54Z attilio $");
39
40#include "opt_bpf.h"
41#include "opt_compat.h"
42#include "opt_netgraph.h"
43
44#include <sys/types.h>
45#include <sys/param.h>
46#include <sys/systm.h>

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

647 callout_stop(&d->bd_callout);
648 d->bd_state = BPF_IDLE;
649 BPFD_UNLOCK(d);
650 funsetown(&d->bd_sigio);
651 mtx_lock(&bpf_mtx);
652 if (d->bd_bif)
653 bpf_detachd(d);
654 mtx_unlock(&bpf_mtx);
39
40#include "opt_bpf.h"
41#include "opt_compat.h"
42#include "opt_netgraph.h"
43
44#include <sys/types.h>
45#include <sys/param.h>
46#include <sys/systm.h>

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

647 callout_stop(&d->bd_callout);
648 d->bd_state = BPF_IDLE;
649 BPFD_UNLOCK(d);
650 funsetown(&d->bd_sigio);
651 mtx_lock(&bpf_mtx);
652 if (d->bd_bif)
653 bpf_detachd(d);
654 mtx_unlock(&bpf_mtx);
655 selwakeuppri(&d->bd_sel, PRINET);
656#ifdef MAC
657 mac_bpfdesc_destroy(d);
658#endif /* MAC */
655#ifdef MAC
656 mac_bpfdesc_destroy(d);
657#endif /* MAC */
658 seldrain(&d->bd_sel);
659 knlist_destroy(&d->bd_sel.si_note);
660 callout_drain(&d->bd_callout);
661 bpf_freed(d);
662 free(d, M_BPF);
663}
664
665/*
666 * Open ethernet device. Returns ENXIO for illegal minor device number,

--- 1880 unchanged lines hidden ---
659 knlist_destroy(&d->bd_sel.si_note);
660 callout_drain(&d->bd_callout);
661 bpf_freed(d);
662 free(d, M_BPF);
663}
664
665/*
666 * Open ethernet device. Returns ENXIO for illegal minor device number,

--- 1880 unchanged lines hidden ---