* [PATCH] PCI: altera: use builtin_platform_driver
@ 2016-11-23 14:52 Geliang Tang
2016-11-25 2:25 ` Ley Foon Tan
2016-12-07 20:32 ` Bjorn Helgaas
0 siblings, 2 replies; 3+ messages in thread
From: Geliang Tang @ 2016-11-23 14:52 UTC (permalink / raw)
To: Ley Foon Tan, Bjorn Helgaas; +Cc: Geliang Tang, rfi, linux-pci, linux-kernel
Use builtin_platform_driver() helper to simplify the code.
Signed-off-by: Geliang Tang <geliangtang@gmail.com>
---
drivers/pci/host/pcie-altera.c | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/drivers/pci/host/pcie-altera.c b/drivers/pci/host/pcie-altera.c
index b0ac4df..eefcb38 100644
--- a/drivers/pci/host/pcie-altera.c
+++ b/drivers/pci/host/pcie-altera.c
@@ -641,8 +641,4 @@ static struct platform_driver altera_pcie_driver = {
},
};
-static int altera_pcie_init(void)
-{
- return platform_driver_register(&altera_pcie_driver);
-}
-device_initcall(altera_pcie_init);
+builtin_platform_driver(altera_pcie_driver);
--
2.9.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] PCI: altera: use builtin_platform_driver
2016-11-23 14:52 [PATCH] PCI: altera: use builtin_platform_driver Geliang Tang
@ 2016-11-25 2:25 ` Ley Foon Tan
2016-12-07 20:32 ` Bjorn Helgaas
1 sibling, 0 replies; 3+ messages in thread
From: Ley Foon Tan @ 2016-11-25 2:25 UTC (permalink / raw)
To: Geliang Tang, Ley Foon Tan, Bjorn Helgaas; +Cc: rfi, linux-pci, linux-kernel
On Rab, 2016-11-23 at 14:52 +0000, Geliang Tang wrote:
> Use builtin_platform_driver() helper to simplify the code.
>
> Signed-off-by: Geliang Tang <geliangtang@gmail.com>
Acked-by: Ley Foon Tan <ley.foon.tan@intel.com>
> ---
> drivers/pci/host/pcie-altera.c | 6 +-----
> 1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/drivers/pci/host/pcie-altera.c b/drivers/pci/host/pcie-
> altera.c
> index b0ac4df..eefcb38 100644
> --- a/drivers/pci/host/pcie-altera.c
> +++ b/drivers/pci/host/pcie-altera.c
> @@ -641,8 +641,4 @@ static struct platform_driver altera_pcie_driver
> = {
> },
> };
>
> -static int altera_pcie_init(void)
> -{
> - return platform_driver_register(&altera_pcie_driver);
> -}
> -device_initcall(altera_pcie_init);
> +builtin_platform_driver(altera_pcie_driver);
> --
> 2.9.3
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] PCI: altera: use builtin_platform_driver
2016-11-23 14:52 [PATCH] PCI: altera: use builtin_platform_driver Geliang Tang
2016-11-25 2:25 ` Ley Foon Tan
@ 2016-12-07 20:32 ` Bjorn Helgaas
1 sibling, 0 replies; 3+ messages in thread
From: Bjorn Helgaas @ 2016-12-07 20:32 UTC (permalink / raw)
To: Geliang Tang; +Cc: Ley Foon Tan, Bjorn Helgaas, rfi, linux-pci, linux-kernel
On Wed, Nov 23, 2016 at 10:52:22PM +0800, Geliang Tang wrote:
> Use builtin_platform_driver() helper to simplify the code.
>
> Signed-off-by: Geliang Tang <geliangtang@gmail.com>
Thanks, Geliang. I already applied an identical patch from Wei Yongjun
that will appear in v4.10.
> ---
> drivers/pci/host/pcie-altera.c | 6 +-----
> 1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/drivers/pci/host/pcie-altera.c b/drivers/pci/host/pcie-altera.c
> index b0ac4df..eefcb38 100644
> --- a/drivers/pci/host/pcie-altera.c
> +++ b/drivers/pci/host/pcie-altera.c
> @@ -641,8 +641,4 @@ static struct platform_driver altera_pcie_driver = {
> },
> };
>
> -static int altera_pcie_init(void)
> -{
> - return platform_driver_register(&altera_pcie_driver);
> -}
> -device_initcall(altera_pcie_init);
> +builtin_platform_driver(altera_pcie_driver);
> --
> 2.9.3
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-pci" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-12-07 20:39 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-23 14:52 [PATCH] PCI: altera: use builtin_platform_driver Geliang Tang
2016-11-25 2:25 ` Ley Foon Tan
2016-12-07 20:32 ` Bjorn Helgaas
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).