linux/drivers/pci/controller
Marek Vasut c93637e6a4 PCI: rcar: Demote WARN() to dev_warn_ratelimited() in rcar_pcie_wakeup()
Avoid large backtrace, it is sufficient to warn the user that there has
been a link problem. Either the link has failed and the system is in need
of maintenance, or the link continues to work and user has been informed.
The message from the warning can be looked up in the sources.

This makes an actual link issue less verbose.

First of all, this controller has a limitation in that the controller
driver has to assist the hardware with transition to L1 link state by
writing L1IATN to PMCTRL register, the L1 and L0 link state switching
is not fully automatic on this controller.

In case of an ASMedia ASM1062 PCIe SATA controller which does not support
ASPM, on entry to suspend or during platform pm_test, the SATA controller
enters D3hot state and the link enters L1 state. If the SATA controller
wakes up before rcar_pcie_wakeup() was called and returns to D0, the link
returns to L0 before the controller driver even started its transition to
L1 link state. At this point, the SATA controller did send an PM_ENTER_L1
DLLP to the PCIe controller and the PCIe controller received it, and the
PCIe controller did set PMSR PMEL1RX bit.

Once rcar_pcie_wakeup() is called, if the link is already back in L0 state
and PMEL1RX bit is set, the controller driver has no way to determine if
it should perform the link transition to L1 state, or treat the link as if
it is in L0 state. Currently the driver attempts to perform the transition
to L1 link state unconditionally, which in this specific case fails with a
PMSR L1FAEG poll timeout, however the link still works as it is already
back in L0 state.

Reduce this warning verbosity. In case the link is really broken, the
rcar_pcie_config_access() would fail, otherwise it will succeed and any
system with this controller and ASM1062 can suspend without generating
a backtrace.

