diff --git a/customization.cfg b/customization.cfg index 26f5ce4..7ff4c7a 100644 --- a/customization.cfg +++ b/customization.cfg @@ -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" diff --git a/linux-tkg-config/prepare b/linux-tkg-config/prepare index f7e78e7..707063b 100644 --- a/linux-tkg-config/prepare +++ b/linux-tkg-config/prepare @@ -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