Add toggle for default TCP algorithm (#210)
* Make YEAH default closes #172 * Make default TCP algorithm choice a config toggle * Add Vegas TCP algorithm, fix westwood * Simplify TCP alg choice code * tcp algs: fix mistake from copy-pasta
This commit is contained in:
parent
146a07f7bd
commit
de79aadd81
@ -189,6 +189,12 @@ _aggressive_ondemand="true"
|
||||
# https://github.com/Tk-Glitch/PKGBUILDS/issues/263
|
||||
_disable_acpi_cpufreq=""
|
||||
|
||||
# [Advanced] Default TCP IPv4 algorithm to use. Options are: "yeah", "bbr", "cubic", "reno", "vegas" and "westwood". Leave empty if unsure.
|
||||
# This config option will not be prompted
|
||||
# Can be changed at runtime with the command line `# echo "$name" > /proc/sys/net/ipv4/tcp_congestion_control` where $name is one of the options above.
|
||||
# Default (empty) and fallback : cubic
|
||||
_tcp_cong_alg=""
|
||||
|
||||
# You can pass a default set of kernel command line options here - example: "intel_pstate=passive nowatchdog amdgpu.ppfeaturemask=0xfffd7fff mitigations=off"
|
||||
_custom_commandline="intel_pstate=passive"
|
||||
|
||||
|
@ -742,6 +742,31 @@ CONFIG_DEBUG_INFO_BTF_MODULES=y\n
|
||||
sed -i -e 's/CONFIG_DEBUG_PREEMPT=y/# CONFIG_DEBUG_PREEMPT is not set/' ./.config
|
||||
fi
|
||||
|
||||
# TCP algorithms
|
||||
_tcp_cong_alg_list=("yeah" "bbr" "cubic" "vegas" "westwood" "reno")
|
||||
_user_set_tcp_alg="false"
|
||||
|
||||
./scripts/config --enable TCP_CONG_ADVANCED
|
||||
|
||||
for _alg in "${_tcp_cong_alg_list[@]}"
|
||||
do
|
||||
./scripts/config --enable TCP_CONG_${_alg}
|
||||
./scripts/config --disable DEFAULT_${_alg}
|
||||
if [ "$_tcp_cong_alg" = "$_alg" ];then
|
||||
_user_set_tcp_alg="true"
|
||||
./scripts/config --enable DEFAULT_${_alg}
|
||||
./scripts/config --set-str DEFAULT_TCP_CONG "${_alg}"
|
||||
fi
|
||||
done
|
||||
|
||||
if [ "$_user_set_tcp_alg" = "false" ];then
|
||||
./scripts/config --enable DEFAULT_CUBIC
|
||||
./scripts/config --set-str DEFAULT_TCP_CONG "cubic"
|
||||
fi
|
||||
|
||||
#######
|
||||
|
||||
|
||||
if [ "${_cpusched}" = "MuQSS" ]; then
|
||||
# MuQSS default config
|
||||
echo "CONFIG_SCHED_MUQSS=y" >> ./.config
|
||||
|
Loading…
Reference in New Issue
Block a user