]> mj.ucw.cz Git - pciutils.git/commit
Simplified pci_fill_info() and friends fill-info
authorMartin Mares <mj@ucw.cz>
Fri, 21 Jan 2022 20:39:18 +0000 (21:39 +0100)
committerMartin Mares <mj@ucw.cz>
Fri, 21 Jan 2022 20:39:18 +0000 (21:39 +0100)
commit8e9299e4dde0bb73f2d571dc6e3b522f88d5765d
tree8682c2c608344ed5c5a8f1d521fbab7d85bca4bb
parentcdc56c65abb83b9e03a2de70fafa3e08fbce788e
Simplified pci_fill_info() and friends

Previously, we kept track of which fields were already filled, which
was quite brittle.

Now we keep only the set of already known fields in struct pci_dev.
We check if the current field is needed against this information.

Not only this simplifies the whole thing, but it also enables future
back-ends to call pci_fill_info() recursively as needed.
lib/access.c
lib/caps.c
lib/fbsd-device.c
lib/generic.c
lib/hurd.c
lib/internal.h
lib/sysfs.c