From: Thomas Renninger Date: Tue, 13 May 2014 10:41:44 +0000 (+0200) Subject: cpupower: cpupower info -b should return 0 on success, not the perf bias value X-Git-Tag: firefly_0821_release~176^2~3768^2~5^2^3~1 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=3fc5a0e51aef4503b6a06ef35409370eed568684;p=firefly-linux-kernel-4.4.55.git cpupower: cpupower info -b should return 0 on success, not the perf bias value Signed-off-by: Thomas Renninger Signed-off-by: Rafael J. Wysocki --- diff --git a/tools/power/cpupower/utils/cpupower-info.c b/tools/power/cpupower/utils/cpupower-info.c index 3f68632c28c7..0ac25772bf63 100644 --- a/tools/power/cpupower/utils/cpupower-info.c +++ b/tools/power/cpupower/utils/cpupower-info.c @@ -125,11 +125,12 @@ int cmd_info(int argc, char **argv) if (params.perf_bias) { ret = msr_intel_get_perf_bias(cpu); if (ret < 0) { - printf(_("Could not read perf-bias value\n")); - break; + fprintf(stderr, + _("Could not read perf-bias value[%d]\n"), ret); + exit(EXIT_FAILURE); } else printf(_("perf-bias: %d\n"), ret); } } - return ret; + return 0; }