commit | fae28a33083602a25f5b3ad6fdbd5f490d548277 | [log] [tgz] |
---|---|---|
author | Michal Suchanek <msuchanek@suse.de> | Wed Oct 12 21:57:52 2022 +0200 |
committer | Simon Glass <sjg@chromium.org> | Mon Oct 17 21:17:12 2022 -0600 |
tree | bb03c9227817fe28a6add97967a43478994cc4cf | |
parent | 44322b5b724b7d84c5b1d5a4241c0fe15be86d2d [diff] |
dm: pci: Fix device PCI iteration When there is no PCI bus uclass_first_device will return no bus and no error which will result in pci_find_first_device calling skip_to_next_device with no bus, and the bus is only checked at the end of the while cycle, not the beginning. Fixes: 76c3fbcd3d ("dm: pci: Add a way to iterate through all PCI devices") Signed-off-by: Michal Suchanek <msuchanek@suse.de> Reviewed-by: Simon Glass <sjg@chromium.org>