diff options
Diffstat (limited to 'drivers/i2c/busses/i2c-imx.c')
-rw-r--r-- | drivers/i2c/busses/i2c-imx.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/i2c/busses/i2c-imx.c b/drivers/i2c/busses/i2c-imx.c index ccf46656bdad..1d7efa3169cd 100644 --- a/drivers/i2c/busses/i2c-imx.c +++ b/drivers/i2c/busses/i2c-imx.c | |||
@@ -365,7 +365,7 @@ static void i2c_imx_stop(struct imx_i2c_struct *i2c_imx) | |||
365 | clk_disable_unprepare(i2c_imx->clk); | 365 | clk_disable_unprepare(i2c_imx->clk); |
366 | } | 366 | } |
367 | 367 | ||
368 | static void __init i2c_imx_set_clk(struct imx_i2c_struct *i2c_imx, | 368 | static void i2c_imx_set_clk(struct imx_i2c_struct *i2c_imx, |
369 | unsigned int rate) | 369 | unsigned int rate) |
370 | { | 370 | { |
371 | struct imx_i2c_clk_pair *i2c_clk_div = i2c_imx->hwdata->clk_div; | 371 | struct imx_i2c_clk_pair *i2c_clk_div = i2c_imx->hwdata->clk_div; |
@@ -589,7 +589,7 @@ static struct i2c_algorithm i2c_imx_algo = { | |||
589 | .functionality = i2c_imx_func, | 589 | .functionality = i2c_imx_func, |
590 | }; | 590 | }; |
591 | 591 | ||
592 | static int __init i2c_imx_probe(struct platform_device *pdev) | 592 | static int i2c_imx_probe(struct platform_device *pdev) |
593 | { | 593 | { |
594 | const struct of_device_id *of_id = of_match_device(i2c_imx_dt_ids, | 594 | const struct of_device_id *of_id = of_match_device(i2c_imx_dt_ids, |
595 | &pdev->dev); | 595 | &pdev->dev); |
@@ -697,7 +697,7 @@ static int __init i2c_imx_probe(struct platform_device *pdev) | |||
697 | return 0; /* Return OK */ | 697 | return 0; /* Return OK */ |
698 | } | 698 | } |
699 | 699 | ||
700 | static int __exit i2c_imx_remove(struct platform_device *pdev) | 700 | static int i2c_imx_remove(struct platform_device *pdev) |
701 | { | 701 | { |
702 | struct imx_i2c_struct *i2c_imx = platform_get_drvdata(pdev); | 702 | struct imx_i2c_struct *i2c_imx = platform_get_drvdata(pdev); |
703 | 703 | ||
@@ -715,7 +715,8 @@ static int __exit i2c_imx_remove(struct platform_device *pdev) | |||
715 | } | 715 | } |
716 | 716 | ||
717 | static struct platform_driver i2c_imx_driver = { | 717 | static struct platform_driver i2c_imx_driver = { |
718 | .remove = __exit_p(i2c_imx_remove), | 718 | .probe = i2c_imx_probe, |
719 | .remove = i2c_imx_remove, | ||
719 | .driver = { | 720 | .driver = { |
720 | .name = DRIVER_NAME, | 721 | .name = DRIVER_NAME, |
721 | .owner = THIS_MODULE, | 722 | .owner = THIS_MODULE, |
@@ -726,7 +727,7 @@ static struct platform_driver i2c_imx_driver = { | |||
726 | 727 | ||
727 | static int __init i2c_adap_imx_init(void) | 728 | static int __init i2c_adap_imx_init(void) |
728 | { | 729 | { |
729 | return platform_driver_probe(&i2c_imx_driver, i2c_imx_probe); | 730 | return platform_driver_register(&i2c_imx_driver); |
730 | } | 731 | } |
731 | subsys_initcall(i2c_adap_imx_init); | 732 | subsys_initcall(i2c_adap_imx_init); |
732 | 733 | ||