Skip to content

Commit

Permalink
DEV 20200503
Browse files Browse the repository at this point in the history
uperf:让system_server的InputReader先读取触摸数据,或许能解决触摸丢帧
uperf:最大支持360hz触控采样率
uperf:进入SfLag的最大缓存次数从15提升到20
uperf:修复触摸中意外退出hint
sfanalysis:同步sfanalysis编译选项更改
高通EAS:修复费电模式在有大量高优先级线程跑在较少的大核数量时,容易发生拥塞
makefile:采用Riru的编译选项,或许能解决一部分兼容性问题
启动脚本:保存injector日志
启动脚本:兼容standlone模式libsfanalysis.so的路径
安装脚本:设置powerhint.json的SELinux文件类型为vendor_configs_file
挂载前脚本:如果powerhint.json不在系统内,不做覆盖

Signed-off-by: Matt Yang <[email protected]>
  • Loading branch information
yc9559 committed May 3, 2020
1 parent 38035a0 commit 1952c17
Show file tree
Hide file tree
Showing 11 changed files with 19 additions and 10 deletions.
3 changes: 3 additions & 0 deletions magisk/common/post-fs-data.sh
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
MODDIR=${0%/*}

# do not place empty powerhint.json if it doesn't exist in system
[ ! -f /vendor/etc/powerhint.json ] && rm $MODDIR/system/vendor/etc/powerhint.json
Empty file modified magisk/initsvc_uperf.sh
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion magisk/module.prop
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
id=uperf
name=Uperf
version=DEV 20200501
version=DEV 20200503
versionCode=1
author=Matt Yang
description=Userspace performance controller for android. Repo: https://github.com/yc9559/uperf/
Expand Down
Empty file modified magisk/run_uperf.sh
100644 → 100755
Empty file.
2 changes: 1 addition & 1 deletion magisk/script/libcommon.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Basic Tool Library
# https://github.com/yc9559/
# Author: Matt Yang
# Version: 20200501
# Version: 20200503

BASEDIR="$(dirname "$0")"
. $BASEDIR/pathinfo.sh
Expand Down
11 changes: 9 additions & 2 deletions magisk/script/libsfanalysis.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Surfaceflinger Analysis Library
# https://github.com/yc9559/
# Author: Matt Yang
# Version: 20200426
# Version: 20200503

BASEDIR="$(dirname "$0")"
. $BASEDIR/pathinfo.sh
Expand Down Expand Up @@ -34,5 +34,12 @@ sfa_start()
lib_path="/system/lib/$SFA_LIB"
fi

"$MODULE_PATH/$SFA_REL/$SFA_NAME" "/system/bin/surfaceflinger" "$lib_path"
# fallback to standlone mode
if [ ! -f "$lib_path" ]; then
lib_path="$BASEDIR/$lib_path"
setenforce 0
fi

echo "$(date '+%Y-%m-%d %H:%M:%S')" > /cache/injector.log
"$MODULE_PATH/$SFA_REL/$SFA_NAME" "/system/bin/surfaceflinger" "$lib_path" >> /cache/injector.log
}
2 changes: 1 addition & 1 deletion magisk/script/powercfg_main.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ save_panel()
write_panel ""
write_panel "Uperf https://github.com/yc9559/uperf/"
write_panel "Author: Matt Yang"
write_panel "Version: DEV 20200501"
write_panel "Version: DEV 20200503"
write_panel "Last performed: $(date '+%Y-%m-%d %H:%M:%S')"
write_panel ""
write_panel "[Uperf status]"
Expand Down
1 change: 1 addition & 0 deletions magisk/script/powercfg_once.sh
Original file line number Diff line number Diff line change
Expand Up @@ -229,4 +229,5 @@ lock_val "25" $LPM/bias_hyst
sfa_start

# start uperf once only
uperf_stop
uperf_start
8 changes: 3 additions & 5 deletions magisk/setup_uperf.sh
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Uperf Setup
# https://github.com/yc9559/
# Author: Matt Yang & cjybyjk ([email protected])
# Version: 20200501
# Version: 20200503

BASEDIR="$(dirname $(readlink -f "$0"))"

Expand Down Expand Up @@ -290,7 +290,7 @@ uperf_print_banner()
echo ""
echo "* Uperf https://github.com/yc9559/uperf/"
echo "* Author: Matt Yang"
echo "* Version: DEV 20200501"
echo "* Version: DEV 20200503"
echo ""
}

Expand Down Expand Up @@ -344,9 +344,7 @@ sfa_install()

powerhal_stub_install()
{
# compatiable with ver.0428 and lower
# do not place empty powerhint.json if it doesn't exist in system
[ "$(wc -l /vendor/etc/powerhint.json)" -le "5" ] && rm $BASEDIR/vendor/etc/powerhint.json
_set_perm "$BASEDIR/system/vendor/etc/powerhint.json" 0 0 0755 u:object_r:vendor_configs_file:s0
}

uperf_print_banner
Expand Down
Binary file modified magisk/sfanalysis/arm64-v8a/injector
Binary file not shown.
Binary file modified magisk/sfanalysis/armeabi-v7a/injector
Binary file not shown.

0 comments on commit 1952c17

Please sign in to comment.