summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2019-08-14 04:23:16 -0400
committerShawn Guo <shawnguo@kernel.org>2019-08-19 08:07:23 -0400
commit4a92f07816ba3020c690cc0f6e9627fec15b335e (patch)
tree66ae3d3c83e1fa6317318b92ea646dabe5979852
parentffbf23d50353915dc2622a3b7b4ddc678165f92d (diff)
bus: imx-weim: use module_platform_driver()
Switch from module_platform_driver_probe() to module_platform_driver(). The former is not suitable for booting with device tree as the driver will be registered before the device and thus won't be probed again when the device is present. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org>
-rw-r--r--drivers/bus/imx-weim.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/bus/imx-weim.c b/drivers/bus/imx-weim.c
index cb7d5504a22a..79af0c27f5a3 100644
--- a/drivers/bus/imx-weim.c
+++ b/drivers/bus/imx-weim.c
@@ -187,8 +187,7 @@ static int __init weim_timing_setup(struct device *dev,
187 return 0; 187 return 0;
188} 188}
189 189
190static int __init weim_parse_dt(struct platform_device *pdev, 190static int weim_parse_dt(struct platform_device *pdev, void __iomem *base)
191 void __iomem *base)
192{ 191{
193 const struct of_device_id *of_id = of_match_device(weim_id_table, 192 const struct of_device_id *of_id = of_match_device(weim_id_table,
194 &pdev->dev); 193 &pdev->dev);
@@ -233,7 +232,7 @@ static int __init weim_parse_dt(struct platform_device *pdev,
233 return ret; 232 return ret;
234} 233}
235 234
236static int __init weim_probe(struct platform_device *pdev) 235static int weim_probe(struct platform_device *pdev)
237{ 236{
238 struct resource *res; 237 struct resource *res;
239 struct clk *clk; 238 struct clk *clk;
@@ -270,8 +269,9 @@ static struct platform_driver weim_driver = {
270 .name = "imx-weim", 269 .name = "imx-weim",
271 .of_match_table = weim_id_table, 270 .of_match_table = weim_id_table,
272 }, 271 },
272 .probe = weim_probe,
273}; 273};
274module_platform_driver_probe(weim_driver, weim_probe); 274module_platform_driver(weim_driver);
275 275
276MODULE_AUTHOR("Freescale Semiconductor Inc."); 276MODULE_AUTHOR("Freescale Semiconductor Inc.");
277MODULE_DESCRIPTION("i.MX EIM Controller Driver"); 277MODULE_DESCRIPTION("i.MX EIM Controller Driver");