diff --git a/linux54-tkg/PKGBUILD b/linux54-tkg/PKGBUILD index 4e77053..4bb43ad 100644 --- a/linux54-tkg/PKGBUILD +++ b/linux54-tkg/PKGBUILD @@ -74,7 +74,16 @@ elif [ "$_cpusched" == "pds" ]; then elif [ "$_cpusched" == "bmq" ]; then echo "_cpusched=\"bmq\"" > "$_where"/cpuschedset else - echo "_cpusched=\"cfs\"" > "$_where"/cpuschedset + if [ "$_nofallback" != "true" ]; then + warning "Something is wrong with your cpusched selection. Do you want to fallback to CFS (default)?" + read -rp "`echo $' > N/y : '`" _fallback; + fi + if [ "$_fallback" == "y" ] || [ "$_nofallback" == "true" ]; then + echo "_cpusched=\"cfs\"" > "$_where"/cpuschedset + else + error "Exiting..." + exit 1 + fi fi source "$_where"/cpuschedset diff --git a/linux54-tkg/linux54-tkg-config/prepare b/linux54-tkg/linux54-tkg-config/prepare index 5012255..63999db 100644 --- a/linux54-tkg/linux54-tkg-config/prepare +++ b/linux54-tkg/linux54-tkg-config/prepare @@ -93,7 +93,7 @@ _tkg_srcprep() { # BMQ patch -Np1 -i ../0009-bmq_v5.4-r2.patch patch -Np1 -i ../0009-glitched-bmq.patch - else + elif [ "${_cpusched}" == "cfs" ]; then patch -Np1 -i ../0003-glitched-cfs.patch fi diff --git a/linux57-tkg/linux57-tkg-config/prepare b/linux57-tkg/linux57-tkg-config/prepare index a556ddb..1efdfdc 100644 --- a/linux57-tkg/linux57-tkg-config/prepare +++ b/linux57-tkg/linux57-tkg-config/prepare @@ -53,7 +53,16 @@ _tkg_initscript() { elif [ "$_cpusched" == "bmq" ]; then echo "_cpusched=\"bmq\"" > "$_where"/cpuschedset else - echo "_cpusched=\"cfs\"" > "$_where"/cpuschedset + if [ "$_nofallback" != "true" ]; then + warning "Something is wrong with your cpusched selection. Do you want to fallback to CFS (default)?" + read -rp "`echo $' > N/y : '`" _fallback; + fi + if [ "$_fallback" == "y" ] || [ "$_nofallback" == "true" ]; then + echo "_cpusched=\"cfs\"" > "$_where"/cpuschedset + else + error "Exiting..." + exit 1 + fi fi source "$_where"/cpuschedset @@ -182,7 +191,6 @@ _tkg_srcprep() { patch -Np1 -i "$srcdir"/0005-glitched-pds.patch elif [ "${_cpusched}" == "bmq" ]; then - # Project C / BMQ msg2 "Applying Project C / BMQ base patch" @@ -195,7 +203,8 @@ _tkg_srcprep() { msg2 "Applying Glitched BMQ patch" patch -Np1 -i "$srcdir"/0009-glitched-bmq.patch - else + + elif [ "${_cpusched}" == "cfs" ]; then msg2 "Applying Glitched CFS patch" patch -Np1 -i "$srcdir"/0003-glitched-cfs.patch fi diff --git a/linux58-tkg/PKGBUILD b/linux58-tkg/PKGBUILD index abb66ea..0b90ae9 100644 --- a/linux58-tkg/PKGBUILD +++ b/linux58-tkg/PKGBUILD @@ -72,8 +72,16 @@ elif [ "$_cpusched" == "cfs" ]; then elif [ "$_cpusched" == "bmq" ]; then echo "_cpusched=\"bmq\"" > "$_where"/cpuschedset else - warning "Invalid selection - Falling back to CFS..." - echo "_cpusched=\"cfs\"" > "$_where"/cpuschedset + if [ "$_nofallback" != "true" ]; then + warning "Something is wrong with your cpusched selection. Do you want to fallback to CFS (default)?" + read -rp "`echo $' > N/y : '`" _fallback; + fi + if [ "$_fallback" == "y" ] || [ "$_nofallback" == "true" ]; then + echo "_cpusched=\"cfs\"" > "$_where"/cpuschedset + else + error "Exiting..." + exit 1 + fi fi source "$_where"/cpuschedset diff --git a/linux58-tkg/linux58-tkg-config/prepare b/linux58-tkg/linux58-tkg-config/prepare index 1917341..d1af626 100644 --- a/linux58-tkg/linux58-tkg-config/prepare +++ b/linux58-tkg/linux58-tkg-config/prepare @@ -54,7 +54,7 @@ _tkg_srcprep() { patch -Np1 -i ../0009-glitched-ondemand-bmq.patch fi patch -Np1 -i ../0009-glitched-bmq.patch - else + elif [ "${_cpusched}" == "cfs" ]; then patch -Np1 -i ../0003-glitched-cfs.patch fi