GPU (Linux): don't detect frequency for AMD cards

It's current frequency and may hang for some reason
This commit is contained in:
Carter Li
2024-07-08 08:52:15 +08:00
parent 8402dba0d9
commit 4d1c62947b
2 changed files with 1 additions and 6 deletions
+1 -1
View File
@@ -32,7 +32,7 @@ typedef struct FFGPUResult
FFstrbuf platformApi;
double temperature;
int32_t coreCount;
double frequency; // Real time clock frequency in GHz
double frequency; // Maximum time clock frequency in GHz
FFGPUMemory dedicated;
FFGPUMemory shared;
uint64_t deviceId; // Used internally, may be uninitialized
-5
View File
@@ -92,11 +92,6 @@ static void pciDetectAmdSpecific(const FFGPUOptions* options, FFGPUResult* gpu,
gpu->temperature = (double) value / 1000;
}
ffStrbufSubstrBefore(pciDir, hwmonLen);
ffStrbufAppendS(pciDir, "freq1_input"); // The gfx/compute clock in hertz
if (ffReadFileBuffer(pciDir->chars, buffer) && (value = ffStrbufToUInt(buffer, 0)))
gpu->frequency = (double) value / (1000 * 1000 * 1000);
if (options->driverSpecific)
{
ffStrbufSubstrBefore(pciDir, pciDirLen);