Fixes: 84b5761462 ("PCI: rcar: Finish transition to L1 state in rcar_pcie_config_access()")
Link: https://lore.kernel.org/linux-pci/20240511235513.77301-1-marek.vasut+renesas@mailbox.org
Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org>
Signed-off-by: Krzysztof Wilczyński <kwilczynski@kernel.org>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
2024-05-28 11:15:47 -05:00
..
cadence Merge branch 'pci/controller/dwc' 2024-05-16 18:14:12 -05:00
dwc Merge branch 'pci/controller/tegra194' 2024-05-16 18:14:13 -05:00
mobiveil PCI: Use PCI_HEADER_TYPE_* instead of literals 2023-10-03 11:55:59 -05:00
Kconfig PCI: xilinx-xdma: Add Xilinx XDMA Root Port driver 2023-10-26 15:02:02 +00:00
Makefile PCI: xilinx-xdma: Add Xilinx XDMA Root Port driver 2023-10-26 15:02:02 +00:00
pci-aardvark.c PCI: aardvark: Convert to platform remove callback returning void 2023-06-24 14:10:09 +00:00
pci-ftpci100.c PCI: Explicitly include correct DT includes 2023-07-18 14:33:17 -05:00
pci-host-common.c PCI: host-generic: Convert to platform remove callback returning void 2023-11-20 15:53:14 -06:00
pci-host-generic.c PCI: host-generic: Convert to platform remove callback returning void 2023-11-20 15:53:14 -06:00
pci-hyperv-intf.c
pci-hyperv.c PCI: hv: Fix ring buffer size calculation 2024-03-10 18:54:12 +00:00
pci-ixp4xx.c PCI: Explicitly include correct DT includes 2023-07-18 14:33:17 -05:00
pci-loongson.c PCI: loongson: Limit MRRS to 256 2023-12-08 10:48:37 -06:00
pci-mvebu.c PCI: mvebu: Use FIELD_PREP() with Link Width 2023-10-10 15:00:52 -05:00
pci-rcar-gen2.c PCI: rcar-gen2: Use devm_platform_get_and_ioremap_resource() 2023-07-13 18:12:35 +00:00
pci-tegra.c PCI: tegra: Convert to platform remove callback returning void 2023-06-24 14:14:02 +00:00
pci-thunder-ecam.c
pci-thunder-pem.c
pci-v3-semi.c Merge branch 'pci/misc' 2023-08-29 11:03:57 -05:00
pci-versatile.c PCI: Remove MODULE_LICENSE so boolean drivers don't look like modules 2023-02-17 08:47:58 -06:00
pci-xgene-msi.c PCI: xgene-msi: Use devm_platform_get_and_ioremap_resource() 2023-07-13 18:12:36 +00:00
pci-xgene.c PCI: xgene: Do PCI error check on own line & keep return value 2023-10-10 16:40:18 -05:00
pcie-altera-msi.c PCI: altera-msi: Convert to platform remove callback returning void 2023-06-24 14:10:47 +00:00
pcie-altera.c PCI: Explicitly include correct DT includes 2023-07-18 14:33:17 -05:00
pcie-apple.c Merge branch 'pci/misc' 2023-08-29 11:03:57 -05:00
pcie-brcmstb.c PCI: brcmstb: Fix broken brcm_pcie_mdio_write() polling 2024-03-10 17:56:10 +00:00
pcie-hisi-error.c PCI: hisi-error: Convert to platform remove callback returning void 2023-06-24 14:12:13 +00:00
pcie-iproc-bcma.c
pcie-iproc-msi.c PCI: iproc: Use of_property_read_bool() for boolean properties 2023-07-13 18:09:24 +00:00
pcie-iproc-platform.c PCI: iproc: Fix -Wvoid-pointer-to-enum-cast warning 2024-01-06 08:06:50 +00:00
pcie-iproc.c PCI: Use PCI_HEADER_TYPE_* instead of literals 2023-10-03 11:55:59 -05:00
pcie-iproc.h PCI: iproc: Convert to platform remove callback returning void 2023-06-24 14:12:36 +00:00
pcie-mediatek-gen3.c PCI: mediatek-gen3: Fix translation window size calculation 2024-01-09 16:42:22 -06:00
pcie-mediatek.c PCI: mediatek: Clear interrupt status before dispatching handler 2024-01-09 16:41:23 -06:00
pcie-microchip-host.c Merge branch 'pci/controller/remove-void-cast' 2023-08-29 11:03:56 -05:00
pcie-mt7621.c PCI: mt7621: Fix string truncation in mt7621_pcie_parse_port() 2024-04-11 11:33:48 +00:00
pcie-rcar-ep.c PCI: endpoint: Remove "core_init_notifier" flag 2024-04-10 17:52:42 +00:00
pcie-rcar-host.c PCI: rcar: Demote WARN() to dev_warn_ratelimited() in rcar_pcie_wakeup() 2024-05-28 11:15:47 -05:00
pcie-rcar.c
pcie-rcar.h PCI: rcar: Avoid defines prefixed with CONFIG 2023-03-10 13:34:27 +01:00
pcie-rockchip-ep.c Merge branch 'pci/controller/rockchip' 2024-05-16 18:14:13 -05:00
pcie-rockchip-host.c PCI: rockchip-host: Rename rockchip_pcie_legacy_int_handler() 2023-12-19 09:36:42 +01:00
pcie-rockchip.c PCI: Explicitly include correct DT includes 2023-07-18 14:33:17 -05:00
pcie-rockchip.h PCI: rockchip: Use 64-bit mask on MSI 64-bit PCI address 2023-07-13 18:25:44 +00:00
pcie-xilinx-common.h PCI: xilinx-xdma: Add Xilinx XDMA Root Port driver 2023-10-26 15:02:02 +00:00
pcie-xilinx-cpm.c PCI: xilinx-cpm: Move IRQ definitions to a common header 2023-10-26 14:10:42 +00:00
pcie-xilinx-dma-pl.c PCI: xilinx-xdma: Fix error code in xilinx_pl_dma_pcie_init_irq_domain() 2024-01-08 17:44:45 +00:00
pcie-xilinx-nwl.c PCI: xilinx-nwl: Use INTX instead of legacy 2023-12-19 09:36:42 +01:00
pcie-xilinx.c
vmd.c pci-v6.8-changes 2024-01-17 16:23:17 -08:00