[PATCH] powerpc/eeh/of: use builtin_platform_driver

Geliang Tang geliangtang at gmail.com
Thu Nov 24 01:58:56 AEDT 2016


Use builtin_platform_driver() helper to simplify the code.

Signed-off-by: Geliang Tang <geliangtang at gmail.com>
---
 arch/powerpc/kernel/of_platform.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/arch/powerpc/kernel/of_platform.c b/arch/powerpc/kernel/of_platform.c
index b60a67d..34aeac5 100644
--- a/arch/powerpc/kernel/of_platform.c
+++ b/arch/powerpc/kernel/of_platform.c
@@ -114,11 +114,6 @@ static struct platform_driver of_pci_phb_driver = {
 	},
 };
 
-static __init int of_pci_phb_init(void)
-{
-	return platform_driver_register(&of_pci_phb_driver);
-}
-
-device_initcall(of_pci_phb_init);
+builtin_platform_driver(of_pci_phb_driver);
 
 #endif /* CONFIG_PPC_OF_PLATFORM_PCI */
-- 
2.9.3



More information about the Linuxppc-dev mailing list