summaryrefslogtreecommitdiffstats
path: root/drivers/pci/host/pcie-designware.c
diff options
context:
space:
mode:
authorMinghuan Lian <Minghuan.Lian@freescale.com>2014-09-23 22:28:59 +0800
committerBjorn Helgaas <bhelgaas@google.com>2014-09-24 07:07:43 -0600
commit24832b4de315ad00e5430a53772750dfcf18514d (patch)
tree8942ed7d5e96510db2d8e7bcd69e1de73ebc6d96 /drivers/pci/host/pcie-designware.c
parent450e344e421b9f555261a2d97952d9e71d4cb082 (diff)
downloadop-kernel-dev-24832b4de315ad00e5430a53772750dfcf18514d.zip
op-kernel-dev-24832b4de315ad00e5430a53772750dfcf18514d.tar.gz
PCI: designware: Add get_msi_data() to pcie_host_ops
Add a struct pcie_host_ops .get_msi_data() method for platforms to return their special MSI message data. Signed-off-by: Minghuan Lian <Minghuan.Lian@freescale.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Acked-by: Mohit KUMAR <mohit.kumar@st.com>
Diffstat (limited to 'drivers/pci/host/pcie-designware.c')
-rw-r--r--drivers/pci/host/pcie-designware.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/pci/host/pcie-designware.c b/drivers/pci/host/pcie-designware.c
index 5666587..34e7366 100644
--- a/drivers/pci/host/pcie-designware.c
+++ b/drivers/pci/host/pcie-designware.c
@@ -366,7 +366,12 @@ static int dw_msi_setup_irq(struct msi_chip *chip, struct pci_dev *pdev,
else
msg.address_lo = virt_to_phys((void *)pp->msi_data);
msg.address_hi = 0x0;
- msg.data = pos;
+
+ if (pp->ops->get_msi_data)
+ msg.data = pp->ops->get_msi_data(pp, pos);
+ else
+ msg.data = pos;
+
write_msi_msg(irq, &msg);
return 0;
OpenPOWER on IntegriCloud