freebsd with flexible iflib nic queues
Go to file
Navdeep Parhar 298d969c53 cxgbe(4): netmap support for Terminator 5 (T5) based 10G/40G cards.
Netmap gets its own hardware-assisted virtual interface and won't take
over or disrupt the "normal" interface in any way.  You can use both
simultaneously.

For kernels with DEV_NETMAP, cxgbe(4) carves out an ncxl<N> interface
(note the 'n' prefix) in the hardware to accompany each cxl<N>
interface.  These two ifnet's per port share the same wire but really
are separate interfaces in the hardware and software.  Each gets its own
L2 MAC addresses (unicast and multicast), MTU, checksum caps, etc.  You
should run netmap on the 'n' interfaces only, that's what they are for.

With this, pkt-gen is able to transmit > 45Mpps out of a single 40G port
of a T580 card.  2 port tx is at ~56Mpps total (28M + 28M) as of now.
Single port receive is at 33Mpps but this is very much a work in
progress.  I expect it to be closer to 40Mpps once done.  In any case
the current effort can already saturate multiple 10G ports of a T5 card
at the smallest legal packet size.  T4 gear is totally untested.

trantor:~# ./pkt-gen -i ncxl0 -f tx -D 00:07:43🆎cd:ef
881.952141 main [1621] interface is ncxl0
881.952250 extract_ip_range [275] range is 10.0.0.1:0 to 10.0.0.1:0
881.952253 extract_ip_range [275] range is 10.1.0.1:0 to 10.1.0.1:0
881.962540 main [1804] mapped 334980KB at 0x801dff000
Sending on netmap:ncxl0: 4 queues, 1 threads and 1 cpus.
10.0.0.1 -> 10.1.0.1 (00:00:00:00:00:00 -> 00:07:43🆎cd:ef)
881.962562 main [1882] Sending 512 packets every  0.000000000 s
881.962563 main [1884] Wait 2 secs for phy reset
884.088516 main [1886] Ready...
884.088535 nm_open [457] overriding ifname ncxl0 ringid 0x0 flags 0x1
884.088607 sender_body [996] start
884.093246 sender_body [1064] drop copy
885.090435 main_thread [1418] 45206353 pps (45289533 pkts in 1001840 usec)
886.091600 main_thread [1418] 45322792 pps (45375593 pkts in 1001165 usec)
887.092435 main_thread [1418] 45313992 pps (45351784 pkts in 1000834 usec)
888.094434 main_thread [1418] 45315765 pps (45406397 pkts in 1002000 usec)
889.095434 main_thread [1418] 45333218 pps (45378551 pkts in 1001000 usec)
890.097434 main_thread [1418] 45315247 pps (45405877 pkts in 1002000 usec)
891.099434 main_thread [1418] 45326515 pps (45417168 pkts in 1002000 usec)
892.101434 main_thread [1418] 45333039 pps (45423705 pkts in 1002000 usec)
893.103434 main_thread [1418] 45324105 pps (45414708 pkts in 1001999 usec)
894.105434 main_thread [1418] 45318042 pps (45408723 pkts in 1002001 usec)
895.106434 main_thread [1418] 45332430 pps (45377762 pkts in 1001000 usec)
896.107434 main_thread [1418] 45338072 pps (45383410 pkts in 1001000 usec)
...

