Skip to content

Commit

Permalink
PCI: qcom: Fix pp->dev usage before assignment
Browse files Browse the repository at this point in the history
Initialize pp->dev in qcom_pcie_probe() before calling get_resources(),
which uses it.

[bhelgaas: changelog]
Fixes: e6a087e ("PCI: qcom: Remove redundant struct qcom_pcie.dev")
Signed-off-by: Srinivas Kandagatla <[email protected]>
Signed-off-by: Bjorn Helgaas <[email protected]>
  • Loading branch information
Srinivas-Kandagatla authored and bjorn-helgaas committed Oct 26, 2016
1 parent 02a1b8f commit ad11044
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/pci/host/pcie-qcom.c
Original file line number Diff line number Diff line change
Expand Up @@ -533,11 +533,11 @@ static int qcom_pcie_probe(struct platform_device *pdev)
if (IS_ERR(pcie->phy))
return PTR_ERR(pcie->phy);

pp->dev = dev;
ret = pcie->ops->get_resources(pcie);
if (ret)
return ret;

pp->dev = dev;
pp->root_bus_nr = -1;
pp->ops = &qcom_pcie_dw_ops;

Expand Down

0 comments on commit ad11044

Please sign in to comment.