mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-06 09:16:41 +07:00
PCI: dra7xx: Set drvdata at end of probe function
Set the drvdata pointer at the end of probe function for consistency with other drivers. We don't need the drvdata until after the probe completes, and we don't need it at all if the probe fails. No functional change intended. Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
This commit is contained in:
parent
01856d1de4
commit
03fa2ae184
@ -418,12 +418,11 @@ static int __init dra7xx_pcie_probe(struct platform_device *pdev)
|
|||||||
reg &= ~LTSSM_EN;
|
reg &= ~LTSSM_EN;
|
||||||
dra7xx_pcie_writel(dra7xx, PCIECTRL_DRA7XX_CONF_DEVICE_CMD, reg);
|
dra7xx_pcie_writel(dra7xx, PCIECTRL_DRA7XX_CONF_DEVICE_CMD, reg);
|
||||||
|
|
||||||
platform_set_drvdata(pdev, dra7xx);
|
|
||||||
|
|
||||||
ret = dra7xx_add_pcie_port(dra7xx, pdev);
|
ret = dra7xx_add_pcie_port(dra7xx, pdev);
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
goto err_gpio;
|
goto err_gpio;
|
||||||
|
|
||||||
|
platform_set_drvdata(pdev, dra7xx);
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
err_gpio:
|
err_gpio:
|
||||||
|
Loading…
Reference in New Issue
Block a user