linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Pali Rohár" <pali@kernel.org>
To: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
Cc: "Daire McNamara" <daire.mcnamara@microchip.com>,
	"Lorenzo Pieralisi" <lorenzo.pieralisi@arm.com>,
	"Rob Herring" <robh@kernel.org>,
	"Krzysztof Wilczyński" <kw@linux.com>,
	linux-pci@vger.kernel.org, "Ian Cowan" <ian@linux.cowan.aero>,
	kernel@pengutronix.de,
	"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
	"Bjorn Helgaas" <bhelgaas@google.com>,
	Conor.Dooley@microchip.com
Subject: Re: [PATCH] PCI: microchip: Allow driver to be built as a module
Date: Wed, 20 Apr 2022 18:41:39 +0200	[thread overview]
Message-ID: <20220420164139.k37fc3xixn4j7kug@pali> (raw)
In-Reply-To: <20220420093449.38054-1-u.kleine-koenig@pengutronix.de>

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@kernel.org/t/#u

> so allow to configure PCIE_MICROCHIP_HOST=m.
> 
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
> ---
>  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
> 

  reply	other threads:[~2022-04-20 16:41 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-20  9:34 [PATCH] PCI: microchip: Allow driver to be built as a module Uwe Kleine-König
2022-04-20 16:41 ` Pali Rohár [this message]
2022-04-21 11:31   ` Conor.Dooley
2022-04-21 13:41     ` Pali Rohár
2022-04-21 13:55       ` Conor.Dooley
2022-04-21 16:18         ` Uwe Kleine-König

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220420164139.k37fc3xixn4j7kug@pali \
    --to=pali@kernel.org \
    --cc=Conor.Dooley@microchip.com \
    --cc=bhelgaas@google.com \
    --cc=daire.mcnamara@microchip.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=ian@linux.cowan.aero \
    --cc=kernel@pengutronix.de \
    --cc=kw@linux.com \
    --cc=linux-pci@vger.kernel.org \
    --cc=lorenzo.pieralisi@arm.com \
    --cc=robh@kernel.org \
    --cc=u.kleine-koenig@pengutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).