PCI: Enable unassigned resource reallocation on per-bus basis
authorYinghai Lu <yinghai@kernel.org>
Mon, 22 Jul 2013 21:37:15 +0000 (14:37 -0700)
committerBjorn Helgaas <bhelgaas@google.com>
Thu, 25 Jul 2013 18:35:03 +0000 (12:35 -0600)
commit967260cdb13f9c0de3cf56e305b34eb363e41d5b
tree7d977adb45121e6e10e9c412c0e8bb4ee424fdbc
parentfa216bf4dbe35e15044b90e7b51509768bab3d9a
PCI: Enable unassigned resource reallocation on per-bus basis

pci_realloc_detect() turns on automatic resource allocation when it finds
unassigned SR-IOV resources.  Previously it did this on a global basis, so
we enabled reallocation if any PCI device anywhere had an unassigned SR-IOV
resource.

This patch changes pci_realloc_detect() so it looks at a single bus, so we
can do this when a host bridge is hot-added.

[bhelgaas: changelog]
Signed-off-by: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
drivers/pci/setup-bus.c