freebsd-dev/sys
Sean Bruno 23c9098b2a Change EM_MULTIQUEUE to a real kernconf entry and enable support for
up to 2 rx/tx queues for the 82574.

Program the 82574 to enable 5 msix vectors, assign 1 to each rx queue,
1 to each tx queue and 1 to the link handler.

Inspired by DragonFlyBSD, enable some RSS logic for handling tx queue
handling/processing.

Move multiqueue handler functions so that they line up better in a diff
review to if_igb.c

Always enqueue tx work to be done in em_mq_start, if unable to acquire
the TX lock, then this will be processed in the background later by the
taskqueue.  Remove mbuf argument from em_start_mq_locked() as the work
is always enqueued.  (stolen from igb)

Setup TARC, TXDCTL and RXDCTL registers for better performance and stability
in multiqueue and singlequeue implementations. Handle Intel errata  3 and
generic multiqueue behavior with the initialization of TARC(0) and TARC(1)

Bind interrupt threads to cpus in order.  (stolen from igb)

Add 2 new DDB functions, one to display the queue(s) and their settings and
one to reset the adapter.  Primarily used for debugging.

In the multiqueue configuration, bump RXD and TXD ring size to max for the
adapter (4096).  Setup an RDTR of 64 and an RADV of 128 in multiqueue configuration
to cut down on the number of interrupts.  RADV was arbitrarily set to 2x RDTR
and can be adjusted as needed.

Cleanup the display in top a bit to make it clearer where the taskqueue threads
are running and what they should be doing.

Ensure that both queues are processed by em_local_timer() by writing them both
to the IMS register to generate soft interrupts.

Ensure that an soft interrupt is generated when em_msix_link() is run so that
any races between assertion of the link/status interrupt and a rx/tx interrupt
are handled.

Document existing tuneables: hw.em.eee_setting, hw.em.msix, hw.em.smart_pwr_down, hw.em.sbp

Document use of hw.em.num_queues and the new kernel option EM_MULTIQUEUE

Thanks to Intel for their continued support of FreeBSD.

Reviewed by:	erj jfv hiren gnn wblock
Obtained from:	Intel Corporation
MFC after:	2 weeks
Relnotes:	Yes
Sponsored by:	Limelight Networks
Differential Revision:	https://reviews.freebsd.org/D1994
2015-06-03 18:01:09 +00:00
..
amd64 Remove unneeded NULL checks in amd64's trap_fatal(). 2015-06-01 06:50:39 +00:00
arm Better handling of userland sysarch() requests to flush icache. 2015-06-03 14:07:50 +00:00
arm64 ddb: finish converting boolean values. 2015-05-21 15:16:18 +00:00
boot userboot: enable bzipfs support 2015-06-03 10:10:00 +00:00
bsm
cam Handle EDQUOT backend storage errors same as ENOSPC. 2015-05-06 19:47:31 +00:00
cddl Add missed {}. 2015-05-27 19:28:14 +00:00
compat Provide vnode in memory map info for files on tmpfs 2015-06-02 18:37:04 +00:00
conf Change EM_MULTIQUEUE to a real kernconf entry and enable support for 2015-06-03 18:01:09 +00:00
contrib Add support for the tuning cap for Hornet/AR9331 boards. 2015-05-23 08:02:54 +00:00
crypto In the version of gcc in the FreeBSD tree, this modification was made to 2015-04-16 17:42:52 +00:00
ddb ddb: de-register 2015-05-23 14:59:27 +00:00
dev Change EM_MULTIQUEUE to a real kernconf entry and enable support for 2015-06-03 18:01:09 +00:00
fs Provide vnode in memory map info for files on tmpfs 2015-06-02 18:37:04 +00:00
gdb CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than ten 2015-05-22 17:05:21 +00:00
geom CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than ten 2015-05-22 17:05:21 +00:00
gnu The GNU Amlogic DTS files have some errors (e.g. bad register 2015-04-11 08:17:39 +00:00
i386 When I merged the lemul branch I missied kib@'s r282708 commit. 2015-05-25 20:44:46 +00:00
isa
kern Provide vnode in memory map info for files on tmpfs 2015-06-02 18:37:04 +00:00
kgssapi
libkern Add more __aeabi_memcpy functions, later versions of clang generate calls 2015-05-31 07:31:20 +00:00
mips Similarly to other architecture, add the include for cpufunc.h which is 2015-05-28 12:33:21 +00:00
modules Change EM_MULTIQUEUE to a real kernconf entry and enable support for 2015-06-03 18:01:09 +00:00
net CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than ten 2015-05-22 17:05:21 +00:00
net80211 Move counter.h include into ieee80211_freebsd.h. Should fix build. 2015-05-27 14:05:46 +00:00
netgraph CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than ten 2015-05-22 17:05:21 +00:00
netinet Remove printf() noise... 2015-05-29 08:31:15 +00:00
netinet6 Move RTM announces into generic code to be independent from Layer2 code. 2015-05-29 10:24:16 +00:00
netipsec CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than ten 2015-05-22 17:05:21 +00:00
netnatm
netpfil CALLOUT_MPSAFE has lost its meaning since r141428, i.e., for more than ten 2015-05-22 17:05:21 +00:00
netsmb
nfs
nfsclient Remove some oldnfs remnants. 2015-04-18 16:08:06 +00:00
nfsserver
nlm
ofed Add SIOCGI2C ioctl support to the driver. Would work only on ConnectX-3 2015-05-27 13:42:28 +00:00
opencrypto Use the correct number of arguments for the 2015-05-25 01:31:39 +00:00
pc98 Build GENERIC with RACCT/RCTL support by default. Note that it still 2015-05-14 14:03:55 +00:00
powerpc The kernel sends signals to the processes via ABI specific sv_sendsig method. 2015-05-24 17:56:02 +00:00
rpc Remove hard limits on number of accepting NFS connections. 2015-04-07 10:25:27 +00:00
security
sparc64 The kernel sends signals to the processes via ABI specific sv_sendsig method. 2015-05-24 17:56:02 +00:00
sys Revert r102953 2015-05-28 22:06:05 +00:00
teken
tools
ufs Remove unused variable. 2015-05-31 15:50:54 +00:00
vm Provide vnode in memory map info for files on tmpfs 2015-06-02 18:37:04 +00:00
x86 Remove several write-only variables, all reported by the gcc 4.9 2015-05-29 13:24:17 +00:00
xdr
xen xen: introduce a newbus function to allocate unused memory 2015-05-08 14:48:40 +00:00
Makefile Kill EoL whitespace. 2015-05-29 14:03:07 +00:00