Skip to content

Commit b9695b5

Browse files
committed
debug: print version from PLR_HEADER
Change-Id: Ib9352a39226d1bce667b059940d8dac486830592
1 parent 285417a commit b9695b5

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/pcm-power.cpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,10 +113,15 @@ namespace PERF_LIMIT_REASON_TPMI
113113
TPMIHandle h(i, PERF_LIMIT_REASON_TPMI_ID, PERF_LIMIT_REASON_TPMI_HEADER);
114114
for (uint32 j = 0; j < h.getNumEntries(); ++j)
115115
{
116-
if (h.read64(j) == ~0ULL)
116+
const auto header = h.read64(j);
117+
if (header == ~0ULL)
117118
{
118119
return false;
119120
}
121+
const auto version = extract_bits_64(header, 7, 0);
122+
const auto majorVersion = extract_bits_64(header, 7, 5);
123+
const auto minorVersion = extract_bits_64(header, 4, 0);
124+
DBG(1, "PLR_HEADER.INTERFACE_VERSION instance ", i, " die ", j, " version ", version, " (major version ", majorVersion, " minor version ", minorVersion, ")");
120125
PERF_LIMIT_REASON_TPMI_Supported = true;
121126
}
122127
}

0 commit comments

Comments
 (0)