diff options
author | 2016-03-29 10:40:13 +0000 | |
---|---|---|
committer | 2016-03-29 10:40:13 +0000 | |
commit | ea5f0a098e0a6555a1cba8e693dbb6bb55ec41d7 (patch) | |
tree | 3c3c0bce7ead8a8a737a6caec7716f3bacdae176 | |
parent | make bpf_mtap et al return whether the mbuf should be dropped (diff) | |
download | wireguard-openbsd-ea5f0a098e0a6555a1cba8e693dbb6bb55ec41d7.tar.xz wireguard-openbsd-ea5f0a098e0a6555a1cba8e693dbb6bb55ec41d7.zip |
all the bpf_mtap functions now return whether to drop the packet or not
-rw-r--r-- | share/man/man9/bpf_mtap.9 | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/share/man/man9/bpf_mtap.9 b/share/man/man9/bpf_mtap.9 index 8be2fa9203f..6889cc12ed1 100644 --- a/share/man/man9/bpf_mtap.9 +++ b/share/man/man9/bpf_mtap.9 @@ -1,4 +1,4 @@ -.\" $OpenBSD: bpf_mtap.9,v 1.3 2016/03/29 07:33:21 jmc Exp $ +.\" $OpenBSD: bpf_mtap.9,v 1.4 2016/03/29 10:40:13 dlg Exp $ .\" .\" Copyright (c) 2016 David Gwynne <dlg@openbsd.org> .\" @@ -28,9 +28,9 @@ .In net/bpf.h .Ft int .Fn bpf_tap "caddr_t bpf" "u_char *pkt" "u_int pktlen" "u_int direction" -.Ft void +.Ft int .Fn bpf_mtap "caddr_t bpf" "struct mbuf *m" "u_int direction" -.Ft void +.Ft int .Fo bpf_mtap_hdr .Fa "caddr_t bpf" .Fa "caddr_t hdr" @@ -39,9 +39,9 @@ .Fa "u_int direction" .Fa "void (*cpfn)(const void *, void *, size_t)" .Fc -.Ft void +.Ft int .Fn bpf_mtap_af "caddr_t bpf" "u_int32_t af" "struct mbuf *m" "u_int direction" -.Ft void +.Ft int .Fn bpf_mtap_ether "caddr_t bpf" "struct mbuf *m" "u_int direction" .Sh DESCRIPTION The BPF kernel API provides incoming linkage from device drivers. @@ -118,8 +118,13 @@ and can be called from process context, or from an interrupt context at or below .Dv IPL_NET . .Sh RETURN VALUES -.Fn bpf_tap -returns 1 if the packet matched a filter that indicates the packet +.Fn bpf_tap , +.Fn bpf_mtap , +.Fn bpf_mtap_hdr , +.Fn bpf_mtap_af , +and +.Fn bpf_mtap_ether +return 1 if the packet matched a filter that indicates the packet should be dropped, otherwise 0. .Sh SEE ALSO .Xr mbuf 9 , |