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>
This commit is contained in:
Alex Briskin 2017-08-25 19:25:06 +03:00 committed by Greg Kroah-Hartman
parent 8eff21bcc6
commit b21bb6d483

View file

@ -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);