Relnotes:	Yes
Sponsored by:	Chelsio Communications.
2014-05-27 18:18:41 +00:00
bin sh: In getopts, unset OPTARG where POSIX says we should. 2014-05-10 19:18:49 +00:00
cddl Explicitly link libzfs against libavl as it is done in OpenSolaris 2014-05-22 00:01:31 +00:00
contrib Merge apr-1.4.8 -> apr-1.5.1 and update. 2014-05-27 07:15:14 +00:00
crypto Change comment about HPNDisabled to match the style of other options to 2014-05-20 10:28:19 +00:00
etc Change libatf-c and libatf-c++ to be private libraries. 2014-05-25 12:01:13 +00:00
games Use src.opts.mk in preference to bsd.own.mk except where we need stuff 2014-05-06 04:22:01 +00:00
gnu Move Nx definition to a separate block. 2014-05-20 21:24:15 +00:00
include Vendor import apr-1.5.1 2014-05-27 07:00:33 +00:00
kerberos5 Use src.opts.mk in preference to bsd.own.mk except where we need stuff 2014-05-06 04:22:01 +00:00
lib Emphasis on 'do not' and 'complement' in the strcspn(3) 2014-05-27 04:30:56 +00:00
libexec Change libatf-c and libatf-c++ to be private libraries. 2014-05-25 12:01:13 +00:00
release Note proper revision number for sendmail 8.14.9 merge. 2014-05-26 15:54:31 +00:00
rescue Minor style nits... 2014-05-23 00:20:57 +00:00
sbin If called without -T or -t, fsck attempts to detect the 2014-05-23 14:32:57 +00:00
secure Switch using the new $2b$ format by default, when bcrypt is used. 2014-05-14 00:50:31 +00:00
share Better documentation for why KERBEROS and OPENSSH are here, and where 2014-05-27 16:30:54 +00:00
sys cxgbe(4): netmap support for Terminator 5 (T5) based 10G/40G cards. 2014-05-27 18:18:41 +00:00
tests Remove last two NO_MAN= in the tree. In both of these cases, MAN= is 2014-05-10 16:38:37 +00:00
tools Remove empty lines that cause mdoc warnings. 2014-05-27 15:52:27 +00:00
usr.bin Update backend files and makefiles for apr 1.4.8 -> 1.5.1 2014-05-27 07:16:43 +00:00
usr.sbin Add segment protection and limits violation checks in vie_calculate_gla() 2014-05-27 04:26:22 +00:00
.arcconfig Add the missing coma 2014-05-15 11:30:17 +00:00
COPYRIGHT Bump copyright year. 2013-12-31 12:18:10 +00:00
LOCKS Explicitly require Security Officer's approval for kernel PRNG bits. 2013-09-17 14:19:05 +00:00
MAINTAINERS This should have been obvious, but make it so. 2014-04-06 16:48:00 +00:00
Makefile grep -L returns non-zero status if none of the files had the pattern 2014-05-10 16:39:08 +00:00
Makefile.inc1 When libelf and libdwarf were updated, we didn't bump the minimal 2014-05-23 00:20:48 +00:00
ObsoleteFiles.inc Don't delete our new vt(4) man page. 2014-05-22 16:30:32 +00:00
README
UPDATING Upgrade our copy of llvm/clang to 3.4.1 release. This release contains 2014-05-12 18:45:56 +00:00

This is the top level of the FreeBSD source directory.  This file
was last revised on:
$FreeBSD$

For copyright information, please see the file COPYRIGHT in this
directory (additional copyright information also exists for some
sources in this tree - please see the specific source directories for
more information).

The Makefile in this directory supports a number of targets for
building components (or all) of the FreeBSD source tree, the most
commonly used one being ``world'', which rebuilds and installs
everything in the FreeBSD system from the source tree except the
kernel, the kernel-modules and the contents of /etc.  The ``world''
target should only be used in cases where the source tree has not
changed from the currently running version.  See:
http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/makeworld.html
for more information, including setting make(1) variables.

The ``buildkernel'' and ``installkernel'' targets build and install
the kernel and the modules (see below).  Please see the top of
the Makefile in this directory for more information on the
standard build targets and compile-time flags.

Building a kernel is a somewhat more involved process, documentation
for which can be found at:
   http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig.html
And in the config(8) man page.
Note: If you want to build and install the kernel with the
``buildkernel'' and ``installkernel'' targets, you might need to build
world before.  More information is available in the handbook.

The sample kernel configuration files reside in the sys/<arch>/conf
sub-directory (assuming that you've installed the kernel sources), the
file named GENERIC being the one used to build your initial installation
kernel.  The file NOTES contains entries and documentation for all possible
devices, not just those commonly used.  It is the successor of the ancient
LINT file, but in contrast to LINT, it is not buildable as a kernel but a
pure reference and documentation file.


Source Roadmap:
---------------
bin		System/user commands.

cddl		Various commands and libraries under the Common Development
		and Distribution License.

contrib		Packages contributed by 3rd parties.

crypto		Cryptography stuff (see crypto/README).

etc		Template files for /etc.

games		Amusements.

gnu		Various commands and libraries under the GNU Public License.
		Please see gnu/COPYING* for more information.

include		System include files.

kerberos5	Kerberos5 (Heimdal) package.

lib		System libraries.

libexec		System daemons.

release		Release building Makefile & associated tools.

rescue		Build system for statically linked /rescue utilities.

sbin		System commands.

secure		Cryptographic libraries and commands.

share		Shared resources.

sys		Kernel sources.

tools		Utilities for regression testing and miscellaneous tasks.

usr.bin		User commands.

usr.sbin	System administration commands.


For information on synchronizing your source tree with one or more of
the FreeBSD Project's development branches, please see:

  http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/synching.html