From 462dd83833065a6b3add3f102f4fe69efa1422e9 Mon Sep 17 00:00:00 2001 From: Axel Lin Date: Fri, 23 Mar 2012 15:01:59 -0700 Subject: backlight: convert backlight spi drivers to module_spi_driver Factor out some boilerplate code for spi driver registration into module_spi_driver. Signed-off-by: Axel Lin Acked-by: Jingoo Han Cc: Eric Miao Acked-by: Alberto Panizzo Cc: Donghwa Lee Acked-by: Marek Vasut Cc: Haavard Skinnemoen Cc: InKi Dae Cc: Dmitry Baryshkov Cc: Ben Dooks Cc: Richard Purdie Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/video/backlight/lms283gf05.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) (limited to 'drivers/video/backlight/lms283gf05.c') diff --git a/drivers/video/backlight/lms283gf05.c b/drivers/video/backlight/lms283gf05.c index 4ec78cfe26ea..4161f9e3982a 100644 --- a/drivers/video/backlight/lms283gf05.c +++ b/drivers/video/backlight/lms283gf05.c @@ -226,18 +226,7 @@ static struct spi_driver lms283gf05_driver = { .remove = __devexit_p(lms283gf05_remove), }; -static __init int lms283gf05_init(void) -{ - return spi_register_driver(&lms283gf05_driver); -} - -static __exit void lms283gf05_exit(void) -{ - spi_unregister_driver(&lms283gf05_driver); -} - -module_init(lms283gf05_init); -module_exit(lms283gf05_exit); +module_spi_driver(lms283gf05_driver); MODULE_AUTHOR("Marek Vasut "); MODULE_DESCRIPTION("LCD283GF05 LCD"); -- cgit v1.2.3