diff options
Diffstat (limited to 'drivers/input/misc/sparcspkr.c')
-rw-r--r-- | drivers/input/misc/sparcspkr.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/drivers/input/misc/sparcspkr.c b/drivers/input/misc/sparcspkr.c index 1dacae4b43f0..f3bb92e9755f 100644 --- a/drivers/input/misc/sparcspkr.c +++ b/drivers/input/misc/sparcspkr.c | |||
@@ -353,14 +353,12 @@ static struct of_platform_driver grover_beep_driver = { | |||
353 | 353 | ||
354 | static int __init sparcspkr_init(void) | 354 | static int __init sparcspkr_init(void) |
355 | { | 355 | { |
356 | int err = of_register_driver(&bbc_beep_driver, | 356 | int err = of_register_platform_driver(&bbc_beep_driver); |
357 | &of_platform_bus_type); | ||
358 | 357 | ||
359 | if (!err) { | 358 | if (!err) { |
360 | err = of_register_driver(&grover_beep_driver, | 359 | err = of_register_platform_driver(&grover_beep_driver); |
361 | &of_platform_bus_type); | ||
362 | if (err) | 360 | if (err) |
363 | of_unregister_driver(&bbc_beep_driver); | 361 | of_unregister_platform_driver(&bbc_beep_driver); |
364 | } | 362 | } |
365 | 363 | ||
366 | return err; | 364 | return err; |
@@ -368,8 +366,8 @@ static int __init sparcspkr_init(void) | |||
368 | 366 | ||
369 | static void __exit sparcspkr_exit(void) | 367 | static void __exit sparcspkr_exit(void) |
370 | { | 368 | { |
371 | of_unregister_driver(&bbc_beep_driver); | 369 | of_unregister_platform_driver(&bbc_beep_driver); |
372 | of_unregister_driver(&grover_beep_driver); | 370 | of_unregister_platform_driver(&grover_beep_driver); |
373 | } | 371 | } |
374 | 372 | ||
375 | module_init(sparcspkr_init); | 373 | module_init(sparcspkr_init); |