Skip to content

Commit 7b00d10

Browse files
committed
tools/power/x86/intel-speed-select: turbo-mode enable disable swapped
The command for turbo-mode enable and disable is swapped. Fix that. Previously turbo-mode enable was actually disabling and disable was enabling. Signed-off-by: Srinivas Pandruvada <[email protected]>
1 parent 3076db3 commit 7b00d10

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

tools/power/x86/intel-speed-select/isst-config.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2527,22 +2527,22 @@ static void set_turbo_mode_for_cpu(struct isst_id *id, int status)
25272527
}
25282528

25292529
if (status) {
2530-
isst_display_result(id, outf, "turbo-mode", "enable", 0);
2531-
} else {
25322530
isst_display_result(id, outf, "turbo-mode", "disable", 0);
2531+
} else {
2532+
isst_display_result(id, outf, "turbo-mode", "enable", 0);
25332533
}
25342534
}
25352535

25362536
static void set_turbo_mode(int arg)
25372537
{
2538-
int i, enable = arg;
2538+
int i, disable = arg;
25392539
struct isst_id id;
25402540

25412541
if (cmd_help) {
2542-
if (enable)
2543-
fprintf(stderr, "Set turbo mode enable\n");
2544-
else
2542+
if (disable)
25452543
fprintf(stderr, "Set turbo mode disable\n");
2544+
else
2545+
fprintf(stderr, "Set turbo mode enable\n");
25462546
exit(0);
25472547
}
25482548

@@ -2560,7 +2560,7 @@ static void set_turbo_mode(int arg)
25602560

25612561
if (online) {
25622562
set_isst_id(&id, i);
2563-
set_turbo_mode_for_cpu(&id, enable);
2563+
set_turbo_mode_for_cpu(&id, disable);
25642564
}
25652565

25662566
}

0 commit comments

Comments
 (0)