File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -373,7 +373,12 @@ func isOrinGPUID(id device.Identifier) bool {
373373}
374374
375375// isIntegratedGPU checks whether the specified device is an integrated GPU.
376- // As a proxy we check the PCI Bus if for thes
376+ // The following heuristic is followed:
377+ // - If the device does not support getting PCI bus information, we fall back to
378+ // checking the device name and consider Orin and Thor devices iGPUs.
379+ // - If the device does support PCI bus information, we check for a specific
380+ // bus ID that is associated with Thor devices.
381+ //
377382// TODO: This should be replaced by an explicit NVML call once available.
378383func isIntegratedGPU (d nvml.Device ) (bool , error ) {
379384 pciInfo , ret := d .GetPciInfo ()
@@ -387,7 +392,11 @@ func isIntegratedGPU(d nvml.Device) (bool, error) {
387392 if ret != nvml .SUCCESS {
388393 return false , fmt .Errorf ("failed to get PCI info: %v" , ret )
389394 }
390-
395+ // On Thor-based systems, the iGPU always has the PCI bus ID '0000:01:00.0'.
396+ // We explicitly handle this case.
397+ if pciInfo .Domain == 0 && pciInfo .Bus == 1 && pciInfo .Device == 0 {
398+ return true , nil
399+ }
391400 if pciInfo .Domain != 0 {
392401 return false , nil
393402 }
You can’t perform that action at this time.
0 commit comments