summaryrefslogtreecommitdiffstats
path: root/drivers/pci/hotplug/pciehp_hpc.c
diff options
context:
space:
mode:
authorKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>2008-08-22 17:16:48 +0900
committerJesse Barnes <jbarnes@virtuousgeek.org>2008-10-20 10:53:47 -0700
commitf7a10e32a1a7ae240fa3925c5727d224eba3e31d (patch)
treeb10ee68a20f16ca6267eb1a7a004277bd50bce9b /drivers/pci/hotplug/pciehp_hpc.c
parentc01156061bdd5976397dfb173f8c70ae351a6cb6 (diff)
downloadkernel-crypto-f7a10e32a1a7ae240fa3925c5727d224eba3e31d.tar.gz
kernel-crypto-f7a10e32a1a7ae240fa3925c5727d224eba3e31d.tar.xz
kernel-crypto-f7a10e32a1a7ae240fa3925c5727d224eba3e31d.zip
PCI: pciehp: fix irq initialization
Current pciehp driver gets irq number from pci_dev->irq. But because pciehp driver is a pci express port service driver, it should get irq number from pcie_device->irq. Signed-off-by: Kenji Kaneshige <kaneshige.kenji@jp.fujitsu.com> Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Diffstat (limited to 'drivers/pci/hotplug/pciehp_hpc.c')
-rw-r--r--drivers/pci/hotplug/pciehp_hpc.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/pci/hotplug/pciehp_hpc.c b/drivers/pci/hotplug/pciehp_hpc.c
index 9d934ddee95..5a5c08f12af 100644
--- a/drivers/pci/hotplug/pciehp_hpc.c
+++ b/drivers/pci/hotplug/pciehp_hpc.c
@@ -223,7 +223,7 @@ static void start_int_poll_timer(struct controller *ctrl, int sec)
static inline int pciehp_request_irq(struct controller *ctrl)
{
- int retval, irq = ctrl->pci_dev->irq;
+ int retval, irq = ctrl->pcie->irq;
/* Install interrupt polling timer. Start with 10 sec delay */
if (pciehp_poll_mode) {
@@ -244,7 +244,7 @@ static inline void pciehp_free_irq(struct controller *ctrl)
if (pciehp_poll_mode)
del_timer_sync(&ctrl->poll_timer);
else
- free_irq(ctrl->pci_dev->irq, ctrl);
+ free_irq(ctrl->pcie->irq, ctrl);
}
static int pcie_poll_cmd(struct controller *ctrl)
@@ -1114,6 +1114,7 @@ struct controller *pcie_init(struct pcie_device *dev)
}
INIT_LIST_HEAD(&ctrl->slot_list);
+ ctrl->pcie = dev;
ctrl->pci_dev = pdev;
ctrl->cap_base = pci_find_capability(pdev, PCI_CAP_ID_EXP);
if (!ctrl->cap_base) {