diff options
author | Tomi Valkeinen <tomi.valkeinen@ti.com> | 2013-04-26 07:27:44 -0400 |
---|---|---|
committer | Tomi Valkeinen <tomi.valkeinen@ti.com> | 2013-05-02 05:23:30 -0400 |
commit | 94cf394b15f94090c8ebd874b29725d35eb54663 (patch) | |
tree | c8944ccfbf6e562dc90a2c8f8acf3fa6401b2b50 | |
parent | dfbc32316c6991010328c21e6046b05bac57eb84 (diff) |
OMAPDSS: DPI: use platform_driver_register()
Use platform_driver_register() instead of platform_driver_probe() so
that we can support EPROBE_DEFER.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
-rw-r--r-- | drivers/video/omap2/dss/dpi.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/drivers/video/omap2/dss/dpi.c b/drivers/video/omap2/dss/dpi.c index e93c4debea7f..202478795c1b 100644 --- a/drivers/video/omap2/dss/dpi.c +++ b/drivers/video/omap2/dss/dpi.c | |||
@@ -520,7 +520,7 @@ void omapdss_dpi_set_data_lines(struct omap_dss_device *dssdev, int data_lines) | |||
520 | } | 520 | } |
521 | EXPORT_SYMBOL(omapdss_dpi_set_data_lines); | 521 | EXPORT_SYMBOL(omapdss_dpi_set_data_lines); |
522 | 522 | ||
523 | static int __init dpi_verify_dsi_pll(struct platform_device *dsidev) | 523 | static int dpi_verify_dsi_pll(struct platform_device *dsidev) |
524 | { | 524 | { |
525 | int r; | 525 | int r; |
526 | 526 | ||
@@ -572,7 +572,7 @@ static enum omap_channel dpi_get_channel(void) | |||
572 | } | 572 | } |
573 | } | 573 | } |
574 | 574 | ||
575 | static int __init dpi_init_display(struct omap_dss_device *dssdev) | 575 | static int dpi_init_display(struct omap_dss_device *dssdev) |
576 | { | 576 | { |
577 | struct platform_device *dsidev; | 577 | struct platform_device *dsidev; |
578 | 578 | ||
@@ -607,7 +607,7 @@ static int __init dpi_init_display(struct omap_dss_device *dssdev) | |||
607 | return 0; | 607 | return 0; |
608 | } | 608 | } |
609 | 609 | ||
610 | static struct omap_dss_device * __init dpi_find_dssdev(struct platform_device *pdev) | 610 | static struct omap_dss_device *dpi_find_dssdev(struct platform_device *pdev) |
611 | { | 611 | { |
612 | struct omap_dss_board_info *pdata = pdev->dev.platform_data; | 612 | struct omap_dss_board_info *pdata = pdev->dev.platform_data; |
613 | const char *def_disp_name = omapdss_get_default_display_name(); | 613 | const char *def_disp_name = omapdss_get_default_display_name(); |
@@ -635,7 +635,7 @@ static struct omap_dss_device * __init dpi_find_dssdev(struct platform_device *p | |||
635 | return def_dssdev; | 635 | return def_dssdev; |
636 | } | 636 | } |
637 | 637 | ||
638 | static void __init dpi_probe_pdata(struct platform_device *dpidev) | 638 | static void dpi_probe_pdata(struct platform_device *dpidev) |
639 | { | 639 | { |
640 | struct omap_dss_device *plat_dssdev; | 640 | struct omap_dss_device *plat_dssdev; |
641 | struct omap_dss_device *dssdev; | 641 | struct omap_dss_device *dssdev; |
@@ -676,7 +676,7 @@ static void __init dpi_probe_pdata(struct platform_device *dpidev) | |||
676 | } | 676 | } |
677 | } | 677 | } |
678 | 678 | ||
679 | static void __init dpi_init_output(struct platform_device *pdev) | 679 | static void dpi_init_output(struct platform_device *pdev) |
680 | { | 680 | { |
681 | struct omap_dss_output *out = &dpi.output; | 681 | struct omap_dss_output *out = &dpi.output; |
682 | 682 | ||
@@ -696,7 +696,7 @@ static void __exit dpi_uninit_output(struct platform_device *pdev) | |||
696 | dss_unregister_output(out); | 696 | dss_unregister_output(out); |
697 | } | 697 | } |
698 | 698 | ||
699 | static int __init omap_dpi_probe(struct platform_device *pdev) | 699 | static int omap_dpi_probe(struct platform_device *pdev) |
700 | { | 700 | { |
701 | mutex_init(&dpi.lock); | 701 | mutex_init(&dpi.lock); |
702 | 702 | ||
@@ -717,6 +717,7 @@ static int __exit omap_dpi_remove(struct platform_device *pdev) | |||
717 | } | 717 | } |
718 | 718 | ||
719 | static struct platform_driver omap_dpi_driver = { | 719 | static struct platform_driver omap_dpi_driver = { |
720 | .probe = omap_dpi_probe, | ||
720 | .remove = __exit_p(omap_dpi_remove), | 721 | .remove = __exit_p(omap_dpi_remove), |
721 | .driver = { | 722 | .driver = { |
722 | .name = "omapdss_dpi", | 723 | .name = "omapdss_dpi", |
@@ -726,7 +727,7 @@ static struct platform_driver omap_dpi_driver = { | |||
726 | 727 | ||
727 | int __init dpi_init_platform_driver(void) | 728 | int __init dpi_init_platform_driver(void) |
728 | { | 729 | { |
729 | return platform_driver_probe(&omap_dpi_driver, omap_dpi_probe); | 730 | return platform_driver_register(&omap_dpi_driver); |
730 | } | 731 | } |
731 | 732 | ||
732 | void __exit dpi_uninit_platform_driver(void) | 733 | void __exit dpi_uninit_platform_driver(void) |