Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Input: walkera0701 - use module_parport_driver macro to simplify the code

Use the module_parport_driver macro to simplify the code, which is the
same as declaring with module_init() and module_exit().

Signed-off-by: Li Zetao <lizetao1@huawei.com>
Link: https://lore.kernel.org/r/20230815080107.1089401-1-lizetao1@huawei.com
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>

authored by

Li Zetao and committed by
Dmitry Torokhov
28d3fe32 eb988e46

+1 -12
+1 -12
drivers/input/joystick/walkera0701.c
··· 296 296 .devmodel = true, 297 297 }; 298 298 299 - static int __init walkera0701_init(void) 300 - { 301 - return parport_register_driver(&walkera0701_parport_driver); 302 - } 303 - 304 - static void __exit walkera0701_exit(void) 305 - { 306 - parport_unregister_driver(&walkera0701_parport_driver); 307 - } 308 - 309 - module_init(walkera0701_init); 310 - module_exit(walkera0701_exit); 299 + module_parport_driver(walkera0701_parport_driver);