Re: [PATCH] PCI: microchip: Allow driver to be built as a module

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wednesday 20 April 2022 11:34:49 Uwe Kleine-König wrote:
> There are no known reasons to not use this driver as a module,

Hello! I think that there are reasons. pcie-microchip-host.c driver uses
builtin_platform_driver() and not module_platform_driver(); it does not
implement .remove driver callback and also has set suppress_bind_attrs
to true. I think that all these parts should be properly implemented
otherwise it does not have sane reasons to use driver as loadable and
unloadable module.

Btw, I implemented proper module support for pci-mvebu.c driver
recently, so you can take an inspiration. See:
https://lore.kernel.org/linux-pci/20211126144307.7568-1-pali@xxxxxxxxxx/t/#u

> so allow to configure PCIE_MICROCHIP_HOST=m.
> 
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx>
> ---
>  drivers/pci/controller/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/pci/controller/Kconfig b/drivers/pci/controller/Kconfig
> index b8d96d38064d..6eae2289410a 100644
> --- a/drivers/pci/controller/Kconfig
> +++ b/drivers/pci/controller/Kconfig
> @@ -301,7 +301,7 @@ config PCI_LOONGSON
>  	  Loongson systems.
>  
>  config PCIE_MICROCHIP_HOST
> -	bool "Microchip AXI PCIe host bridge support"
> +	tristate "Microchip AXI PCIe host bridge support"
>  	depends on PCI_MSI && OF
>  	select PCI_MSI_IRQ_DOMAIN
>  	select GENERIC_MSI_IRQ_DOMAIN
> 
> base-commit: 3123109284176b1532874591f7c81f3837bbdc17
> prerequisite-patch-id: e8aad0ef8193038684bc2e10d387a7b74da1116a
> -- 
> 2.35.1
> 



[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux