From 25a236a5dba47a16affb105525cfd75eaa03ceea Mon Sep 17 00:00:00 2001 From: Axel Lin Date: Fri, 25 Nov 2011 02:31:00 -0500 Subject: hwmon: convert drivers/hwmon/* to use module_platform_driver() This patch converts the drivers in drivers/hwmon/* to use the module_platform_driver() macro which makes the code smaller and a bit simpler. Cc: Donggeun Kim Cc: Simon Guinot Cc: Lars-Peter Clausen Cc: MyungJoo Ham Cc: Ben Dooks Cc: Hans de Goede Cc: J Keerthy Cc: David S. Miller Cc: Mark Brown Signed-off-by: Axel Lin Acked-by: Mark Brown Signed-off-by: Guenter Roeck --- drivers/hwmon/gpio-fan.c | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) (limited to 'drivers/hwmon/gpio-fan.c') diff --git a/drivers/hwmon/gpio-fan.c b/drivers/hwmon/gpio-fan.c index 89aa9fb743af..9ba38f318ffb 100644 --- a/drivers/hwmon/gpio-fan.c +++ b/drivers/hwmon/gpio-fan.c @@ -539,18 +539,7 @@ static struct platform_driver gpio_fan_driver = { }, }; -static int __init gpio_fan_init(void) -{ - return platform_driver_register(&gpio_fan_driver); -} - -static void __exit gpio_fan_exit(void) -{ - platform_driver_unregister(&gpio_fan_driver); -} - -module_init(gpio_fan_init); -module_exit(gpio_fan_exit); +module_platform_driver(gpio_fan_driver); MODULE_AUTHOR("Simon Guinot "); MODULE_DESCRIPTION("GPIO FAN driver"); -- cgit