Re: [PATCH v4 02/18] PCI: dwc: Factor out the PORT_LINK_DEBUG1 link-up check
From: Marek Vasut
Date: Sat Oct 17 2026 - 08:12:49 EST
On 10/15/26 5:30 AM, Koichiro Den wrote:
dw_pcie_link_up() reads PORT_LINK_DEBUG1 when the glue driver providesReviewed-by: Marek Vasut <marek.vasut+renesas@xxxxxxxxxxx>
no .link_up() callback. A callback that needs a platform-specific check
on top of that register would have to duplicate the register read.
Factor the check out into dw_pcie_link_up_debug_check() and export it
for modular glue drivers. pcie-rcar-gen4 will be the first user: its APP
link-up events remain latched after the link goes down, so it has to
combine them with the live PORT_LINK_DEBUG1 state.
No functional change.
Suggested-by: Marek Vasut <marek.vasut+renesas@xxxxxxxxxxx>
Signed-off-by: Koichiro Den <den@xxxxxxxxxxxxx>