Date: Mon, 8 Apr 2013 14:18:36 +0900 From: YongHyeon PYUN <pyunyh@gmail.com> To: "Eggert, Lars" <lars@netapp.com> Cc: "freebsd-net@freebsd.org" <freebsd-net@freebsd.org> Subject: Re: enable tcpdump GUESS_TSO flag? Message-ID: <20130408051836.GA1526@michelle.cdnetworks.com> In-Reply-To: <0A5ED929-C148-45C3-8576-C31D2C05AB04@netapp.com> References: <0A5ED929-C148-45C3-8576-C31D2C05AB04@netapp.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Apr 04, 2013 at 11:24:18AM +0000, Eggert, Lars wrote: > Hi, > > I wonder whether it'd be a good idea to enable tcpdump's GUESS_TSO flag by default? It enables a heuristic that lets tcpdump understand pcaps that include segments generated by TCP TSO (which otherwise show up as "IP bad-len 0".) > I don't have strong option on enabling that flag but I think it would be even better to have an option to enable/disable that feature(default off). em(4) controllers require IP length should be 0 before controller performs TSO operation. fxp(4) controllers requires IP length should be set to the IP length of the first TCP segment after TSO operation. bpf listeners see the modified packet so it can confuse them. AFAIK, except em(4)/fxp(4) controllers, no other controllers in tree have such limitation with TSO. Enabling GUESS_TSO flag may make it hard to debug network/driver issues I guess. > See the dicussion at http://www.mail-archive.com/tcpdump-workers@lists.tcpdump.org/msg01051.html for details. > > Lars > > diff --git a/usr.sbin/tcpdump/tcpdump/Makefile b/usr.sbin/tcpdump/tcpdump/Makefile > index ca8ec4c..5fd73a1 100644 > --- a/usr.sbin/tcpdump/tcpdump/Makefile > +++ b/usr.sbin/tcpdump/tcpdump/Makefile > @@ -45,6 +45,10 @@ CFLAGS+= -I${.CURDIR} -I${TCPDUMP_DISTDIR} > CFLAGS+= -DHAVE_CONFIG_H > CFLAGS+= -D_U_="__attribute__((unused))" > > +# Enable tcpdump heuristic to identify TSO-generated packets; see > +# http://www.mail-archive.com/tcpdump-workers@lists.tcpdump.org/msg01051.html > +CFLAGS+= -DGUESS_TSO > + > .if ${MK_INET6_SUPPORT} != "no" > SRCS+= print-ip6.c print-ip6opts.c print-mobility.c print-ripng.c \ > print-icmp6.c print-babel.c print-frag6.c print-rt6.c print-ospf6.c \ >
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130408051836.GA1526>