PCI: Avoid potential out-of-bounds read in pci_dev_for_each_resource()