]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
PCI: microchip: Enable building driver as a module
authorDaire McNamara <daire.mcnamara@microchip.com>
Fri, 28 Jul 2023 13:13:56 +0000 (14:13 +0100)
committerLorenzo Pieralisi <lpieralisi@kernel.org>
Tue, 8 Aug 2023 10:55:55 +0000 (12:55 +0200)
Enable building driver as a module. The expected use case is the
driver is built as a module, is installed when needed, and cannot be
removed once installed since it is not possible to clean-up
the irq_chip data structures on removal, as described in:

https://lore.kernel.org/linux-pci/87y1wgbah8.wl-maz@kernel.org/

The driver has .suppress_bind_attrs set to true for the same
reasons (ie prevent unbinding, that would leave the kernel
with stale IRQ configuration that cannot be cleaned up).

Link: https://lore.kernel.org/linux-pci/87y1wgbah8.wl-maz@kernel.org/
Link: https://lore.kernel.org/r/20230728131401.1615724-3-daire.mcnamara@microchip.com
Suggested-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Daire McNamara <daire.mcnamara@microchip.com>
Signed-off-by: Lorenzo Pieralisi <lpieralisi@kernel.org>
Acked-by: Conor Dooley <conor.dooley@microchip.com>
drivers/pci/controller/Kconfig
drivers/pci/controller/pcie-microchip-host.c

index 8d49bad7f84728add52a9f3b53d6f189de69813b..f4ad0e9cca459193c2949539789cf1ed6e247026 100644 (file)
@@ -217,7 +217,7 @@ config PCIE_MT7621
          This selects a driver for the MediaTek MT7621 PCIe Controller.
 
 config PCIE_MICROCHIP_HOST
-       bool "Microchip AXI PCIe controller"
+       tristate "Microchip AXI PCIe controller"
        depends on PCI_MSI && OF
        select PCI_HOST_COMMON
        help
index dd5245904c874561e2432e43320f61ffa08d1e6d..5c89caaab8c9283b1b0c754324cfc973eecfe696 100644 (file)
@@ -1135,5 +1135,6 @@ static struct platform_driver mc_pcie_driver = {
 };
 
 builtin_platform_driver(mc_pcie_driver);
+MODULE_LICENSE("GPL");
 MODULE_DESCRIPTION("Microchip PCIe host controller driver");
 MODULE_AUTHOR("Daire McNamara <daire.mcnamara@microchip.com>");