diff options
author | Andrzej Hajda <a.hajda@samsung.com> | 2015-06-11 17:20:52 +0300 |
---|---|---|
committer | Inki Dae <daeinki@gmail.com> | 2015-06-19 18:32:55 +0300 |
commit | 417133e46924a9aa7bfa0e17dab01a1b475878c4 (patch) | |
tree | 23272a6c611178774a3077c4a132964388d4c752 /drivers/gpu/drm/exynos/exynos_drm_vidi.c | |
parent | 38000dbb71ded4121b27338a2d41ad060001592a (diff) | |
download | linux-417133e46924a9aa7bfa0e17dab01a1b475878c4.tar.xz |
drm/exynos: consolidate driver/device initialization code
Code registering different drivers and simple platform devices was dispersed
across multiple sub-modules. This patch moves it to one place. As a result
initialization code is shorter and cleaner and should simplify further
development.
Signed-off-by: Andrzej Hajda <a.hajda@samsung.com>
Signed-off-by: Inki Dae <inki.dae@samsung.com>
Diffstat (limited to 'drivers/gpu/drm/exynos/exynos_drm_vidi.c')
-rw-r--r-- | drivers/gpu/drm/exynos/exynos_drm_vidi.c | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_vidi.c b/drivers/gpu/drm/exynos/exynos_drm_vidi.c index 16dc68cf7c88..a12ae3850256 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_vidi.c +++ b/drivers/gpu/drm/exynos/exynos_drm_vidi.c @@ -569,38 +569,3 @@ struct platform_driver vidi_driver = { .owner = THIS_MODULE, }, }; - -int exynos_drm_probe_vidi(void) -{ - struct platform_device *pdev; - int ret; - - pdev = platform_device_register_simple("exynos-drm-vidi", -1, NULL, 0); - if (IS_ERR(pdev)) - return PTR_ERR(pdev); - - ret = platform_driver_register(&vidi_driver); - if (ret) { - platform_device_unregister(pdev); - return ret; - } - - return ret; -} - -static int exynos_drm_remove_vidi_device(struct device *dev, void *data) -{ - platform_device_unregister(to_platform_device(dev)); - - return 0; -} - -void exynos_drm_remove_vidi(void) -{ - int ret = driver_for_each_device(&vidi_driver.driver, NULL, NULL, - exynos_drm_remove_vidi_device); - /* silence compiler warning */ - (void)ret; - - platform_driver_unregister(&vidi_driver); -} |