summaryrefslogtreecommitdiff
path: root/drivers/media/video/s5p-jpeg
diff options
context:
space:
mode:
authorSachin Kamat <sachin.kamat@linaro.org>2012-07-03 08:54:33 (GMT)
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-07-06 21:16:50 (GMT)
commit87e9429490dfe610faaf209795942272bc7a730a (patch)
tree6f05f24ddc3f18b22bc0a188ece4658a387a51b0 /drivers/media/video/s5p-jpeg
parent91268a5e788c5bf246650c3a8c1a4626b9f0fe11 (diff)
downloadlinux-87e9429490dfe610faaf209795942272bc7a730a.tar.xz
[media] s5p-jpeg: Use module_platform_driver in jpeg-core.c file
module_platform_driver makes the code simpler by eliminating module_init and module_exit calls. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/s5p-jpeg')
-rw-r--r--drivers/media/video/s5p-jpeg/jpeg-core.c24
1 files changed, 1 insertions, 23 deletions
diff --git a/drivers/media/video/s5p-jpeg/jpeg-core.c b/drivers/media/video/s5p-jpeg/jpeg-core.c
index 28b5225d..e40e79b 100644
--- a/drivers/media/video/s5p-jpeg/jpeg-core.c
+++ b/drivers/media/video/s5p-jpeg/jpeg-core.c
@@ -1503,29 +1503,7 @@ static struct platform_driver s5p_jpeg_driver = {
},
};
-static int __init
-s5p_jpeg_register(void)
-{
- int ret;
-
- pr_info("S5P JPEG V4L2 Driver, (c) 2011 Samsung Electronics\n");
-
- ret = platform_driver_register(&s5p_jpeg_driver);
-
- if (ret)
- pr_err("%s: failed to register jpeg driver\n", __func__);
-
- return ret;
-}
-
-static void __exit
-s5p_jpeg_unregister(void)
-{
- platform_driver_unregister(&s5p_jpeg_driver);
-}
-
-module_init(s5p_jpeg_register);
-module_exit(s5p_jpeg_unregister);
+module_platform_driver(s5p_jpeg_driver);
MODULE_AUTHOR("Andrzej Pietrasiewicz <andrzej.p@samsung.com>");
MODULE_DESCRIPTION("Samsung JPEG codec driver");