From b3435a8586ebe9672ec3937f47823f9d9100692b Mon Sep 17 00:00:00 2001 From: Benjamin Herrenschmidt Date: Fri, 25 Jun 2021 14:04:41 +1000 Subject: [PATCH] Revert "arm64: acpi/pci: invoke _DSM whether to preserve firmware PCI setup" This reverts commit 0a74aec308fde802539a18ce6e3348459c310145. --- arch/arm64/kernel/pci.c | 20 ++------------------ include/linux/pci-acpi.h | 7 +++---- 2 files changed, 5 insertions(+), 22 deletions(-) diff --git a/arch/arm64/kernel/pci.c b/arch/arm64/kernel/pci.c index 4c180c317465f..0e2ea1c785427 100644 --- a/arch/arm64/kernel/pci.c +++ b/arch/arm64/kernel/pci.c @@ -169,7 +169,6 @@ struct pci_bus *pci_acpi_scan_root(struct acpi_pci_root *root) struct acpi_pci_generic_root_info *ri; struct pci_bus *bus, *child; struct acpi_pci_root_ops *root_ops; - union acpi_object *obj; ri = kzalloc_node(sizeof(*ri), GFP_KERNEL, node); if (!ri) @@ -195,23 +194,8 @@ struct pci_bus *pci_acpi_scan_root(struct acpi_pci_root *root) if (!bus) return NULL; - /* - * Invoke the PCI device specific method (_DSM) #5 'Ignore PCI Boot - * Configuration', which tells us whether the firmware wants us to - * preserve the configuration of the PCI resource tree for this root - * bridge. - */ - obj = acpi_evaluate_dsm(ACPI_HANDLE(bus->bridge), &pci_acpi_dsm_guid, 1, - IGNORE_PCI_BOOT_CONFIG_DSM, NULL); - if (obj && obj->type == ACPI_TYPE_INTEGER && obj->integer.value == 0) { - /* preserve existing resource assignment */ - pci_bus_claim_resources(bus); - } else { - /* reconfigure the resource tree from scratch */ - pci_bus_size_bridges(bus); - pci_bus_assign_resources(bus); - } - ACPI_FREE(obj); + pci_bus_size_bridges(bus); + pci_bus_assign_resources(bus); list_for_each_entry(child, &bus->children, node) pcie_bus_configure_settings(child); diff --git a/include/linux/pci-acpi.h b/include/linux/pci-acpi.h index 62b7fdcc661c3..8082b612f5612 100644 --- a/include/linux/pci-acpi.h +++ b/include/linux/pci-acpi.h @@ -107,10 +107,9 @@ static inline void acpiphp_check_host_bridge(struct acpi_device *adev) { } #endif extern const guid_t pci_acpi_dsm_guid; -#define IGNORE_PCI_BOOT_CONFIG_DSM 0x05 -#define DEVICE_LABEL_DSM 0x07 -#define RESET_DELAY_DSM 0x08 -#define FUNCTION_DELAY_DSM 0x09 +#define DEVICE_LABEL_DSM 0x07 +#define RESET_DELAY_DSM 0x08 +#define FUNCTION_DELAY_DSM 0x09 #else /* CONFIG_ACPI */ static inline void acpi_pci_add_bus(struct pci_bus *bus) { }