opnsense-src/sys/arm64
Randall Stewart b8d60729de tcp: Congestion control cleanup.
NOTE: HEADS UP read the note below if your kernel config is not including GENERIC!!

This patch does a bit of cleanup on TCP congestion control modules. There were some rather
interesting surprises that one could get i.e. where you use a socket option to change
from one CC (say cc_cubic) to another CC (say cc_vegas) and you could in theory get
a memory failure and end up on cc_newreno. This is not what one would expect. The
new code fixes this by requiring a cc_data_sz() function so we can malloc with M_WAITOK
and pass in to the init function preallocated memory. The CC init is expected in this
case *not* to fail but if it does and a module does break the
"no fail with memory given" contract we do fall back to the CC that was in place at the time.

This also fixes up a set of common newreno utilities that can be shared amongst other
CC modules instead of the other CC modules reaching into newreno and executing
what they think is a "common and understood" function. Lets put these functions in
cc.c and that way we have a common place that is easily findable by future developers or
bug fixers. This also allows newreno to evolve and grow support for its features i.e. ABE
and HYSTART++ without having to dance through hoops for other CC modules, instead
both newreno and the other modules just call into the common functions if they desire
that behavior or roll there own if that makes more sense.

Note: This commit changes the kernel configuration!! If you are not using GENERIC in
some form you must add a CC module option (one of CC_NEWRENO, CC_VEGAS, CC_CUBIC,
CC_CDG, CC_CHD, CC_DCTCP, CC_HTCP, CC_HD). You can have more than one defined
as well if you desire. Note that if you create a kernel configuration that does not
define a congestion control module and includes INET or INET6 the kernel compile will
break. Also you need to define a default, generic adds 'options CC_DEFAULT=\"newreno\"
but you can specify any string that represents the name of the CC module (same names
that show up in the CC module list under net.inet.tcp.cc). If you fail to add the
options CC_DEFAULT in your kernel configuration the kernel build will also break.

Reviewed by: Michael Tuexen
Sponsored by: Netflix Inc.
RELNOTES:YES
Differential Revision: https://reviews.freebsd.org/D32693
2021-11-11 06:28:18 -05:00
..
acpica Remove "All Rights Reserved" from FreeBSD Foundation sys/ copyrights 2021-08-08 10:42:24 -04:00
arm64 arm64/gicv3: improve a panic message 2021-11-10 09:41:57 +00:00
broadcom genet: pullup minimum header amount for IPv4 2021-06-26 11:04:02 -05:00
cavium Remove "All Rights Reserved" from FreeBSD Foundation sys/ copyrights 2021-08-08 10:42:24 -04:00
conf tcp: Congestion control cleanup. 2021-11-11 06:28:18 -05:00
coresight arm64: clean up empty lines in .c and .h files 2020-09-01 21:18:06 +00:00
freescale/imx Add the clock for the imx8 thermal monitoring unit. 2021-09-28 11:51:57 -06:00
include Allocate arm64 per-CPU data in the correct domain 2021-10-11 10:36:50 +01:00
intel Add support for Intel Stratix 10 platform. 2019-09-13 16:50:57 +00:00
iommu Use the vm_radix_init() helper when initializing pmaps 2021-10-19 21:22:56 -04:00
linux linux: Replace ifdefs in ptrace with per-architecture callbacks 2021-11-09 11:59:17 +00:00
nvidia/tegra210 arm64: Directly use #include <dt-binding/...> 2021-01-15 20:07:19 +01:00
qoriq Introduce qoriq_gpio_pic driver 2021-11-06 09:08:45 +01:00
qualcomm
rockchip rk805: add system poweroff support 2021-11-06 19:58:43 +02:00