Commit 3d470598 authored by Alberts Muktupāvels's avatar Alberts Muktupāvels

cpufreq: fix -Wabsolute-value warning

parent 6651962a
......@@ -101,7 +101,10 @@ cpufreq_selector_get_valid_frequency (CPUFreqSelector *selector,
return frequency;
}
current_dist = abs (freq->frequency - frequency);
if (freq->frequency > frequency)
current_dist = freq->frequency - frequency;
else
current_dist = frequency - freq->frequency;
if (current_dist < dist)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment