Re: [PATCH v5 2/7] PCI: mediatek-gen3: Move mtk_pcie_setup_irq() out of mtk_pcie_setup()
From: Bartosz Golaszewski
Date: Wed Mar 11 2026 - 04:23:32 EST
On Wed, 11 Mar 2026 08:52:17 +0100, Chen-Yu Tsai <wenst@xxxxxxxxxxxx> said:
> mtk_pcie_setup_irq() just sets up the IRQ domains for PCI INTx and MSI,
> and chains them to the controller's interrupt. It's not really related
> to the setup of the actual PCIe controller.
>
> Move the mtk_pcie_setup_irq() call out of and before mtk_pcie_setup(),
> and add a proper error message for when it fails. Reorder
> mtk_pcie_irq_teardown() in the remove callback to follow. Also create
> an error path in the probe function.
>
> Suggested-by: Bjorn Helgaas <helgaas@xxxxxxxxxx>
> Link: https://lore.kernel.org/all/20260309215056.GA603013@bhelgaas/
> Signed-off-by: Chen-Yu Tsai <wenst@xxxxxxxxxxxx>
> ---
Reviewed-by: Bartosz Golaszewski <bartosz.golaszewski@xxxxxxxxxxxxxxxx>