diff options
author | Alex Briskin <br.shurik@gmail.com> | 2017-08-25 19:25:06 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-08-28 10:27:29 +0200 |
commit | b21bb6d483a6973f8fd034e3aebcce42e64c3463 (patch) | |
tree | a41fede76e0cb87720c3998f02e8665826b1e8bf /drivers/staging | |
parent | 8eff21bcc6baa1303241ad4c0c8087de0f5022ae (diff) |
staging: unisys: visorinput: Add module_driver driver registration
1. Remove module_init()/module_exit() macroes and
visorbus_register_visor_driver/visorbus_unregister_visor_driver
functions.
2. Replace with a short module_driver macro
Signed-off-by: Alex Briskin <br.shurik@gmail.com>
Acked-by: David Kershner <david.kershner@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r-- | drivers/staging/unisys/visorinput/visorinput.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/drivers/staging/unisys/visorinput/visorinput.c b/drivers/staging/unisys/visorinput/visorinput.c index 26f0b9bd09d9..9d8cbc52de8b 100644 --- a/drivers/staging/unisys/visorinput/visorinput.c +++ b/drivers/staging/unisys/visorinput/visorinput.c @@ -727,18 +727,8 @@ static struct visor_driver visorinput_driver = { .resume = visorinput_resume, }; -static int visorinput_init(void) -{ - return visorbus_register_visor_driver(&visorinput_driver); -} - -static void visorinput_cleanup(void) -{ - visorbus_unregister_visor_driver(&visorinput_driver); -} - -module_init(visorinput_init); -module_exit(visorinput_cleanup); +module_driver(visorinput_driver, visorbus_register_visor_driver, + visorbus_unregister_visor_driver); MODULE_DEVICE_TABLE(visorbus, visorinput_channel_types); |