diff options
Diffstat (limited to 'drivers/spi')
-rw-r--r-- | drivers/spi/spidev.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/spi/spidev.c b/drivers/spi/spidev.c index cb7147e0a573..f4a7a287b7f1 100644 --- a/drivers/spi/spidev.c +++ b/drivers/spi/spidev.c | |||
@@ -561,7 +561,7 @@ static struct class *spidev_class; | |||
561 | 561 | ||
562 | /*-------------------------------------------------------------------------*/ | 562 | /*-------------------------------------------------------------------------*/ |
563 | 563 | ||
564 | static int spidev_probe(struct spi_device *spi) | 564 | static int __devinit spidev_probe(struct spi_device *spi) |
565 | { | 565 | { |
566 | struct spidev_data *spidev; | 566 | struct spidev_data *spidev; |
567 | int status; | 567 | int status; |
@@ -610,7 +610,7 @@ static int spidev_probe(struct spi_device *spi) | |||
610 | return status; | 610 | return status; |
611 | } | 611 | } |
612 | 612 | ||
613 | static int spidev_remove(struct spi_device *spi) | 613 | static int __devexit spidev_remove(struct spi_device *spi) |
614 | { | 614 | { |
615 | struct spidev_data *spidev = spi_get_drvdata(spi); | 615 | struct spidev_data *spidev = spi_get_drvdata(spi); |
616 | 616 | ||
@@ -632,7 +632,7 @@ static int spidev_remove(struct spi_device *spi) | |||
632 | return 0; | 632 | return 0; |
633 | } | 633 | } |
634 | 634 | ||
635 | static struct spi_driver spidev_spi = { | 635 | static struct spi_driver spidev_spi_driver = { |
636 | .driver = { | 636 | .driver = { |
637 | .name = "spidev", | 637 | .name = "spidev", |
638 | .owner = THIS_MODULE, | 638 | .owner = THIS_MODULE, |
@@ -664,14 +664,14 @@ static int __init spidev_init(void) | |||
664 | 664 | ||
665 | spidev_class = class_create(THIS_MODULE, "spidev"); | 665 | spidev_class = class_create(THIS_MODULE, "spidev"); |
666 | if (IS_ERR(spidev_class)) { | 666 | if (IS_ERR(spidev_class)) { |
667 | unregister_chrdev(SPIDEV_MAJOR, spidev_spi.driver.name); | 667 | unregister_chrdev(SPIDEV_MAJOR, spidev_spi_driver.driver.name); |
668 | return PTR_ERR(spidev_class); | 668 | return PTR_ERR(spidev_class); |
669 | } | 669 | } |
670 | 670 | ||
671 | status = spi_register_driver(&spidev_spi); | 671 | status = spi_register_driver(&spidev_spi_driver); |
672 | if (status < 0) { | 672 | if (status < 0) { |
673 | class_destroy(spidev_class); | 673 | class_destroy(spidev_class); |
674 | unregister_chrdev(SPIDEV_MAJOR, spidev_spi.driver.name); | 674 | unregister_chrdev(SPIDEV_MAJOR, spidev_spi_driver.driver.name); |
675 | } | 675 | } |
676 | return status; | 676 | return status; |
677 | } | 677 | } |
@@ -679,9 +679,9 @@ module_init(spidev_init); | |||
679 | 679 | ||
680 | static void __exit spidev_exit(void) | 680 | static void __exit spidev_exit(void) |
681 | { | 681 | { |
682 | spi_unregister_driver(&spidev_spi); | 682 | spi_unregister_driver(&spidev_spi_driver); |
683 | class_destroy(spidev_class); | 683 | class_destroy(spidev_class); |
684 | unregister_chrdev(SPIDEV_MAJOR, spidev_spi.driver.name); | 684 | unregister_chrdev(SPIDEV_MAJOR, spidev_spi_driver.driver.name); |
685 | } | 685 | } |
686 | module_exit(spidev_exit); | 686 | module_exit(spidev_exit); |
687 | 687 | ||