mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 10:58:48 +09:00
Revert "PCI: Use preserve_config in place of pci_flags"
This reverts commit f858b0fab2 which is
commit 7246a4520b4bf1494d7d030166a11b5226f6d508 upstream.
This patch causes a regression in cuttlefish/crossvm boot on arm64.
The patch was part of a series that when applied will not cause a regression
but this patch was backported to the 6.1 branch by itself.
The other patches do not apply cleanly to the 6.1 branch.
Signed-off-by: Terry Tritton <terry.tritton@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
6603aca936
commit
479a42eedb
@@ -73,6 +73,10 @@ int pci_host_common_probe(struct platform_device *pdev)
|
|||||||
if (IS_ERR(cfg))
|
if (IS_ERR(cfg))
|
||||||
return PTR_ERR(cfg);
|
return PTR_ERR(cfg);
|
||||||
|
|
||||||
|
/* Do not reassign resources if probe only */
|
||||||
|
if (!pci_has_flag(PCI_PROBE_ONLY))
|
||||||
|
pci_add_flags(PCI_REASSIGN_ALL_BUS);
|
||||||
|
|
||||||
bridge->sysdata = cfg;
|
bridge->sysdata = cfg;
|
||||||
bridge->ops = (struct pci_ops *)&ops->pci_ops;
|
bridge->ops = (struct pci_ops *)&ops->pci_ops;
|
||||||
bridge->msi_domain = true;
|
bridge->msi_domain = true;
|
||||||
|
|||||||
@@ -3082,18 +3082,20 @@ int pci_host_probe(struct pci_host_bridge *bridge)
|
|||||||
|
|
||||||
bus = bridge->bus;
|
bus = bridge->bus;
|
||||||
|
|
||||||
/* If we must preserve the resource configuration, claim now */
|
|
||||||
if (bridge->preserve_config)
|
|
||||||
pci_bus_claim_resources(bus);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Assign whatever was left unassigned. If we didn't claim above,
|
* We insert PCI resources into the iomem_resource and
|
||||||
* this will reassign everything.
|
* ioport_resource trees in either pci_bus_claim_resources()
|
||||||
|
* or pci_bus_assign_resources().
|
||||||
*/
|
*/
|
||||||
pci_assign_unassigned_root_bus_resources(bus);
|
if (pci_has_flag(PCI_PROBE_ONLY)) {
|
||||||
|
pci_bus_claim_resources(bus);
|
||||||
|
} else {
|
||||||
|
pci_bus_size_bridges(bus);
|
||||||
|
pci_bus_assign_resources(bus);
|
||||||
|
|
||||||
list_for_each_entry(child, &bus->children, node)
|
list_for_each_entry(child, &bus->children, node)
|
||||||
pcie_bus_configure_settings(child);
|
pcie_bus_configure_settings(child);
|
||||||
|
}
|
||||||
|
|
||||||
pci_bus_add_devices(bus);
|
pci_bus_add_devices(bus);
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user