Daniel Verkamp has uploaded this change for review.

View Change

pcidev.c: populate IDs with pci_fill_info()

With pciutils 3.7.0, flashrom is unable to match any PCI devices by
vendor/device ID because the vendor_id and device_id fields of struct
pci_dev are not filled in.

Call pci_fill_info() to request these identifiers before trying to match
them against the supported device list.

With this change, reading/writing a nicintel_spi boot ROM is successful.

Signed-off-by: Daniel Verkamp <dverkamp@chromium.org>
Change-Id: Ia011d4d801f8a54160e45a70b14b740e6dcc00ef
---
M pcidev.c
1 file changed, 1 insertion(+), 0 deletions(-)

git pull ssh://review.coreboot.org:29418/flashrom refs/changes/10/46310/1
diff --git a/pcidev.c b/pcidev.c
index e13b78c..892f7b1 100644
--- a/pcidev.c
+++ b/pcidev.c
@@ -206,6 +206,7 @@

for (dev = pacc->devices; dev; dev = dev->next) {
if (pci_filter_match(&filter, dev)) {
+ pci_fill_info(dev, PCI_FILL_IDENT);
/* Check against list of supported devices. */
for (i = 0; devs[i].device_name != NULL; i++)
if ((dev->vendor_id == devs[i].vendor_id) &&

To view, visit change 46310. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Ia011d4d801f8a54160e45a70b14b740e6dcc00ef
Gerrit-Change-Number: 46310
Gerrit-PatchSet: 1
Gerrit-Owner: Daniel Verkamp <dverkamp@chromium.org>
Gerrit-MessageType: newchange