diff options
author | Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> | 2012-12-27 18:40:26 +0000 |
---|---|---|
committer | Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> | 2012-12-27 18:40:26 +0000 |
commit | 342bb7a0365d0faa8d451344900e4cfd91a63d09 (patch) | |
tree | be7adedc94b5c55dec0e7e1f1dae88ef4e127fad /pcidev.c | |
parent | f7d2c4171da6cffca280065adc06966b1b4dfe4e (diff) | |
download | flashrom-342bb7a0365d0faa8d451344900e4cfd91a63d09.zip flashrom-342bb7a0365d0faa8d451344900e4cfd91a63d09.tar.gz |
Refactor PCI and USB device status printing
To be able to get rid of lots of #ifdefs and centralize programmer-specific
data more...
- introduce two new fields to struct programmer_entry, namely
enum type (OTHER, USB, PCI) and union devs (pcidev_status, usbdev_status
or char *note).
- use those fields to generate device listings in print.c and print_wiki.c.
Bonus: add printing of USB devices to print_wiki.c and count supported PCI
and USB devices.
Corresponding to flashrom svn r1631.
Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Diffstat (limited to 'pcidev.c')
-rw-r--r-- | pcidev.c | 13 |
1 files changed, 0 insertions, 13 deletions
@@ -224,19 +224,6 @@ uintptr_t pcidev_init(int bar, const struct pcidev_status *devs) return curaddr; } -void print_supported_pcidevs(const struct pcidev_status *devs) -{ - int i; - - msg_pinfo("PCI devices:\n"); - for (i = 0; devs[i].vendor_name != NULL; i++) { - msg_pinfo("%s %s [%04x:%04x]%s\n", devs[i].vendor_name, - devs[i].device_name, devs[i].vendor_id, - devs[i].device_id, - (devs[i].status == NT) ? " (untested)" : ""); - } -} - enum pci_write_type { pci_write_type_byte, pci_write_type_word, |