diff options
author | Hauke Mehrtens <hauke@hauke-m.de> | 2015-05-24 22:37:02 +0200 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2015-05-28 01:27:54 +0200 |
commit | 18c4342aa56d70176eea85021e6fe8f6f8f39c7b (patch) | |
tree | bbd138c03d8ca533fee4362b0325eb79340a92da /drivers/pci/host/pcie-iproc-platform.c | |
parent | PCI: iproc: Add BCMA PCIe driver (diff) | |
download | linux-18c4342aa56d70176eea85021e6fe8f6f8f39c7b.tar.xz linux-18c4342aa56d70176eea85021e6fe8f6f8f39c7b.zip |
PCI: iproc: Directly add PCI resources
The struct iproc_pcie.resources member was pointing to a stack variable and
is invalid after the registration function returned.
Remove this pointer and add a parameter to the function.
Tested-by: Ray Jui <rjui@broadcom.com>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Ray Jui <rjui@broadcom.com>
Diffstat (limited to 'drivers/pci/host/pcie-iproc-platform.c')
-rw-r--r-- | drivers/pci/host/pcie-iproc-platform.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/pci/host/pcie-iproc-platform.c b/drivers/pci/host/pcie-iproc-platform.c index c8aa06f10d73..c5fe4c160972 100644 --- a/drivers/pci/host/pcie-iproc-platform.c +++ b/drivers/pci/host/pcie-iproc-platform.c @@ -69,11 +69,9 @@ static int iproc_pcie_pltfm_probe(struct platform_device *pdev) return ret; } - pcie->resources = &res; - pcie->map_irq = of_irq_parse_and_map_pci; - ret = iproc_pcie_setup(pcie); + ret = iproc_pcie_setup(pcie, &res); if (ret) { dev_err(pcie->dev, "PCIe controller setup failed\n"); return ret; |