summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>2025-03-05 22:03:15 +0300
committerSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>2025-03-07 19:00:21 +0300
commit7ad93737ddf355d57cbdd2e769fc6a0802019b46 (patch)
tree137a60e9e92ba08c42c419298f236379f78cd63b
parentc49e805db30674293d6a595db52549addd9d611f (diff)
downloadlinux-7ad93737ddf355d57cbdd2e769fc6a0802019b46.tar.xz
tools/power/x86/intel-speed-select: Die ID for IO dies
Instead of displaying "-1" for IO dies, display "IO". Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
-rw-r--r--tools/power/x86/intel-speed-select/isst-display.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/tools/power/x86/intel-speed-select/isst-display.c b/tools/power/x86/intel-speed-select/isst-display.c
index 07ebd08f3202..da5a59a4c545 100644
--- a/tools/power/x86/intel-speed-select/isst-display.c
+++ b/tools/power/x86/intel-speed-select/isst-display.c
@@ -173,7 +173,11 @@ static int print_package_info(struct isst_id *id, FILE *outf)
if (out_format_is_json()) {
if (api_version() > 1) {
- if (id->cpu < 0)
+ if (id->die < 0 && id->cpu < 0)
+ snprintf(header, sizeof(header),
+ "package-%d:die-IO:powerdomain-%d:cpu-None",
+ id->pkg, id->punit);
+ else if (id->cpu < 0)
snprintf(header, sizeof(header),
"package-%d:die-%d:powerdomain-%d:cpu-None",
id->pkg, id->die, id->punit);
@@ -190,7 +194,10 @@ static int print_package_info(struct isst_id *id, FILE *outf)
}
snprintf(header, sizeof(header), "package-%d", id->pkg);
format_and_print(outf, level++, header, NULL);
- snprintf(header, sizeof(header), "die-%d", id->die);
+ if (id->die < 0)
+ snprintf(header, sizeof(header), "die-IO");
+ else
+ snprintf(header, sizeof(header), "die-%d", id->die);
format_and_print(outf, level++, header, NULL);
if (api_version() > 1) {
snprintf(header, sizeof(header), "powerdomain-%d", id->punit);