From 339fcef9154d50542fefbd10f764f8c86aeb83e3 Mon Sep 17 00:00:00 2001 From: yzyhk904 <86816519+yzyhk904@users.noreply.github.com> Date: Tue, 3 Oct 2023 16:40:28 +0900 Subject: [PATCH] Add files via upload * Changed the re-sampling parameters for Galaxy S4 to the general purpose ones (optimized for 3.5mm jack; not USB DAC's) * Reduced I/O scheduling jitter on Tensor and SDM660 devices * Reduced CFQ I/O scheduling jitter on Qcomm devices --- changelog.md | 5 +++ customize-functions.sh | 5 --- jitter-reducer-functions.shlib | 56 +++++++++++++++++----------------- module.prop | 4 +-- 4 files changed, 35 insertions(+), 35 deletions(-) diff --git a/changelog.md b/changelog.md index 329d627..b608a5b 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,10 @@ ## Change logs +# v2.5.3 +* Changed the re-sampling parameters for Galaxy S4 to the general purpose ones (optimized for 3.5mm jack; not USB DAC's) +* Reduced I/O scheduling jitter on Tensor and SDM660 devices +* Reduced CFQ I/O scheduling jitter on Qcomm devices + # v2.5.2 * Tuned tunables of I/O scheduler * Added warning messages for unneeded magisk modules diff --git a/customize-functions.sh b/customize-functions.sh index 2ae0e82..dd4d063 100644 --- a/customize-functions.sh +++ b/customize-functions.sh @@ -210,11 +210,6 @@ function replaceSystemProps_S4() fi - sed -i \ - -e 's/ro\.audio\.resampler\.psd\.stopband=.*$/ro\.audio\.resampler\.psd\.stopband=194/' \ - -e 's/ro\.audio\.resampler\.psd\.halflength=.*$/ro\.audio\.resampler\.psd\.halflength=520/' \ - -e 's/ro\.audio\.resampler\.psd\.tbwcheat=.*$/ro\.audio\.resampler\.psd\.cutoff_percent=100/' \ - "$MODPATH/system.prop" sed -i \ -e 's/ro\.audio\.resampler\.psd\.halflength=.*$/ro\.audio\.resampler\.psd\.halflength=320/' \ "$MODPATH/system.prop-workaround" diff --git a/jitter-reducer-functions.shlib b/jitter-reducer-functions.shlib index 83f9a3d..ba18bea 100644 --- a/jitter-reducer-functions.shlib +++ b/jitter-reducer-functions.shlib @@ -1148,7 +1148,7 @@ function getSchedulerParams() ;; "cfq" ) echo "back_seek_penalty fifo_expire_async fifo_expire_sync group_idle low_latency quantum slice_async slice_async_rq \ - slice_idle slice_sync target_latency" + slice_async_us slice_idle slice_sync target_latency" ;; "kyber" ) echo "read_lat_nsec write_lat_nsec" @@ -1208,16 +1208,16 @@ function getSchedulerValues() "exp" ) case "`getSocModelName`" in sdm8[5-9]* | sdm9* ) - echo "92 0 36 516 0" + echo "95 0 36 516 0" ;; gs* ) - echo "92 0 36 516 0" + echo "96 0 36 516 0" ;; sdm8* ) - echo "92 0 34 516 0" + echo "96 0 36 516 0" ;; sdm* | msm* | sd* | exynos* ) - echo "92 0 34 516 0" + echo "96 0 34 516 0" ;; mt68* ) echo "92 0 36 516 0" @@ -1233,16 +1233,16 @@ function getSchedulerValues() "boost" ) case "`getSocModelName`" in sdm8[5-9]* | sdm9* ) - echo "92 0 36 516 0" + echo "95 0 36 516 0" ;; gs* ) - echo "92 0 36 516 0" + echo "96 0 36 516 0" ;; sdm8* ) - echo "92 0 34 516 0" + echo "96 0 36 516 0" ;; sdm* | msm* | sd* | exynos* ) - echo "92 0 34 516 0" + echo "96 0 34 516 0" ;; mt68* ) echo "92 0 36 516 0" @@ -1285,31 +1285,31 @@ function getSchedulerValues() "cfq" ) # back_seek_penalty fifo_expire_async fifo_expire_sync group_idle low_latency quantum slice_async slice_async_rq - # slice_idle slice_sync target_latency + # slice_async_us slice_idle slice_sync target_latency case "$2" in "light" ) - echo "1 3 3 0 1 1 3 34 0 3 3" + echo "1 3 3 0 1 1 3 34 3000 0 3 3" ;; "m-light" ) - echo "1 3 3 0 1 1 3 46 0 3 3" + echo "1 3 3 0 1 1 3 46 3000 0 3 3" ;; "boost" ) case "`getSocModelName`" in - sdm* | mt68* | gs* ) - echo "1 2 2 0 1 1 2 59 0 2 1" + sdm* | mt68* | gs* | sd* | exynos* ) + echo "1 2 2 0 1 1 2 59 1541 0 2 1" ;; * ) - echo "1 3 3 0 1 1 3 59 0 3 3" + echo "1 3 3 0 1 1 3 59 3000 0 3 3" ;; esac ;; "medium" | * ) case "`getSocModelName`" in - sdm* | mt68* | gs* ) - echo "1 3 3 0 1 1 3 51 0 3 3" + sdm* | mt68* | gs* | sd* | exynos* ) + echo "1 3 3 0 1 1 3 51 3000 0 3 3" ;; * ) - echo "1 3 3 0 1 1 3 51 0 3 3" + echo "1 3 3 0 1 1 3 51 3000 0 3 3" ;; esac ;; @@ -1388,13 +1388,13 @@ function getSchedulerNrRequests() "exp" ) case "`getSocModelName`" in sdm8[5-9]* | sdm9* ) - echo "86163" + echo "86171" ;; gs* ) - echo "86153" + echo "86163" ;; sdm8* ) - echo "86163" + echo "86171" ;; sdm* | msm* | sd* | exynos* ) echo "86163" @@ -1413,13 +1413,13 @@ function getSchedulerNrRequests() "boost" ) case "`getSocModelName`" in sdm8[5-9]* | sdm9* ) - echo "86163" + echo "86171" ;; gs* ) - echo "86153" + echo "86163" ;; sdm8* ) - echo "86163" + echo "86171" ;; sdm* | msm* | sd* | exynos* ) echo "86163" @@ -1485,10 +1485,10 @@ function getSchedulerNrRequests() "boost" ) case "`getSocModelName`" in sdm* | msm* | sd* | exynos* | gs* ) - echo "86161" + echo "86163" ;; * ) - echo "86161" + echo "86163" ;; esac ;; @@ -1603,10 +1603,10 @@ function reduceIoJitter() # For Tensor devices (5.10 Kernels) if [ "$sched" = "mq-deadline" ]; then if [ -w "/sys/block/$i/queue/iosched/async_depth" ]; then - echo '35' >"/sys/block/$i/queue/iosched/async_depth" + echo '38' >"/sys/block/$i/queue/iosched/async_depth" fi if [ -w "/sys/block/$i/queue/iosched/prio_aging_expire" ]; then - echo '6903148' >"/sys/block/$i/queue/iosched/prio_aging_expire" + echo '6903156' >"/sys/block/$i/queue/iosched/prio_aging_expire" fi fi diff --git a/module.prop b/module.prop index bd55b05..ac35d36 100644 --- a/module.prop +++ b/module.prop @@ -1,6 +1,6 @@ id=hifi-maximizer-mod name=Hifi Maximizer -version=v2.5.2 -versionCode=2502 +version=v2.5.3 +versionCode=2503 author=zyhk description=A module for maximizing the digital audio fidelity by reducing jitters on audio outputs (USB DACs, Bluetooth a2dp, DLNA, etc.)