From owner-freebsd-net@freebsd.org Thu Jun 16 07:18:14 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 0F222A69D01 for ; Thu, 16 Jun 2016 07:18:14 +0000 (UTC) (envelope-from Michael.Tuexen@lurchi.franken.de) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id EC69417F2 for ; Thu, 16 Jun 2016 07:18:13 +0000 (UTC) (envelope-from Michael.Tuexen@lurchi.franken.de) Received: by mailman.ysv.freebsd.org (Postfix) id EBBE8A69D00; Thu, 16 Jun 2016 07:18:13 +0000 (UTC) Delivered-To: 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 EB61FA69CFF for ; Thu, 16 Jun 2016 07:18:13 +0000 (UTC) (envelope-from Michael.Tuexen@lurchi.franken.de) Received: from drew.franken.de (mail-n.franken.de [193.175.24.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "*.franken.de", Issuer "COMODO RSA Domain Validation Secure Server CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 94AF617F0; Thu, 16 Jun 2016 07:18:13 +0000 (UTC) (envelope-from Michael.Tuexen@lurchi.franken.de) Received: from [IPv6:2a02:c6a0:3061:50e1:6002:30fd:f135:9450] (unknown [IPv6:2a02:c6a0:3061:50e1:6002:30fd:f135:9450]) (Authenticated sender: macmic) by mail-n.franken.de (Postfix) with ESMTPSA id 629C9721E280C; Thu, 16 Jun 2016 09:18:04 +0200 (CEST) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Subject: Re: Netmap Checksum Offloading From: Michael Tuexen In-Reply-To: <576249FA.2050809@in.tum.de> Date: Thu, 16 Jun 2016 09:18:03 +0200 Cc: Jim Thompson , Navdeep Parhar , "net@freebsd.org" , Andrey Yakovlev Content-Transfer-Encoding: quoted-printable Message-Id: References: <57601DFA.2040008@in.tum.de> <470941466032510@web23o.yandex.ru> <576249FA.2050809@in.tum.de> To: Dominik Schoeffmann X-Mailer: Apple Mail (2.3124) X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00 autolearn=disabled version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on mail-n.franken.de X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Jun 2016 07:18:14 -0000 > On 16 Jun 2016, at 08:40, Dominik Schoeffmann = wrote: >=20 > Is the checksum offloading patch for the igb(4) driver available = online? > (I could not find it) > I would really like to take a look at it, espacially the context > descriptor part of it. I would also be interested in it... For looking at SCTP checksum = offloading. Best regards Michael >=20 > Best regards, > Dominik >=20 > On 16.06.2016 02:04, Jim Thompson wrote: >>=20 >> Luiz Otavio O Souza (loos@) developed these for igb(4) and, by = extension, em(4) for use in netmap-fwd. >>=20 >> He=E2=80=99s just gone back to Brazil with 82599 ixgb(4) hardware. = I=E2=80=99m sure he=E2=80=99ll develop similar patches for ixgb(4) in = the near future. >>=20 >> Chelsio is also =E2=80=9Con the list=E2=80=9D, but I figured I=E2=80=99= d speak to np@ about it first. ;-) =20 >> We might do ixl(4) as well. =20 >>=20 >> Before Luiz retired to Brazil, we discussed upstreaming these to = FreeBSD. We=E2=80=99re committed to make it happen, but I doubt they = make 11. >>=20 >> Jim >>=20 >>> On Jun 15, 2016, at 6:50 PM, Navdeep Parhar wrote: >>>=20 >>> On 06/15/2016 16:15, Andrey Yakovlev wrote: >>>> ive heard on bsdcan this year that some patches exist to add hwcsum = offloading to netmap, hope to see it chelsio at least >>>=20 >>> cxgbe/cxl is a bit sneaky and will let you override netmap (on tx = only). >>> The ncxl interfaces declare themselves capable of checksumming but = all >>> such capabilities are disabled by default. Just enable txcsum on = the >>> interface and the hardware will do checksum insertion on tx. No way = to >>> solve the rx part entirely within the driver -- netmap has to be = willing >>> to accept checksum related flags from the driver. >>>=20 >>> Regards, >>> Navdeep >>>=20 >>>>=20 >>>> --=20 >>>> ./andy >>>>=20 >>>>=20 >>>> 14.06.2016, 12:15, "Dominik Schoeffmann" : >>>>> Dear Netmap Developers, >>>>>=20 >>>>> during the course of my bachelor's thesis, I modified a packet = generator >>>>> called MoonGen [1] in order to utilize netmap. >>>>> One key component was to flexibly offload checksums for different = kinds >>>>> of packets (IPv4, UDP, TCP). >>>>> The ixgbe netmap patch was modified [2] in order to construct = context >>>>> descriptors and suitable data descriptors. This is implemented in = less >>>>> than 250 LoC (including pseudo-header calculations). >>>>> The man page states, that checksum offloading is available via = ethtool, >>>>> although a solution inside the netmap API might be a cleaner way = for >>>>> applications to actually use these features. >>>>> Attached is a graph showing the performance implication of using >>>>> offloading in the current implementation. >>>>> As can be seen, offloading has only a minor impact. >>>>> When regarding this data (and comparing it to other frameworks), = please >>>>> keep in mind, that internally a lot of per-packet effort is needed = due >>>>> to the software architecture of the packet generator. >>>>>=20 >>>>> The question being: >>>>> Would it not make sense to include checksum offloading inside of = netmap >>>>> in order to accomodate applications operating on layer 3 and = above? >>>>> As these programs need to calculate the checksums in software, it = would >>>>> be just as fast to move these calculations to the kernel for NICs >>>>> without checksum offloading support (and the kernel would act as a = library). >>>>> The problem which currently is imposed by the fact, that netmap = exports >>>>> the complete ring, is that context descriptors disrupt the data >>>>> descriptors, which is unpleasant for the application. >>>>> But you may find the data interesting nevertheless. >>>>>=20 >>>>> Best Regards, >>>>> Dominik Schoeffmann >>>>>=20 >>>>> [1] https://github.com/dschoeffm/MoonGen/tree/netmap >>>>> [2] https://github.com/dschoeffm/netmap/tree/mg-chksum-offloading >>>> _______________________________________________ >>>> 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" >>>>=20 >>>=20 >>> _______________________________________________ >>> 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" >>=20 >=20