diff options
author | Bin Meng | 2018-08-03 01:14:37 -0700 |
---|---|---|
committer | Simon Glass | 2018-08-08 12:49:31 +0100 |
commit | 64e45f73bd0aa9d8a1069587540bc91fe45b62e0 (patch) | |
tree | e9b7ee1f7d291255ec57a77cf03a9f635df158a5 /drivers/pci | |
parent | 1f6b08b969b345a83b63f481e50555536d89854f (diff) |
dm: pci: Fix scanning multi-function device
The flag to control whether to scan multi-function device during
enumeration should be cleared at the beginning of each iteration
if the device's function number equals to zero.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers/pci')
-rw-r--r-- | drivers/pci/pci-uclass.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/pci/pci-uclass.c b/drivers/pci/pci-uclass.c index b2909a325ac..28ea8c5d4ee 100644 --- a/drivers/pci/pci-uclass.c +++ b/drivers/pci/pci-uclass.c @@ -745,6 +745,8 @@ int pci_bind_bus_devices(struct udevice *bus) struct udevice *dev; ulong class; + if (!PCI_FUNC(bdf)) + found_multi = false; if (PCI_FUNC(bdf) && !found_multi) continue; /* Check only the first access, we don't expect problems */ |