diff options
author | Damien Miller <djm@cvs.openbsd.org> | 2006-03-25 22:41:49 +0000 |
---|---|---|
committer | Damien Miller <djm@cvs.openbsd.org> | 2006-03-25 22:41:49 +0000 |
commit | 24436414aab60dc84348ec54f23b324b4ae862a3 (patch) | |
tree | ee35283622a78eeac5656cb5661954771faf6520 /sys/dev/ic/dc.c | |
parent | d1265a1a72755bd0209950654a6df47287781241 (diff) |
allow bpf(4) to ignore packets based on their direction (inbound or
outbound), using a new BIOCSDIRFILT ioctl;
guidance, feedback and ok canacar@
Diffstat (limited to 'sys/dev/ic/dc.c')
-rw-r--r-- | sys/dev/ic/dc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/ic/dc.c b/sys/dev/ic/dc.c index 928d9c16b22..df227d51e98 100644 --- a/sys/dev/ic/dc.c +++ b/sys/dev/ic/dc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dc.c,v 1.91 2006/01/28 10:08:38 brad Exp $ */ +/* $OpenBSD: dc.c,v 1.92 2006/03/25 22:41:42 djm Exp $ */ /* * Copyright (c) 1997, 1998, 1999 @@ -2269,7 +2269,7 @@ dc_rxeof(sc) ifp->if_ipackets++; #if NBPFILTER > 0 if (ifp->if_bpf) - bpf_mtap(ifp->if_bpf, m); + bpf_mtap(ifp->if_bpf, m, BPF_DIRECTION_IN); #endif ether_input_mbuf(ifp, m); } @@ -2780,7 +2780,7 @@ dc_start(ifp) */ #if NBPFILTER > 0 if (ifp->if_bpf) - bpf_mtap(ifp->if_bpf, m_head); + bpf_mtap(ifp->if_bpf, m_head, BPF_DIRECTION_OUT); #endif if (sc->dc_flags & DC_TX_ONE) { ifp->if_flags |= IFF_OACTIVE; |