]> mj.ucw.cz Git - pciutils.git/commitdiff
Fixed a bug in name lookups
authorMartin Mares <mj@ucw.cz>
Sat, 26 Nov 2005 11:53:38 +0000 (11:53 +0000)
committerMartin Mares <mj@ucw.cz>
Fri, 5 May 2006 12:18:33 +0000 (14:18 +0200)
git-archimport-id: mj@ucw.cz--public/pciutils--main--2.2--patch-88

ChangeLog
lspci.c

index d55bf27ce8ac6e37a0c6adadabb6bb33054d3129..c2ae0645530c3eee503b1320c380a3923cd8cba8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2005-11-26  Martin Mares  <mj@ucw.cz>
+
+       * lspci.c (show_machine): Subsystem vendors were printed incorrectly
+       in machine-readable modes. Thanks to Pavel Celeda for a bug report.
+
 2005-10-11  Martin Mares  <mj@ucw.cz>
 
        * lspci.c (new_bus): Fixed a memory leak. Thanks to Paul Sangree for reporting it.
diff --git a/lspci.c b/lspci.c
index 20408a94168e26c04d9644cd7b57e6cf6315de4d..5a9251e800a5086f543d1442cd13c1fb395f045c 100644 (file)
--- a/lspci.c
+++ b/lspci.c
@@ -1791,7 +1791,7 @@ show_machine(struct device *d)
       if (sv_id && sv_id != 0xffff)
        {
          printf("SVendor:\t%s\n",
-                pci_lookup_name(pacc, svbuf, sizeof(svbuf), PCI_LOOKUP_SUBSYSTEM | PCI_LOOKUP_VENDOR, p->vendor_id, p->device_id, sv_id, sd_id));
+                pci_lookup_name(pacc, svbuf, sizeof(svbuf), PCI_LOOKUP_SUBSYSTEM | PCI_LOOKUP_VENDOR, sv_id));
          printf("SDevice:\t%s\n",
                 pci_lookup_name(pacc, sdbuf, sizeof(sdbuf), PCI_LOOKUP_SUBSYSTEM | PCI_LOOKUP_DEVICE, p->vendor_id, p->device_id, sv_id, sd_id));
        }
@@ -1816,7 +1816,7 @@ show_machine(struct device *d)
        printf(" -p%02x", c);
       if (sv_id && sv_id != 0xffff)
        printf(" \"%s\" \"%s\"",
-              pci_lookup_name(pacc, svbuf, sizeof(svbuf), PCI_LOOKUP_SUBSYSTEM | PCI_LOOKUP_VENDOR, p->vendor_id, p->device_id, sv_id, sd_id),
+              pci_lookup_name(pacc, svbuf, sizeof(svbuf), PCI_LOOKUP_SUBSYSTEM | PCI_LOOKUP_VENDOR, sv_id),
               pci_lookup_name(pacc, sdbuf, sizeof(sdbuf), PCI_LOOKUP_SUBSYSTEM | PCI_LOOKUP_DEVICE, p->vendor_id, p->device_id, sv_id, sd_id));
       else
        printf(" \"\" \"\"");