diff options
3 files changed, 3 insertions, 3 deletions
diff --git a/cpufreq/src/cpufreq-selector/cpufreq-selector-libcpufreq.c b/cpufreq/src/cpufreq-selector/cpufreq-selector-libcpufreq.c index d2fda2bf..d56364b5 100644 --- a/cpufreq/src/cpufreq-selector/cpufreq-selector-libcpufreq.c +++ b/cpufreq/src/cpufreq-selector/cpufreq-selector-libcpufreq.c @@ -106,7 +106,7 @@ cpufreq_selector_libcpufreq_get_valid_frequency (CPUFreqSelectorLibcpufreq *sele return frequency; } - current_dist = abs (freq->frequency - frequency); + current_dist = abs ((int)freq->frequency - (int)frequency); if (current_dist < dist) { dist = current_dist; retval = freq->frequency; diff --git a/cpufreq/src/cpufreq-selector/cpufreq-selector-procfs.c b/cpufreq/src/cpufreq-selector/cpufreq-selector-procfs.c index 3ee43c47..69ecaf77 100644 --- a/cpufreq/src/cpufreq-selector/cpufreq-selector-procfs.c +++ b/cpufreq/src/cpufreq-selector/cpufreq-selector-procfs.c @@ -184,7 +184,7 @@ cpufreq_selector_procfs_set_frequency (CPUFreqSelector *selector, } if (frequency != sc_max && frequency != sc_min) { - if (abs (sc_max - frequency) < abs (frequency - sc_min)) + if (abs ((int)sc_max - (int)frequency) < abs ((int)frequency - (int)sc_min)) freq = sc_max; else freq = sc_min; diff --git a/cpufreq/src/cpufreq-selector/cpufreq-selector-sysfs.c b/cpufreq/src/cpufreq-selector/cpufreq-selector-sysfs.c index 1cb87660..c1b0850c 100644 --- a/cpufreq/src/cpufreq-selector/cpufreq-selector-sysfs.c +++ b/cpufreq/src/cpufreq-selector/cpufreq-selector-sysfs.c @@ -241,7 +241,7 @@ cpufreq_selector_sysfs_get_valid_frequency (CPUFreqSelectorSysfs *selector, if (f == frequency) return freq; - current_dist = abs (frequency - f); + current_dist = abs ((int)frequency - (int)f); if (current_dist < dist) { dist = current_dist; retval = freq; |