Date: Tue, 11 May 2021 08:27:46 -0600 From: Jim Thompson <jim@netgate.com> To: Francois ten Krooden <ftk@nanoteq.com> Cc: Konstantin Belousov <kostikbel@gmail.com>, "freebsd-net@freebsd.org" <freebsd-net@freebsd.org>, Mark Johnston <markj@freebsd.org> Subject: Re: Vector Packet Processing (VPP) portability on FreeBSD Message-ID: <A00B968B-790E-4D2C-B4EC-6E19014B0078@netgate.com> In-Reply-To: <YJqAznByy772Tc82@nuc> References: <AB9BB4D903F59549B2E27CC033B964D6C4F8BECE@NTQ-EXC.nanoteq.co.za> <YJk%2BxyUQx5/ENPRj@kib.kiev.ua> <AB9BB4D903F59549B2E27CC033B964D6C4F8D11A@NTQ-EXC.nanoteq.co.za> <YJqAznByy772Tc82@nuc>
next in thread | previous in thread | raw e-mail | index | archive | help
> On May 11, 2021, at 7:04 AM, Mark Johnston <markj@freebsd.org> wrote: >=20 > On Tue, May 11, 2021 at 12:43:10PM +0000, Francois ten Krooden wrote: >> On Monday, 10 May 2021 16:10 Konstantin Belousov wrote: >>=20 >>=20 >>> On Mon, May 10, 2021 at 11:08:18AM +0000, Francois ten Krooden = wrote: >>>> 3. What are suitable alternatives for reading information from = procfs and >>> sysfs on FreeBSD? >>> Understand what information is obtained, then what for is it = actually used, >>> then match it against equivalent FreeBSD approach, then gather the >>> required information. >>=20 >> Thank you. This was basically what we suspected. >> One of the ones we are unsure about is what the equivalent of = /proc/self/pagemap on Linux would be. >> The one idea we had is using procstat_getvmmap from libprocstat, but = haven't finished investigating yet. >=20 > I believe DPDK's libeal uses /proc/pagemap to look up the physical > address of large page mappings. Assuming you want to do the same = thing, > there is the MEM_EXTRACT_PADDR /dev/mem ioctl. It was added > specifically for DPDK. See the mem(4) man page for details on its > usage. Upthread mentioned Netgate (we do pfSense) as being possibly involved in = a port of VPP to FreeBSD. We do have some interest, and I had once = handed this to a contractor, but not much progress was made, and we had our hands full with pfSense and = our VPP-based product (tnsr). VPP has been discussed on freebsd-net = before. You and your team have made it much farther. I=E2=80=99d spoken to the VPP =E2=80=98core team=E2=80=99 about the = sustainability of a port of VPP to FreeBSD, and they didn=E2=80=99t say = =E2=80=99No=E2=80=99. The lead VPP person at Cisco used to be a FreeBSD = src committer, and he basically said, =E2=80=9CPatches welcome=E2=80=9D. = Someone will probably want to bring CSIT along to help prevent = regressions on FreeBSD, but that team also seemed open when I checked. IMO, netmap seems a better approach on FreeBSD, as you=E2=80=99ll = eventually want something like the =E2=80=98router plugin=E2=80=99 to be = able to communicate between the kernel and VPP, obtain FIBs, etc. =20 We=E2=80=99ve been strong proponents of (and a main contributor to) the = =E2=80=98linux-cp=E2=80=9D plugin, (a better version of the router = plugin, partially upstreamed to VPP), but it=E2=80=99s based on netlink, = and is has more linux-isms than the main body of VPP. Netmap has a very = nice architecture for building something similar, where packets can be = directly sent to and received from the host rings by VPP, and these host = rings are associated with an interface ring. Netmap-fwd uses this to = good effect. Netmap is slightly slower in maximum PPS than DPDK, but for your use = case (IPsec), you won't see a difference (assuming some things when I = say this.) Jim=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?A00B968B-790E-4D2C-B4EC-6E19014B0078>