From 45517faaf93e75f792a4065c6f17546da39337be Mon Sep 17 00:00:00 2001 From: Dmitry Skvortsov Date: Mon, 8 Nov 2021 22:38:36 +0300 Subject: [PATCH] Correct applying fsyncs patches on kernels 5.12 and below (#350) * prepare: Fix missing of futex_waitv patches for kernel 5.12 and below * cfg: Minor message/comment tweak --- customization.cfg | 2 +- linux-tkg-config/prepare | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/customization.cfg b/customization.cfg index 3316b40..0bbe26d 100644 --- a/customization.cfg +++ b/customization.cfg @@ -148,7 +148,7 @@ _acs_override="" _bcachefs="" # Set to "true" to enable support for fsync, an experimental replacement for esync found in Valve Proton 4.11+ - https://steamcommunity.com/games/221410/announcements/detail/2957094910196249305 -# Can be enabled alongside _futex_waitv on 5.14+ to use it as a fallback for older Proton builds +# Can be enabled alongside _futex_waitv on 5.13+ to use it as a fallback for older Proton builds _fsync="true" # Set to "true" to enable support for futex2, an experimental interface that can be used by proton-tkg and proton 5.13 experimental through Fsync - Can be enabled alongside fsync to use it as a fallback diff --git a/linux-tkg-config/prepare b/linux-tkg-config/prepare index 5b4b400..dc1655b 100644 --- a/linux-tkg-config/prepare +++ b/linux-tkg-config/prepare @@ -1078,6 +1078,8 @@ _tkg_srcprep() { _tkg_patcher _futex2="false" fi + else + _futex_waitv="false" fi # fsync support @@ -1120,7 +1122,8 @@ _tkg_srcprep() { fi fi - if [ "$_futex2" = "true" ] && [ "$_futex_waitv" != "true" ] && [ "$_basever" != "54" ] && [ "$_basever" != "57" ] && [ "$_basever" != "58" ] && [ "$_basever" != "59" ]; then + if ( [ "$_futex2" = "true" ] && [ -e "$srcdir/0007-v${_basekernel}-futex2_interface.patch" ] ) \ + && ( [ "$_futex_waitv" != "true" ] && [ -e "$srcdir/0007-v${_basekernel}-futex_waitv.patch" ] ); then sed -i -e 's/# CONFIG_EXPERT is not set/CONFIG_EXPERT=y/' ./.config echo -e "\r# start of config expert\r # CONFIG_DEBUG_RSEQ is not set\r