Message ID | 20160904225923.27993-1-steven@uplinklabs.net (mailing list archive) |
---|---|
State | Deferred |
Headers | show |
diff --git a/tools/power/cpupower/bench/system.c b/tools/power/cpupower/bench/system.c index c25a74a..b05a979 100644 --- a/tools/power/cpupower/bench/system.c +++ b/tools/power/cpupower/bench/system.c @@ -61,9 +61,9 @@ int set_cpufreq_governor(char *governor, unsigned int cpu) dprintf("set %s as cpufreq governor\n", governor); - if (cpupower_is_cpu_online(cpu) != 0) { - perror("cpufreq_cpu_exists"); - fprintf(stderr, "error: cpu %u does not exist\n", cpu); + if (cpupower_is_cpu_online(cpu) != 1) { + perror("cpufreq_is_cpu_online"); + fprintf(stderr, "error: cpu %u is not online\n", cpu); return -1; }
Another case of incorrectly assuming the same return values as 'cpufreq_cpu_exists' (which used to return 0 on success). Signed-off-by: Steven Noonan <steven@uplinklabs.net> --- tools/power/cpupower/bench/system.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)