mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-10-28 07:44:06 +01:00
GPU (MT): adds PCIe speed detection support
This commit is contained in:
@@ -190,6 +190,20 @@ const char* ffDetectMthreadsGpuInfo(const FFGpuDriverCondition* cond, FFGpuDrive
|
||||
}
|
||||
}
|
||||
|
||||
if (result.psCurr || result.psMax) {
|
||||
MtmlPciInfo pciInfo;
|
||||
if (mtmlData.ffmtmlDeviceGetPciInfo(device, &pciInfo) == MTML_SUCCESS) {
|
||||
if (result.psCurr) {
|
||||
result.psCurr->lanes = (uint16_t) pciInfo.pciCurWidth;
|
||||
result.psCurr->gen = (uint16_t) pciInfo.pciCurGen;
|
||||
}
|
||||
if (result.psMax) {
|
||||
result.psMax->lanes = (uint16_t) pciInfo.pciMaxWidth;
|
||||
result.psMax->gen = (uint16_t) pciInfo.pciMaxGen;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return NULL;
|
||||
|
||||
#else
|
||||
|
||||
Reference in New Issue
Block a user