From owner-freebsd-net@freebsd.org Tue Jan 19 23:47:58 2016 Return-Path: Delivered-To: freebsd-net@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 33659A8906A for ; Tue, 19 Jan 2016 23:47:58 +0000 (UTC) (envelope-from rizzo.unipi@gmail.com) Received: from mail-lb0-x231.google.com (mail-lb0-x231.google.com [IPv6:2a00:1450:4010:c04::231]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id B260B1D60; Tue, 19 Jan 2016 23:47:57 +0000 (UTC) (envelope-from rizzo.unipi@gmail.com) Received: by mail-lb0-x231.google.com with SMTP id oh2so373399088lbb.3; Tue, 19 Jan 2016 15:47:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=BLpI8YUgoiUTbXQ2wac+1gMxQhkGfacfysvAvmugUFQ=; b=jYvEYGSgKv0AksbIykuxl465ZDKOpnLcx2/ENqMstbBWfepLXUYFU9pqhYjF3nvUhC IhCt9VgdM6KP70yaJpebIKRCaayGBjYvhyJBrQWcTH5V+3hiHFHLJv8TALZUrwvD+6Se UNII2uH1+ldeellK8fNKdFHS3S3IVw906u9IupUFI8uIUdrwyfAcPDGi/5lU61DME5kz FKd+A8tEixIBq0GI+996ea9Z+D16JfhzMys2xErxCAOVpZxUZUUuLHFxHRg/lO3pSDUt /acprn9VQj7uJ4wv2s+3nXjF29/Y88tEkYMuxzr1yNdgHZPvKANcuA+NkOnGB9vzTpBG 0sfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:sender:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=BLpI8YUgoiUTbXQ2wac+1gMxQhkGfacfysvAvmugUFQ=; b=Ly2T2/hjwMPHjr/na5yE7YdlV2rxKXiQKWUnfgRuYjccUzQQieptAHyr5AdENL17M1 TZb1i/wVbjKBSMY+0A1Vpj6imLuELRp0Fvl+vEu1VNmfVV2uZLXl+2+CNWw/jGqTK37U q8KCWmnKNA6kjz06bjEfmsH1m5p/3b3DlFzcZmu5BJAkCH4oGux9goCS6S3GHvdMzb0l 7g5Wu1h+K3jZ/2N9U+z8lX5NasW/36HU6Euv7o0822v8lm86Nt1d1V/SkMRot944KZe2 q8LVfdEeiCiTZT63yBT8GtS+NWOaGTcRniGOyToIHszjhj8qdl7PtVbD4KegpXYHDHgm mWBw== X-Gm-Message-State: AG10YORf/vCMOXpVdZznVz+udd0n11U53HtwiGYMadjsnM7021cl25mntboQobsKxv7DLBKSTvE8x4il8FZVEA== MIME-Version: 1.0 X-Received: by 10.112.155.201 with SMTP id vy9mr4163649lbb.54.1453247275610; Tue, 19 Jan 2016 15:47:55 -0800 (PST) Sender: rizzo.unipi@gmail.com Received: by 10.114.4.232 with HTTP; Tue, 19 Jan 2016 15:47:55 -0800 (PST) In-Reply-To: <22174.51361.2022.984959@hergotha.csail.mit.edu> References: <22174.51361.2022.984959@hergotha.csail.mit.edu> Date: Wed, 20 Jan 2016 00:47:55 +0100 X-Google-Sender-Auth: YLgjw5_af5vkVDWytqPLr9L_Lls Message-ID: Subject: Re: Another issue with ixl(4) with netmap From: Luigi Rizzo To: Garrett Wollman , Giuseppe Lettieri Cc: "freebsd-net@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Jan 2016 23:47:58 -0000 Interesting report, thanks. My colleague Giuseppe can have a look at this. While not sure about the actual issue I can tell you that generally we try to include checksums in drivers that support netmap, because PCIe bus transactions are faster for transfers that are multiple of 64 bytes and aligned to those boundaries. Keeping the CRC (and doing the stripping in software) makes the requirement for min-sized packets, which are a common test case. The symptoms you see suggest a mismatch on who is doing the CRC stripping, which seems to occur twice; what is strange is that in case i would expect the opposite error, i.e. disable stripping in the hardware and forget to enable it in the software. cheers luigi On Wed, Jan 20, 2016 at 12:37 AM, Garrett Wollman wrote: > I noticed that a large number -- but by no means all -- of the packets > captured using libpcap on a netmap'ified ixl(4) interface show up as > truncated -- usually by exactly four bytes. They show up in tcpdump > like this: > > 18:10:05.348735 IP truncated-ip - 4 bytes missing! 128.30.xxx.xxx.443 > yyy.yyy.yyy.yyy.54711: Flags [P.], seq 3151716053:3151716112, ack 3109956633, win 31, length 59 > 18:10:05.348735 IP truncated-ip - 4 bytes missing! zzz.zzz.zzz.zzz.17376 > 128.30.aaa.aaa.80: Flags [.], ack 1771224170, win 12775, options [nop,nop,sack 1 [|tcp]> > 18:10:05.348735 IP truncated-ip - 4 bytes missing! zzz.zzz.zzz.zzz.17376 > 128.30.aaa.aaa.80: Flags [.], ack 1, win 12775, options [nop,nop,sack 1 [|tcp]> > > This does not occur when the same interface is used with BPF (but > libpcap can't keep up with the traffic when using BPF). Has anyone > see this before, and if so, what was the solution? (This is on 10.2 > with the ixl(4) updates merged from 10-stable.) > > -GAWollman > _______________________________________________ > freebsd-net@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-net > To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org" -- -----------------------------------------+------------------------------- Prof. Luigi RIZZO, rizzo@iet.unipi.it . Dip. di Ing. dell'Informazione http://www.iet.unipi.it/~luigi/ . Universita` di Pisa TEL +39-050-2217533 . via Diotisalvi 2 Mobile +39-338-6809875 . 56122 PISA (Italy) -----------------------------------------+-------------------------------