From: Martin Mares Date: Sun, 31 Dec 2017 17:24:15 +0000 (+0100) Subject: fbsd-device: Hopefully fixed a bug in fbsd_scan() X-Git-Tag: v3.6.0~27 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=58d9f25f25c0070c3c3df3073f375d87a9163e88;p=pciutils.git fbsd-device: Hopefully fixed a bug in fbsd_scan() The previous version was obviously wrong: as Andriy Gapon pointed out, we assign twice to t->dev, but never to t->func. Not tested, though, as I have no FreeBSD system at hand. --- diff --git a/lib/fbsd-device.c b/lib/fbsd-device.c index 78067dc..62a335a 100644 --- a/lib/fbsd-device.c +++ b/lib/fbsd-device.c @@ -143,7 +143,7 @@ fbsd_scan(struct pci_access *a) t = pci_alloc_dev(a); t->bus = matches[i].pc_sel.pc_bus; t->dev = matches[i].pc_sel.pc_dev; - t->dev = matches[i].pc_sel.pc_dev; + t->func = matches[i].pc_sel.pc_func; t->domain = matches[i].pc_sel.pc_domain; t->domain_16 = matches[i].pc_sel.pc_domain; t->vendor_id = matches[i].pc_vendor;