From 11cfa7b305b2a4e7af55a53948d86d56addc40f0 Mon Sep 17 00:00:00 2001 From: CN_SZTL Date: Sun, 23 Aug 2020 22:53:46 +0800 Subject: [PATCH] luci-app-cpufreq: upthreshold/factor: depend on ondemand --- package/lean/luci-app-cpufreq/luasrc/model/cbi/cpufreq.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/package/lean/luci-app-cpufreq/luasrc/model/cbi/cpufreq.lua b/package/lean/luci-app-cpufreq/luasrc/model/cbi/cpufreq.lua index 78fc09ec2f..8777d74ba0 100644 --- a/package/lean/luci-app-cpufreq/luasrc/model/cbi/cpufreq.lua +++ b/package/lean/luci-app-cpufreq/luasrc/model/cbi/cpufreq.lua @@ -49,6 +49,7 @@ upthreshold.rmempty = false upthreshold.description = translate("Kernel make a decision on whether it should increase the frequency (%)") upthreshold.placeholder = 50 upthreshold.default = 50 +upthreshold:depends("governor", "ondemand") factor = s:option(Value, "factor", translate("CPU Switching Sampling rate")) factor.datatype="range(1,100000)" @@ -56,5 +57,6 @@ factor.rmempty = false factor.description = translate("The sampling rate determines how frequently the governor checks to tune the CPU (ms)") factor.placeholder = 10 factor.default = 10 +factor:depends("governor", "ondemand") return mp