Skip to content

Commit

Permalink
fix: Sleep after checking PM_STATUS_95
Browse files Browse the repository at this point in the history
  • Loading branch information
VisualEhrmanntraut committed Nov 11, 2024
1 parent 9a9b038 commit 07105dd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion SMCRadeonSensors/SMCRSCard.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -210,10 +210,10 @@ IOReturn SMCRSCard::smu7GetPowerPMStatus(float *data) {
this->writeIndirectSMC(ixSMU_PM_STATUS_95, 0);
UInt32 value = 0;
for (size_t i = 0; i < 10; i += 1) {
IOSleep(500);
this->smu7SendMessageToSMC(PPSMC_MSG_PmStatusLogSample_SMU7);
value = this->readIndirectSMC(ixSMU_PM_STATUS_95);
if (value != 0) { break; }
IOSleep(500);
}
if (value == 0) { return kIOReturnError; }
*data = fractional8BitToFloat(value);
Expand Down

0 comments on commit 07105dd

Please sign in to comment.