linux/drivers/pci/controller
Serge Semin 113fa857b7 PCI: dwc: Stop link on host_init errors and de-initialization
It's logically correct to undo everything that was done when an error is
discovered or in the corresponding cleanup counterpart. Otherwise the host
controller will be left in an undetermined state. Since the link is set up
in the host_init method, deactivate it there in the cleanup-on-error block
and stop the link in the antagonistic routine - dw_pcie_host_deinit(). Link
deactivation is platform-specific and should be implemented in
dw_pcie_ops.stop_link().

Fixes: 886a9c1347 ("PCI: dwc: Move link handling into common code")
Link: https://lore.kernel.org/r/20220624143428.8334-2-Sergey.Semin@baikalelectronics.ru
Tested-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: Serge Semin <Sergey.Semin@baikalelectronics.ru>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Reviewed-by: Rob Herring <robh@kernel.org>
2022-07-05 19:00:32 -05:00
..
cadence PCI: cadence: Clear FLR in device capabilities register 2022-05-12 22:19:40 +01:00
dwc PCI: dwc: Stop link on host_init errors and de-initialization 2022-07-05 19:00:32 -05:00
mobiveil PCI: Add defines for normal and subtractive PCI bridges 2022-02-17 15:29:35 -06:00
Kconfig PCI: mvebu: Add help string for CONFIG_PCI_MVEBU option 2022-02-03 10:52:22 +00:00
Makefile
pci-aardvark.c Revert "PCI: aardvark: Rewrite IRQ code to chained IRQ handler" 2022-05-16 15:58:47 -05:00
pci-ftpci100.c
pci-host-common.c
pci-host-generic.c
pci-hyperv-intf.c
pci-hyperv.c PCI: hv: Fix synchronization between channel callback and hv_pci_bus_exit() 2022-05-13 16:57:32 +00:00
pci-ixp4xx.c
pci-loongson.c PCI: Add defines for normal and subtractive PCI bridges 2022-02-17 15:29:35 -06:00
pci-mvebu.c PCI: mvebu: Add support for sending Set_Slot_Power_Limit message 2022-04-25 10:53:39 +01:00
pci-rcar-gen2.c
pci-tegra.c PCI: Add defines for normal and subtractive PCI bridges 2022-02-17 15:29:35 -06:00
pci-thunder-ecam.c
pci-thunder-pem.c
pci-v3-semi.c
pci-versatile.c PCI: versatile: Remove redundant variable retval 2022-04-28 10:46:37 +01:00
pci-xgene-msi.c
pci-xgene.c Merge branch 'remotes/lorenzo/pci/xgene' 2022-03-22 17:16:27 -05:00
pcie-altera-msi.c
pcie-altera.c
pcie-apple.c PCI: apple: Change MSI handling to handle 4-cell AIC fwspec form 2022-03-10 09:49:03 +00:00
pcie-brcmstb.c Revert "PCI: brcmstb: Split brcm_pcie_setup() into two funcs" 2022-05-31 15:06:19 -05:00
pcie-hisi-error.c
pcie-iproc-bcma.c PCI: Add defines for normal and subtractive PCI bridges 2022-02-17 15:29:35 -06:00
pcie-iproc-msi.c
pcie-iproc-platform.c
pcie-iproc.c PCI: iproc: Set all 24 bits of PCI class code 2022-02-17 15:30:01 -06:00
pcie-iproc.h
pcie-mediatek-gen3.c PCI: mediatek-gen3: Assert resets to ensure expected init state 2022-05-11 15:25:26 +01:00
pcie-mediatek.c PCI: mediatek: Fix refcount leak in mtk_pcie_subsys_powerup() 2022-04-08 15:29:44 +01:00
pcie-microchip-host.c PCI: microchip: Fix potential race in interrupt handling 2022-05-18 17:14:21 +01:00
pcie-mt7621.c PCI: mt7621: Remove unused function pcie_rmw() 2022-01-25 18:02:02 -06:00
pcie-rcar-ep.c
pcie-rcar-host.c Merge branch 'remotes/lorenzo/pci/rcar' 2022-03-22 17:16:26 -05:00
pcie-rcar.c
pcie-rcar.h
pcie-rockchip-ep.c PCI: rockchip: Fix find_first_zero_bit() limit 2022-04-08 14:42:07 +01:00
pcie-rockchip-host.c PCI: Add defines for normal and subtractive PCI bridges 2022-02-17 15:29:35 -06:00
pcie-rockchip.c
pcie-rockchip.h PCI: Add defines for normal and subtractive PCI bridges 2022-02-17 15:29:35 -06:00
pcie-xilinx-cpm.c
pcie-xilinx-nwl.c
pcie-xilinx.c
vmd.c PCI: vmd: Revert 2565e5b69c ("PCI: vmd: Do not disable MSI-X remapping if interrupt remapping is enabled by IOMMU.") 2022-05-12 15:54:14 +01:00