[PATCH 5/8] ACPI, PCI: PCI MSI _OSC support capabilities called when root bridge added

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



ACPI, PCI: PCI MSI _OSC support capabilities called when root bridge added

The _OSC capabilityy OSC_MSI_SUPPORT is set when the root
bridge is added with pci_acpi_osc_support(), so we no longer
need to do it in the PCI MSI driver.
---

 drivers/acpi/pci_root.c |    3 +++
 drivers/pci/msi.c       |   21 ---------------------
 drivers/pci/pci.c       |    2 --
 drivers/pci/pci.h       |    2 --
 4 files changed, 3 insertions(+), 25 deletions(-)


diff --git a/drivers/acpi/pci_root.c b/drivers/acpi/pci_root.c
index 4d60629..75a59ea 100644
--- a/drivers/acpi/pci_root.c
+++ b/drivers/acpi/pci_root.c
@@ -214,6 +214,9 @@ static int __devinit acpi_pci_root_add(struct acpi_device *device)
 	pci_acpi_osc_support(device->handle,
 			     OSC_EXT_PCI_CONFIG_SUPPORT |
 			     OSC_PCI_SEGMENT_GROUPS_SUPPORT |
+#ifdef CONFIG_PCI_MSI
+			     OSC_MSI_SUPPORT |
+#endif
 #ifdef CONFIG_PCIEASPM
 			     OSC_ACTIVE_STATE_PWR_SUPPORT |
 			     OSC_CLOCK_PWR_CAPABILITY_SUPPORT |
diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c
index 74801f7..d281201 100644
--- a/drivers/pci/msi.c
+++ b/drivers/pci/msi.c
@@ -759,24 +759,3 @@ void pci_msi_init_pci_dev(struct pci_dev *dev)
 {
 	INIT_LIST_HEAD(&dev->msi_list);
 }
-
-#ifdef CONFIG_ACPI
-#include <linux/acpi.h>
-#include <linux/pci-acpi.h>
-static void __devinit msi_acpi_init(void)
-{
-	if (acpi_pci_disabled)
-		return;
-	pci_osc_support_set(OSC_MSI_SUPPORT);
-	pcie_osc_support_set(OSC_MSI_SUPPORT);
-}
-#else
-static inline void msi_acpi_init(void) { }
-#endif /* CONFIG_ACPI */
-
-void __devinit msi_init(void)
-{
-	if (!pci_msi_enable)
-		return;
-	msi_acpi_init();
-}
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
index 533aeb5..d77e477 100644
--- a/drivers/pci/pci.c
+++ b/drivers/pci/pci.c
@@ -2032,8 +2032,6 @@ static int __devinit pci_init(void)
 		pci_fixup_device(pci_fixup_final, dev);
 	}
 
-	msi_init();
-
 	return 0;
 }
 
diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h
index 9de87e9..b205ab8 100644
--- a/drivers/pci/pci.h
+++ b/drivers/pci/pci.h
@@ -98,11 +98,9 @@ extern unsigned int pci_pm_d3_delay;
 #ifdef CONFIG_PCI_MSI
 void pci_no_msi(void);
 extern void pci_msi_init_pci_dev(struct pci_dev *dev);
-extern void __devinit msi_init(void);
 #else
 static inline void pci_no_msi(void) { }
 static inline void pci_msi_init_pci_dev(struct pci_dev *dev) { }
-static inline void msi_init(void) { }
 #endif
 
 #ifdef CONFIG_PCIEAER

--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux