]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
PCI: Factor DT-specific pci_bus_find_domain_nr() code out
authorTomasz Nowicki <tn@semihalf.com>
Fri, 10 Jun 2016 19:55:15 +0000 (21:55 +0200)
committerBjorn Helgaas <bhelgaas@google.com>
Fri, 10 Jun 2016 23:28:32 +0000 (18:28 -0500)
pci_bus_find_domain_nr() retrieves the host bridge domain number in a
DT-specific way.  Rename it to of_pci_bus_find_domain_nr() to reflect that,
so we can add a corresponding function for ACPI.

[bhelgaas: changelog]
Signed-off-by: Tomasz Nowicki <tn@semihalf.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
drivers/pci/pci.c

index b9a783385eaec0d85f40d57167227e344fc723dc..97f7cd4a7e86ce703c122695115818660237d22b 100644 (file)
@@ -4941,7 +4941,7 @@ int pci_get_new_domain_nr(void)
 }
 
 #ifdef CONFIG_PCI_DOMAINS_GENERIC
-int pci_bus_find_domain_nr(struct pci_bus *bus, struct device *parent)
+static int of_pci_bus_find_domain_nr(struct device *parent)
 {
        static int use_dt_domains = -1;
        int domain = -1;
@@ -4987,6 +4987,11 @@ int pci_bus_find_domain_nr(struct pci_bus *bus, struct device *parent)
 
        return domain;
 }
+
+int pci_bus_find_domain_nr(struct pci_bus *bus, struct device *parent)
+{
+       return of_pci_bus_find_domain_nr(parent);
+}
 #endif
 #endif