tools/power/x86/intel-speed-select: Remove cpu mask display for non-cpu power domain

Non CPU power domains will not have any CPUs. So don't display any CPU
count or enable mask.

Signed-off-by: Zhang Rui <rui.zhang@intel.com>
[srinivas.pandruvada@linux.intel.com: subject and changelog edits]
Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
This commit is contained in:
Zhang Rui 2022-08-18 21:26:23 +08:00 committed by Srinivas Pandruvada
parent c5a295caef
commit c7ff8ff3b2

View File

@ -356,6 +356,7 @@ void isst_ctdp_display_information(struct isst_id *id, FILE *outf, int tdp_level
ctdp_level->level);
format_and_print(outf, level + 1, header, NULL);
if (id->cpu >= 0) {
snprintf(header, sizeof(header), "cpu-count");
j = get_cpu_count(id);
snprintf(value, sizeof(value), "%d", j);
@ -382,6 +383,7 @@ void isst_ctdp_display_information(struct isst_id *id, FILE *outf, int tdp_level
ctdp_level->core_cpumask);
format_and_print(outf, level + 2, header, value);
}
}
snprintf(header, sizeof(header), "thermal-design-power-ratio");
snprintf(value, sizeof(value), "%d", ctdp_level->tdp_ratio);