1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-03-09 15:40:03 +00:00

Fix ACL and set performance scaling governor for RPI

This commit is contained in:
Ycarus (Yannick Chabanois) 2020-06-09 22:37:53 +02:00
parent 09226a29a7
commit c4e6778a94
3 changed files with 12 additions and 2 deletions

View file

@ -42,6 +42,7 @@ start_service() {
# force CPU speed for RPI
uci -q set openmptcprouter.settings.scaling_min_freq=$(cat /sys/devices/system/cpu/cpufreq/policy0/scaling_max_freq | tr -d "\n")
uci -q set openmptcprouter.settings.scaling_max_freq=$(cat /sys/devices/system/cpu/cpufreq/policy0/scaling_max_freq | tr -d "\n")
uci -q set openmptcprouter.settings.scaling_governor='performance'
}
config_load openmptcprouter

View file

@ -101,4 +101,10 @@ if [ "$(uci -q get openmptcprouter.settings.enable_nodelay)" = "" ]; then
commit openmptcprouter
EOF
fi
if [ "$(uci -q get openmptcprouter.settings.scaling_governor)" = "" ]; then
uci -q batch <<-EOF >/dev/null
set openmptcprouter.settings.scaling_governor='performance'
commit openmptcprouter
EOF
fi
exit 0

View file

@ -2,10 +2,13 @@
"luci-app-openmptcprouter": {
"description": "Grant UCI access for luci-app-openmptcprouter",
"read": {
"uci": [ "'*" ]
"uci": [ "*" ],
"ubus": {
"openmptcprouter": [ "*" ]
}
},
"write": {
"uci": [ "'*" ]
"uci": [ "*" ]
}
}
}