aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/spi
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2009-12-14 17:20:22 -0500
committerGrant Likely <grant.likely@secretlab.ca>2009-12-17 10:39:12 -0500
commitdb389b6143c895d23060179b14928f63d44285a2 (patch)
tree455cffefc259a833374be4ea4b7c4397efc75d69 /drivers/spi
parent8ae1c9248042c5122f9628282f41c363c9610dd7 (diff)
spidev: add proper section markers
The driver already uses __devexit_p() in the structure, but looks like actual __dev{init,exit} markings were forgotten. The spidev_spi driver also needs renaming to include a "_driver" suffix to avoid section mismatch warnings. Signed-off-by: Mike Frysinger <vapier@gentoo.org> Cc: David Brownell <david-b@pacbell.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'drivers/spi')
-rw-r--r--drivers/spi/spidev.c16
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
564static int spidev_probe(struct spi_device *spi) 564static 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
613static int spidev_remove(struct spi_device *spi) 613static 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
635static struct spi_driver spidev_spi = { 635static 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
680static void __exit spidev_exit(void) 680static 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}
686module_exit(spidev_exit); 686module_exit(spidev_exit);
687 687