PCI: host-generic: Support building as modules
Enable building host-generic and its host-common dependency as a module. Link: https://lore.kernel.org/r/20200409234923.21598-3-robh@kernel.org Signed-off-by: Rob Herring <robh@kernel.org> Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Acked-by: Will Deacon <will@kernel.org> Acked-by: Bjorn Helgaas <bhelgaas@google.com> Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Cc: Andrew Murray <amurray@thegoodpenguin.co.uk> Cc: Bjorn Helgaas <bhelgaas@google.com> Cc: Will Deacon <will@kernel.org> Cc: linux-pci@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org
This commit is contained in:

committed by
Lorenzo Pieralisi

parent
0b104773b4
commit
0c59c06a7c
@@ -10,6 +10,7 @@
|
||||
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/init.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/of_address.h>
|
||||
#include <linux/of_pci.h>
|
||||
#include <linux/pci-ecam.h>
|
||||
@@ -76,6 +77,7 @@ static const struct of_device_id gen_pci_of_match[] = {
|
||||
|
||||
{ },
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, gen_pci_of_match);
|
||||
|
||||
static int gen_pci_probe(struct platform_device *pdev)
|
||||
{
|
||||
@@ -92,9 +94,10 @@ static struct platform_driver gen_pci_driver = {
|
||||
.driver = {
|
||||
.name = "pci-host-generic",
|
||||
.of_match_table = gen_pci_of_match,
|
||||
.suppress_bind_attrs = true,
|
||||
},
|
||||
.probe = gen_pci_probe,
|
||||
.remove = pci_host_common_remove,
|
||||
};
|
||||
builtin_platform_driver(gen_pci_driver);
|
||||
module_platform_driver(gen_pci_driver);
|
||||
|
||||
MODULE_LICENSE("GPL v2");
|
||||
|
Reference in New Issue
Block a user