summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZhang Rui <rui.zhang@intel.com>2026-03-19 08:52:54 +0300
committerSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>2026-04-05 21:46:21 +0300
commit3e244dd513e26728577f1e4deca6fdf749b6f244 (patch)
tree5e1f46e1196454c661d33289b2373070b9040fa2
parentdf4a83543117c7fc27077fd7f4ffe870556b257b (diff)
downloadlinux-3e244dd513e26728577f1e4deca6fdf749b6f244.tar.xz
tools/power/x86/intel-speed-select: Fix some program return value
When running the "intel-speed-select -h" command, it returns 1. 0 when using a version that is API incompatible. 2. 1 when using a version that is API compatible. And this is confusing. Fix the program to return 0 for "-h" parameter, and return 1 whenever "Incompatible API versions" is detected. Signed-off-by: Zhang Rui <rui.zhang@intel.com> Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
-rw-r--r--tools/power/x86/intel-speed-select/isst-config.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/power/x86/intel-speed-select/isst-config.c b/tools/power/x86/intel-speed-select/isst-config.c
index 3f2573ecca76..b1376411cfa4 100644
--- a/tools/power/x86/intel-speed-select/isst-config.c
+++ b/tools/power/x86/intel-speed-select/isst-config.c
@@ -1139,7 +1139,7 @@ static int isst_fill_platform_info(void)
if (isst_platform_info.api_version > supported_api_ver) {
printf("Incompatible API versions; Upgrade of tool is required\n");
- return -1;
+ exit(1);
}
set_platform_ops:
@@ -3195,7 +3195,7 @@ static void usage(void)
printf("\tTo get full turbo-freq information dump:\n");
printf("\t\tintel-speed-select turbo-freq info -l 0\n");
}
- exit(1);
+ exit(0);
}
static void print_version(void)