Skip to content

Commit

Permalink
tools/power/x86/intel-speed-select: Display AMX base frequency
Browse files Browse the repository at this point in the history
AMX frequency is present in non TPMI platforms also. When platform
supports, the value is non zero. So, display AMX base frequency when
non zero, irrespective of platform API version.

Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
  • Loading branch information
Srinivas Pandruvada committed Mar 22, 2023
1 parent 997074d commit a835ff5
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions tools/power/x86/intel-speed-select/isst-core-mbox.c
Original file line number Diff line number Diff line change
@@ -383,10 +383,11 @@ static void _get_p1_info(struct isst_id *id, int config_index,
ctdp_level->sse_p1 = resp & GENMASK(7, 0);
ctdp_level->avx2_p1 = (resp & GENMASK(15, 8)) >> 8;
ctdp_level->avx512_p1 = (resp & GENMASK(23, 16)) >> 16;
ctdp_level->amx_p1 = (resp & GENMASK(31, 24)) >> 24;
debug_printf(
"cpu:%d ctdp:%d CONFIG_TDP_GET_P1_INFO resp:%x sse_p1:%d avx2_p1:%d avx512_p1:%d\n",
"cpu:%d ctdp:%d CONFIG_TDP_GET_P1_INFO resp:%x sse_p1:%d avx2_p1:%d avx512_p1:%d amx_p1:%d\n",
id->cpu, config_index, resp, ctdp_level->sse_p1,
ctdp_level->avx2_p1, ctdp_level->avx512_p1);
ctdp_level->avx2_p1, ctdp_level->avx512_p1, ctdp_level->amx_p1);
}

static void _get_uncore_mem_freq(struct isst_id *id, int config_index,
2 changes: 1 addition & 1 deletion tools/power/x86/intel-speed-select/isst-display.c
Original file line number Diff line number Diff line change
@@ -424,7 +424,7 @@ void isst_ctdp_display_information(struct isst_id *id, FILE *outf, int tdp_level
format_and_print(outf, level + 2, header, value);
}

if (api_version() > 1 && ctdp_level->amx_p1) {
if (ctdp_level->amx_p1) {
snprintf(header, sizeof(header), "base-frequency-amx(MHz)");
snprintf(value, sizeof(value), "%d",
ctdp_level->amx_p1 * isst_get_disp_freq_multiplier());

0 comments on commit a835ff5

Please sign in to comment.