aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hwmon/ultra45_env.c
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2011-02-22 22:01:33 -0500
committerGrant Likely <grant.likely@secretlab.ca>2011-02-28 03:36:39 -0500
commit4ebb24f707187196937607c60810d42f7112d7aa (patch)
tree89a92b3f8dd55f3c5e0cfa73fa6446b3d490f3a8 /drivers/hwmon/ultra45_env.c
parent000061245a6797d542854106463b6b20fbdcb12e (diff)
dt/sparc: Eliminate users of of_platform_{,un}register_driver
Get rid of old users of of_platform_driver in arch/sparc. Most of_platform_driver users can be converted to use the platform_bus directly. Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'drivers/hwmon/ultra45_env.c')
-rw-r--r--drivers/hwmon/ultra45_env.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/hwmon/ultra45_env.c b/drivers/hwmon/ultra45_env.c
index d863e13a50b8..1f36c635d933 100644
--- a/drivers/hwmon/ultra45_env.c
+++ b/drivers/hwmon/ultra45_env.c
@@ -234,8 +234,7 @@ static const struct attribute_group env_group = {
234 .attrs = env_attributes, 234 .attrs = env_attributes,
235}; 235};
236 236
237static int __devinit env_probe(struct platform_device *op, 237static int __devinit env_probe(struct platform_device *op)
238 const struct of_device_id *match)
239{ 238{
240 struct env *p = kzalloc(sizeof(*p), GFP_KERNEL); 239 struct env *p = kzalloc(sizeof(*p), GFP_KERNEL);
241 int err = -ENOMEM; 240 int err = -ENOMEM;
@@ -299,7 +298,7 @@ static const struct of_device_id env_match[] = {
299}; 298};
300MODULE_DEVICE_TABLE(of, env_match); 299MODULE_DEVICE_TABLE(of, env_match);
301 300
302static struct of_platform_driver env_driver = { 301static struct platform_driver env_driver = {
303 .driver = { 302 .driver = {
304 .name = "ultra45_env", 303 .name = "ultra45_env",
305 .owner = THIS_MODULE, 304 .owner = THIS_MODULE,
@@ -311,12 +310,12 @@ static struct of_platform_driver env_driver = {
311 310
312static int __init env_init(void) 311static int __init env_init(void)
313{ 312{
314 return of_register_platform_driver(&env_driver); 313 return platform_driver_register(&env_driver);
315} 314}
316 315
317static void __exit env_exit(void) 316static void __exit env_exit(void)
318{ 317{
319 of_unregister_platform_driver(&env_driver); 318 platform_driver_unregister(&env_driver);
320} 319}
321 320
322module_init(env_init); 321module_init(env_init);