mirror of
https://review.coreboot.org/flashrom.git
synced 2025-04-29 16:03:47 +02:00
Add support for pciutils/libpci older than 2.2
Needed on the original Xbox running Xebian and a few other ancient systems. Corresponding to flashrom svn r1088. Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> Acked-by: Alec Wright <alecjw@member.fsf.org>
This commit is contained in:
parent
b51e58e50f
commit
44cd9ab080
@ -785,7 +785,15 @@ static int nvidia_mcp_gpio_set(int gpio, int raise)
|
||||
return -1;
|
||||
}
|
||||
|
||||
#if PCI_LIB_VERSION >= 0x020200
|
||||
dev = pci_get_dev(pacc, dev->domain, dev->bus, dev->dev, 1);
|
||||
#else
|
||||
/* pciutils/libpci before version 2.2 is too old to support
|
||||
* PCI domains. Such old machines usually don't have domains
|
||||
* besides domain 0, so this is not a problem.
|
||||
*/
|
||||
dev = pci_get_dev(pacc, dev->bus, dev->dev, 1);
|
||||
#endif
|
||||
if (!dev) {
|
||||
msg_perr("MCP SMBus controller could not be found\n");
|
||||
return -1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user