diff options
author | Edward O'Callaghan <quasisec@google.com> | 2021-11-13 17:59:18 +1100 |
---|---|---|
committer | Edward O'Callaghan <quasisec@chromium.org> | 2022-03-22 05:53:36 +0000 |
commit | 1b1066e2d5db21167394e0d40dfe5a0d370c8852 (patch) | |
tree | 1b1e56e349609a5faaaa53cdb34a85a404eff89b /programmer.h | |
parent | 855b8983319f24835e72669469669f270fffa1db (diff) | |
download | flashrom-1b1066e2d5db21167394e0d40dfe5a0d370c8852.tar.gz flashrom-1b1066e2d5db21167394e0d40dfe5a0d370c8852.tar.bz2 flashrom-1b1066e2d5db21167394e0d40dfe5a0d370c8852.zip |
pcidev: Move pci_dev_find() from internal to canonical place
Also rename to `pcidev_find()` in fitting with pcidev.c helpers.
BUG=b:220950271
TEST=```sudo ./flashrom -p internal -r /tmp/bios
<snip>
Found Programmer flash chip "Opaque flash chip" (16384 kB, Programmer-specific) mapped at physical address 0x0000000000000000.
Reading flash... done.
```
Change-Id: Ie21f87699481a84398ca4450b3f03548f0528191
Signed-off-by: Edward O'Callaghan <quasisec@google.com>
Reviewed-on: https://review.coreboot.org/c/flashrom/+/59280
Reviewed-by: Thomas Heijligen <src@posteo.de>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'programmer.h')
-rw-r--r-- | programmer.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/programmer.h b/programmer.h index 50753cf44..c79422c54 100644 --- a/programmer.h +++ b/programmer.h @@ -129,6 +129,7 @@ struct pci_dev *pcidev_scandev(struct pci_filter *filter, struct pci_dev *start) struct pci_dev *pcidev_getdevfn(struct pci_dev *dev, const int func); struct pci_dev *pcidev_find_vendorclass(uint16_t vendor, uint16_t devclass); struct pci_dev *pcidev_card_find(uint16_t vendor, uint16_t device, uint16_t card_vendor, uint16_t card_device); +struct pci_dev *pcidev_find(uint16_t vendor, uint16_t device); /* rpci_write_* are reversible writes. The original PCI config space register * contents will be restored on shutdown. * To clone the pci_dev instances internally, the `pacc` global @@ -261,9 +262,7 @@ extern int superio_count; #define SUPERIO_VENDOR_ITE 0x1 #define SUPERIO_VENDOR_WINBOND 0x2 #endif -#if NEED_PCI == 1 -struct pci_dev *pci_dev_find(uint16_t vendor, uint16_t device); -#endif + #if CONFIG_INTERNAL == 1 extern int is_laptop; extern int laptop_ok; |