From 70bdf0de74b2d8375e8d4851d459d20adbc32a9c Mon Sep 17 00:00:00 2001 From: Kefeng Wang Date: Tue, 29 Sep 2015 10:36:59 +0800 Subject: PCI: hisi: use subsys_initcall for hisi pcie init Some pcie device drivers like vgaarb probe very early, so the pcie host driver should initialize earlier, use subsys_initcall instead of module_platform_driver. Cc: liudongdong Cc: Gabriele Paoloni CC: Zhou Wang Signed-off-by: Kefeng Wang Signed-off-by: Ding Tianhong Signed-off-by: Zhou Wang Signed-off-by: Hanjun Guo --- drivers/pci/host/pcie-hisi.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/pci/host/pcie-hisi.c b/drivers/pci/host/pcie-hisi.c index b7043d898462..7a655f81f979 100644 --- a/drivers/pci/host/pcie-hisi.c +++ b/drivers/pci/host/pcie-hisi.c @@ -273,11 +273,14 @@ static const struct of_device_id hisi_pcie_of_match[] = { MODULE_DEVICE_TABLE(of, hisi_pcie_of_match); static struct platform_driver hisi_pcie_driver = { - .probe = hisi_pcie_probe, .driver = { .name = "hisi-pcie", .of_match_table = hisi_pcie_of_match, }, }; -module_platform_driver(hisi_pcie_driver); +static int __init hisi_pcie_init(void) +{ + return platform_driver_probe(&hisi_pcie_driver, hisi_pcie_probe); +} +subsys_initcall(hisi_pcie_init); -- cgit v1.2.3