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

misc: atmel_pwm: use module_platform_driver_probe()

This patch uses module_platform_driver_probe() macro which makes
the code smaller and simpler.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Jingoo Han and committed by
Greg Kroah-Hartman
4022ed5a 0c759482

+1 -11
+1 -11
drivers/misc/atmel_pwm.c
··· 393 393 */ 394 394 }; 395 395 396 - static int __init pwm_init(void) 397 - { 398 - return platform_driver_probe(&atmel_pwm_driver, pwm_probe); 399 - } 400 - module_init(pwm_init); 401 - 402 - static void __exit pwm_exit(void) 403 - { 404 - platform_driver_unregister(&atmel_pwm_driver); 405 - } 406 - module_exit(pwm_exit); 396 + module_platform_driver_probe(atmel_pwm_driver, pwm_probe); 407 397 408 398 MODULE_DESCRIPTION("Driver for AT32/AT91 PWM module"); 409 399 MODULE_LICENSE("GPL");