freebsd-nq/sys
Robert Watson 3cb73e3d8b Teach the loopback interface about checksum generation and validation
avoidance:

- Enable setting the RXCSUM and TXCSUM flags for loopback interfaces;
  set both by default.
- When RXCSUM is set, flag packets sent over the loopback interface as
  having checked and valid IP, UDP, TCP checksums so that higher
  protocol layers won't check them.
- Always clear CSUM_{IP,UDP_TCP} checksum required flags on transmit,
  as they will have gotten there as a result of TXCSUM being set.

This is done only for packets explicitly sent over the loopback, not
simulated loopback via if_simloop() due to !SIMPLEX interfaces, etc.

Note that enabling TXCSUM but not RXCSUM will lead to unhappiness, as
checksums won't be generated but will be validated.

Kris reports that this leads to significant performance improvements
in loopback benchmarking with TCP and UDP for throughput:

	RXCSUM 	RXCSUM+TXCSUM
TCP	15%	37%
UDP	10%	74%

Update man page.

Reviewed by:	sam
Tested by:	kris
MFC after:	1 week
2009-03-15 20:17:44 +00:00
..
amd64 Update the pmap's resident page count when a page table page is freed in 2009-03-14 08:28:02 +00:00
arm Implement new way of branding ELF binaries by looking to a 2009-03-13 16:40:51 +00:00
boot The recent change to use memory > 1MB for the heap by default broke CD 2009-03-12 20:41:52 +00:00
bsm Merge OpenBSM 1.1 beta 1 from OpenBSM vendor branch to head, both 2009-03-02 13:29:18 +00:00
cam
cddl Add a new internal mount flag (MNTK_EXTENDED_SHARED) to indicate that a 2009-03-11 14:13:47 +00:00
compat Ignore FUTEX_FD op, as it is done by linux. 2009-03-15 19:38:34 +00:00
conf Remove IFF_NEEDSGIANT, a compatibility infrastructure introduced 2009-03-15 14:21:05 +00:00
contrib For all files including net/vnet.h directly include opt_route.h and 2009-02-27 14:12:05 +00:00
crypto
ddb Prefer prototypes to k&r definitions. 2009-03-09 13:32:19 +00:00
dev Don't adjust ranges at all for subtractive bridges. The simple-minded 2009-03-15 06:40:57 +00:00
fs Remove the null_islocked() overloaded vop because the standard one does 2009-03-13 07:09:20 +00:00
gdb
geom Backout this commit whil a better solution is developed 2009-03-13 08:13:51 +00:00
gnu Don't declare bin_search() as an inline function, since there's no 2009-03-08 06:14:33 +00:00
i386 Remove IFF_NEEDSGIANT, a compatibility infrastructure introduced 2009-03-15 14:21:05 +00:00
ia64 Implement new way of branding ELF binaries by looking to a 2009-03-13 16:40:51 +00:00
isa Allow syscons to work on amd64 and i386 without any hints: 2009-03-05 19:10:17 +00:00
kern Remove IFF_NEEDSGIANT, a compatibility infrastructure introduced 2009-03-15 14:21:05 +00:00
kgssapi
legacy/dev remove now-redunant cardbus attachment lines. 2009-03-09 13:25:34 +00:00
libkern Add memmove() to the kernel, making the kernel compile with Clang. 2009-02-28 16:21:25 +00:00
mips Implement new way of branding ELF binaries by looking to a 2009-03-13 16:40:51 +00:00
modules Remove IFF_NEEDSGIANT, a compatibility infrastructure introduced 2009-03-15 14:21:05 +00:00
net Teach the loopback interface about checksum generation and validation 2009-03-15 20:17:44 +00:00
net80211 add the desired channel to the scan list if not already present and 2009-03-04 22:05:25 +00:00
netatalk
netgraph Make Netgraph compile with Clang. 2009-03-03 18:47:33 +00:00
netinet Remove IFF_NEEDSGIANT, a compatibility infrastructure introduced 2009-03-15 14:21:05 +00:00
netinet6 Remove IFF_NEEDSGIANT, a compatibility infrastructure introduced 2009-03-15 14:21:05 +00:00
netipsec SAs are valid (but dying) when they reached soft lifetime, 2009-03-05 16:22:32 +00:00
netipx
netnatm Remove IFF_NEEDSGIANT, a compatibility infrastructure introduced 2009-03-15 14:21:05 +00:00
netncp
netsmb
nfs
nfs4client
nfsclient - Remove code to set SAVENAME for CREATE or RENAME requests that get a -ve 2009-03-10 18:41:06 +00:00
nfsserver Include audit.h so that the system call path protected by NFS_LEGACYRPC 2009-02-23 23:04:15 +00:00
nlm
opencrypto
pc98 Remove IFF_NEEDSGIANT, a compatibility infrastructure introduced 2009-03-15 14:21:05 +00:00
pci The callback takes a void *, not a caddr_t * (sic). 2009-03-03 18:54:57 +00:00
powerpc Implement new way of branding ELF binaries by looking to a 2009-03-13 16:40:51 +00:00
rpc
security - Correct logic in if statement - we want to allocate temporary buffer 2009-03-14 20:40:06 +00:00
sparc64 Implement new way of branding ELF binaries by looking to a 2009-03-13 16:40:51 +00:00
sun4v Change over the usb kernel options to the new stack (retaining existing 2009-02-23 18:34:56 +00:00
sys Bump __FreeBSD_version for the removal of IFF_NEEDSGIANT; network 2009-03-15 16:10:25 +00:00
tools
ufs The non-modifying EA VOPs are executed with only shared vnode lock taken. 2009-03-12 12:43:56 +00:00
vm Adjust some variables (mostly related to the buffer cache) that hold 2009-03-09 19:35:20 +00:00
xdr Add memmove() to the kernel, making the kernel compile with Clang. 2009-02-28 16:21:25 +00:00
xen Merge in support for Xen HVM on amd64 architecture. 2009-03-11 15:30:12 +00:00
Makefile