diff options
author | Axel Lin <axel.lin@gmail.com> | 2011-11-28 11:38:39 +0800 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-11-28 11:49:13 +0000 |
commit | 005d610f2abc550172726b997f5cfe683769cc1c (patch) | |
tree | 50803d17eed521814c0e2d2bd892d29260ec946e /drivers/regulator/userspace-consumer.c | |
parent | a5228d2e5ea02c90581d5957cb6c4c73c191298f (diff) | |
download | op-kernel-dev-005d610f2abc550172726b997f5cfe683769cc1c.zip op-kernel-dev-005d610f2abc550172726b997f5cfe683769cc1c.tar.gz |
regulator: Convert virtual and userspace regulator consumer drivers to use module_platform_driver()
This patch converts virtual and userspace regulator consumer drivers to use the
module_platform_driver() macro which makes the code smaller and a bit simpler.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'drivers/regulator/userspace-consumer.c')
-rw-r--r-- | drivers/regulator/userspace-consumer.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/drivers/regulator/userspace-consumer.c b/drivers/regulator/userspace-consumer.c index fc66551..518667e 100644 --- a/drivers/regulator/userspace-consumer.c +++ b/drivers/regulator/userspace-consumer.c @@ -185,18 +185,7 @@ static struct platform_driver regulator_userspace_consumer_driver = { }, }; - -static int __init regulator_userspace_consumer_init(void) -{ - return platform_driver_register(®ulator_userspace_consumer_driver); -} -module_init(regulator_userspace_consumer_init); - -static void __exit regulator_userspace_consumer_exit(void) -{ - platform_driver_unregister(®ulator_userspace_consumer_driver); -} -module_exit(regulator_userspace_consumer_exit); +module_platform_driver(regulator_userspace_consumer_driver); MODULE_AUTHOR("Mike Rapoport <mike@compulab.co.il>"); MODULE_DESCRIPTION("Userspace consumer for voltage and current regulators"); |