NetBSD/sys/net
christos 224c697f91 Patch from Dheeraj S, inspired by the following FreeBSD change:
Rather than calling mircotime() in catchpacket(), make catchpacket()
take a timeval indicating when the packet was captured. Move
microtime() to the calling functions and grab the timestamp as soon
as we know that we're going to call catchpacket at least once.

This means that we call microtime() once per matched packet, as
opposed to once per matched packet per bpf listener. It also means
that we return the same timestamp to all bpf listeners, rather than
slightly different ones.

It would be more accurate to call microtime() even earlier for all
packets, as you have to grab (1+#listener) locks before you can
determine if the packet will be logged. You could always grab a
timestamp before the locks, but microtime() can be costly, so this
didn't seem like a good idea.

(I guess most ethernet interfaces will have a bpf listener these
days because of dhclient. That means that we could be doing two bpf
locks on most packets going through the interface.)
2006-07-26 13:54:13 +00:00
..
agr make a multiple inclusion protection macro match with the filename. 2006-07-08 05:57:41 +00:00
bpf_filter.c
bpf.c Patch from Dheeraj S, inspired by the following FreeBSD change: 2006-07-26 13:54:13 +00:00
bpf.h
bpfdesc.h
bridgestp.c
bsd-comp.c
dlt.h
ethertypes.h
files.pf
if_arc.h
if_arcsubr.c merge FreeBSD timecounters from branch simonb-timecounters 2006-06-07 22:33:33 +00:00
if_arp.h
if_atm.h
if_atmsubr.c
if_bridge.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_bridgevar.h
if_dl.h
if_eco.h
if_ecosubr.c merge FreeBSD timecounters from branch simonb-timecounters 2006-06-07 22:33:33 +00:00
if_ether.h
if_ethersubr.c merge FreeBSD timecounters from branch simonb-timecounters 2006-06-07 22:33:33 +00:00
if_faith.c
if_faith.h
if_fddi.h
if_fddisubr.c merge FreeBSD timecounters from branch simonb-timecounters 2006-06-07 22:33:33 +00:00
if_gif.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_gif.h
if_gre.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_gre.h
if_hippi.h
if_hippisubr.c merge FreeBSD timecounters from branch simonb-timecounters 2006-06-07 22:33:33 +00:00
if_ieee1394.h
if_ieee1394subr.c merge FreeBSD timecounters from branch simonb-timecounters 2006-06-07 22:33:33 +00:00
if_llc.h
if_loop.c
if_media.c
if_media.h Add IFM_10G_SR and IFM_10G_CX4, to keep in sync with FreeBSD. 2006-06-03 12:43:28 +00:00
if_ppp.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_ppp.h
if_pppoe.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_pppoe.h
if_pppvar.h Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_sl.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_slvar.h merge FreeBSD timecounters from branch simonb-timecounters 2006-06-07 22:33:33 +00:00
if_sppp.h
if_spppsubr.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_spppvar.h
if_stf.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_stf.h
if_strip.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_stripvar.h merge FreeBSD timecounters from branch simonb-timecounters 2006-06-07 22:33:33 +00:00
if_tap.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_tap.h
if_token.h
if_tokensubr.c merge FreeBSD timecounters from branch simonb-timecounters 2006-06-07 22:33:33 +00:00
if_tun.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_tun.h
if_types.h
if_vlan.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if_vlanvar.h
if.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
if.h add a comment on if_agrprivate. 2006-06-25 07:50:00 +00:00
Makefile Do not instal net/if_pppvar.h, net/if_slvar.h and net/if_stripvar.h. 2006-06-18 21:02:16 +00:00
net_osdep.h Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
netisr_dispatch.h
netisr.h
pfil.c
pfil.h
pfkeyv2.h
ppp_defs.h
ppp_tty.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
ppp-comp.h
ppp-deflate.c
radix.c
radix.h
raw_cb.c
raw_cb.h
raw_usrreq.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
route.c merge FreeBSD timecounters from branch simonb-timecounters 2006-06-07 22:33:33 +00:00
route.h
rtsock.c Use the LWP cached credentials where sane. 2006-07-23 22:06:03 +00:00
slcompress.c
slcompress.h
slip.h
zlib.c
zlib.h