mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-04-20 10:44:32 +10:00
device_probe.py: Fix missing pci check
This commit is contained in:
@@ -52,10 +52,11 @@ class PCIDevice:
|
||||
if type(ioname) is bytes:
|
||||
ioname = ioname.strip(b"\0").decode()
|
||||
|
||||
vendor_id_unspoofed, device_id_unspoofed = (int(i, 16) for i in ioname[3:].split(","))
|
||||
if anti_spoof:
|
||||
vendor_id = vendor_id_unspoofed
|
||||
device_id = device_id_unspoofed
|
||||
if ioname.startswith("pci"):
|
||||
vendor_id_unspoofed, device_id_unspoofed = (int(i, 16) for i in ioname[3:].split(","))
|
||||
if anti_spoof:
|
||||
vendor_id = vendor_id_unspoofed
|
||||
device_id = device_id_unspoofed
|
||||
|
||||
if vendor_id is None and device_id is None:
|
||||
vendor_id, device_id = [int.from_bytes(properties[i][:4], byteorder="little") for i in ["vendor-id", "device-id"]]
|
||||
|
||||
Reference in New Issue
Block a user