mirror of
https://review.coreboot.org/flashrom.git
synced 2025-07-01 14:11:15 +02:00
Refine version check of libpci function pci_get_dev
The way more elegant check for the header fails unfortunately on CentOS 4.9 because PCI_LIB_VERSION is not defined at all although the domain parameter is present. This patch jumps through the hoops via an additional check in the Makefile to determine if the function accepts 5 parameters (new version) or not (old version). Corresponding to flashrom svn r1880. Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
This commit is contained in:
@ -1047,7 +1047,7 @@ static int nvidia_mcp_gpio_set(int gpio, int raise)
|
||||
return -1;
|
||||
}
|
||||
|
||||
#if PCI_LIB_VERSION >= 0x020200
|
||||
#if !defined(OLD_PCI_GET_DEV)
|
||||
dev = pci_get_dev(pacc, dev->domain, dev->bus, dev->dev, 1);
|
||||
#else
|
||||
/* pciutils/libpci before version 2.2 is too old to support
|
||||
|
Reference in New Issue
Block a user