cpufreq: skip redudant freq variable check
This commit is contained in:
parent
97e54d60f8
commit
0741531efd
|
@ -39,13 +39,13 @@ local function worker(format, warg)
|
||||||
if freq then
|
if freq then
|
||||||
freqv.mhz = freq / 1000
|
freqv.mhz = freq / 1000
|
||||||
freqv.ghz = freqv.mhz / 1000
|
freqv.ghz = freqv.mhz / 1000
|
||||||
end
|
|
||||||
|
|
||||||
-- Get the current voltage
|
-- Get the current voltage
|
||||||
if cpufreq.scaling_voltages and freq then
|
if cpufreq.scaling_voltages then
|
||||||
freqv.mv = tonumber(string.match(cpufreq.scaling_voltages, freq.."[%s]([%d]+)"))
|
freqv.mv = tonumber(string.match(cpufreq.scaling_voltages, freq.."[%s]([%d]+)"))
|
||||||
-- Calculate voltage from mV
|
-- Calculate voltage from mV
|
||||||
freqv.v = freqv.mv / 1000
|
freqv.v = freqv.mv / 1000
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
-- Get the current governor
|
-- Get the current governor
|
||||||
|
|
Loading…
Reference in New Issue