From: Marek Vasut Date: Tue, 15 Oct 2013 16:06:38 +0000 (+0200) Subject: PCI: imx6: Probe the PCIe in fs_initcall() X-Git-Tag: upstream/snapshot3+hdmi~3984^2~6^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f216f57ffe6eede3c8a763add65d331e688f8c56;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git PCI: imx6: Probe the PCIe in fs_initcall() Probe the PCIe driver in fs_initcall() instead of module_init() to assure that pci_assign_unassigned_resources() will be called early. This function is called in dw_pcie_host_init(), which is in turn called from imx6_add_pcie_port(), which is called from imx6_pcie_probe(). If this is not called early, we will hit resource collisions since pcieport driver is then probed way too late. Signed-off-by: Marek Vasut Signed-off-by: Bjorn Helgaas Acked-by: Shawn Guo Cc: Frank Li Cc: Jingoo Han Cc: Mohit KUMAR Cc: Pratyush Anand Cc: Richard Zhu Cc: Sascha Hauer Cc: Sean Cross Cc: Siva Reddy Kallam Cc: Srikanth T Shivanand Cc: Tim Harvey Cc: Troy Kisky Cc: Yinghai Lu --- diff --git a/drivers/pci/host/pci-imx6.c b/drivers/pci/host/pci-imx6.c index 0a435b8..bd70af8 100644 --- a/drivers/pci/host/pci-imx6.c +++ b/drivers/pci/host/pci-imx6.c @@ -561,7 +561,7 @@ static int __init imx6_pcie_init(void) { return platform_driver_probe(&imx6_pcie_driver, imx6_pcie_probe); } -module_init(imx6_pcie_init); +fs_initcall(imx6_pcie_init); MODULE_AUTHOR("Sean Cross "); MODULE_DESCRIPTION("Freescale i.MX6 PCIe host controller driver");