aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/hotplug/acpi_pcihp.c
diff options
context:
space:
mode:
authorMika Westerberg <mika.westerberg@linux.intel.com>2018-05-31 11:42:11 -0500
committerBjorn Helgaas <bhelgaas@google.com>2018-06-04 12:08:06 -0500
commit90cc0c3cc7092ea4c7871fdd5fb00a9ba62842e3 (patch)
tree8593d15501ff0b65aadbe7840e9ce3d600469508 /drivers/pci/hotplug/acpi_pcihp.c
parentPCI: shpchp: Fix AMD POGO identification (diff)
downloadlinux-dev-90cc0c3cc7092ea4c7871fdd5fb00a9ba62842e3.tar.xz
linux-dev-90cc0c3cc7092ea4c7871fdd5fb00a9ba62842e3.zip
PCI: shpchp: Add shpchp_is_native()
In the same way we do for pciehp, add shpchp_is_native(), which returns true if the bridge should be handled by the native SHPC driver. Then convert the driver to use this function. Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers/pci/hotplug/acpi_pcihp.c')
-rw-r--r--drivers/pci/hotplug/acpi_pcihp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/pci/hotplug/acpi_pcihp.c b/drivers/pci/hotplug/acpi_pcihp.c
index 597d22aeefc1..3979f89b250a 100644
--- a/drivers/pci/hotplug/acpi_pcihp.c
+++ b/drivers/pci/hotplug/acpi_pcihp.c
@@ -83,11 +83,11 @@ int acpi_get_hp_hw_control_from_firmware(struct pci_dev *pdev)
* OSHP within the scope of the hotplug controller and its parents,
* up to the host bridge under which this controller exists.
*/
- host = pci_find_host_bridge(pdev->bus);
- if (host->native_shpc_hotplug)
+ if (shpchp_is_native(pdev))
return 0;
/* If _OSC exists, we should not evaluate OSHP */
+ host = pci_find_host_bridge(pdev->bus);
root = acpi_pci_find_root(ACPI_HANDLE(&host->dev));
if (root->osc_support_set)
goto no_control;