Skip to content

Commit d798d5b

Browse files
Merge pull request #527 from GameTechDev/fix/sus-pwr-caps
check the enabled field for sustained power limit
2 parents 877f249 + 1de07d8 commit d798d5b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

IntelPresentMon/ControlLib/IntelPowerTelemetryAdapter.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,9 @@ namespace pwr::intel
232232
};
233233
if (const auto result = ctlPowerGetLimits(powerDomains[0], &limits);
234234
result == CTL_RESULT_SUCCESS) {
235-
gpu_sustained_power_limit_mw = (double)limits.sustainedPowerLimit.power;
235+
if (limits.sustainedPowerLimit.enabled) {
236+
gpu_sustained_power_limit_mw = (double)limits.sustainedPowerLimit.power;
237+
}
236238
pmlog_verb(v::tele_gpu)(std::format("ctlPowerGetLimits output")).pmwatch(GetName())
237239
.pmwatch(ref::DumpGenerated(limits));
238240
}

0 commit comments

Comments
 (0)