]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
spi: fix platform driver hotplug/coldplug
authorKay Sievers <kay.sievers@vrfy.org>
Fri, 11 Apr 2008 04:29:20 +0000 (21:29 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 11 Apr 2008 15:06:43 +0000 (08:06 -0700)
Since 43cc71eed1250755986da4c0f9898f9a635cb3bf, the platform modalias is
prefixed with "platform:".  Add MODULE_ALIAS() to the hotpluggable SPI
platform drivers, to allow module auto loading.

[dbrownell@users.sourceforge.net: more drivers: registration fixes]
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
14 files changed:
drivers/spi/atmel_spi.c
drivers/spi/au1550_spi.c
drivers/spi/mpc52xx_psc_spi.c
drivers/spi/omap2_mcspi.c
drivers/spi/omap_uwire.c
drivers/spi/pxa2xx_spi.c
drivers/spi/spi_bfin5xx.c
drivers/spi/spi_imx.c
drivers/spi/spi_mpc83xx.c
drivers/spi/spi_s3c24xx.c
drivers/spi/spi_s3c24xx_gpio.c
drivers/spi/spi_sh_sci.c
drivers/spi/spi_txx9.c
drivers/spi/xilinx_spi.c

index 85687aaf9cabf5876381d647764613a13a9aab9e..1749a27be0669f71670ec38f0670e1bf537588f4 100644 (file)
@@ -863,3 +863,4 @@ module_exit(atmel_spi_exit);
 MODULE_DESCRIPTION("Atmel AT32/AT91 SPI Controller driver");
 MODULE_AUTHOR("Haavard Skinnemoen <hskinnemoen@atmel.com>");
 MODULE_LICENSE("GPL");
+MODULE_ALIAS("platform:atmel_spi");
index 41a3d00c45156f27d9c59c1663f02c95f4993265..072c4a595334dd41de5ed7d7ec2f9bc85d6817b4 100644 (file)
@@ -958,6 +958,9 @@ static int __exit au1550_spi_remove(struct platform_device *pdev)
        return 0;
 }
 
+/* work with hotplug and coldplug */
+MODULE_ALIAS("platform:au1550-spi");
+
 static struct platform_driver au1550_spi_drv = {
        .remove = __exit_p(au1550_spi_remove),
        .driver = {
index a86315a0c5b8e93c90c70edac02fd6734cf62bbb..90729469d481dced3ae3e70d1c284df22e385acf 100644 (file)
@@ -500,6 +500,9 @@ static int __exit mpc52xx_psc_spi_remove(struct platform_device *dev)
        return mpc52xx_psc_spi_do_remove(&dev->dev);
 }
 
+/* work with hotplug and coldplug */
+MODULE_ALIAS("platform:mpc52xx-psc-spi");
+
 static struct platform_driver mpc52xx_psc_spi_platform_driver = {
        .remove = __exit_p(mpc52xx_psc_spi_remove),
        .driver = {
index a6ba11afb03f798bb7f8520c352b419ff6bb119d..b1cc148036c1e378ef870c0fa30f614f2a92745a 100644 (file)
@@ -1084,6 +1084,9 @@ static int __exit omap2_mcspi_remove(struct platform_device *pdev)
        return 0;
 }
 
+/* work with hotplug and coldplug */
+MODULE_ALIAS("platform:omap2_mcspi");
+
 static struct platform_driver omap2_mcspi_driver = {
        .driver = {
                .name =         "omap2_mcspi",
index 8245b5153f30957e9e12d705b25ced31b03fbed5..5f00bd6500efa2f8c51203c892f3d75bc1c9eb0e 100644 (file)
@@ -537,10 +537,12 @@ static int __exit uwire_remove(struct platform_device *pdev)
        return status;
 }
 
+/* work with hotplug and coldplug */
+MODULE_ALIAS("platform:omap_uwire");
+
 static struct platform_driver uwire_driver = {
        .driver = {
                .name           = "omap_uwire",
-               .bus            = &platform_bus_type,
                .owner          = THIS_MODULE,
        },
        .remove         = __exit_p(uwire_remove),
index 59deed79e0ab9e9da5db9781a869ca4c90b9f1ff..147e26a78d648c5d343454de8fca05f200faccac 100644 (file)
@@ -44,6 +44,7 @@
 MODULE_AUTHOR("Stephen Street");
 MODULE_DESCRIPTION("PXA2xx SSP SPI Controller");
 MODULE_LICENSE("GPL");
+MODULE_ALIAS("platform:pxa2xx-spi");
 
 #define MAX_BUSES 3
 
@@ -1581,7 +1582,6 @@ static int pxa2xx_spi_resume(struct platform_device *pdev)
 static struct platform_driver driver = {
        .driver = {
                .name = "pxa2xx-spi",
-               .bus = &platform_bus_type,
                .owner = THIS_MODULE,
        },
        .remove = pxa2xx_spi_remove,
index 6635e15e5a7acf0c7a27465ad662f274162b1494..a9ac1fdb30948c5eba8ff864d0ee156d8db7e247 100644 (file)
@@ -1396,7 +1396,7 @@ static int bfin5xx_spi_resume(struct platform_device *pdev)
 #define bfin5xx_spi_resume NULL
 #endif                         /* CONFIG_PM */
 
-MODULE_ALIAS("bfin-spi-master");       /* for platform bus hotplug */
+MODULE_ALIAS("platform:bfin-spi");
 static struct platform_driver bfin5xx_spi_driver = {
        .driver = {
                .name   = DRV_NAME,
index 1b0647124933cc473ef532e3a59265f6f2dd6a2c..d4ba640366b6c0039682bf24921e7736b76425d8 100644 (file)
@@ -1722,10 +1722,12 @@ static int spi_imx_resume(struct platform_device *pdev)
 #define spi_imx_resume NULL
 #endif /* CONFIG_PM */
 
+/* work with hotplug and coldplug */
+MODULE_ALIAS("platform:spi_imx");
+
 static struct platform_driver driver = {
        .driver = {
                .name = "spi_imx",
-               .bus = &platform_bus_type,
                .owner = THIS_MODULE,
        },
        .remove = __exit_p(spi_imx_remove),
index 04f7cd9fc26175258300486086626e24f26b158d..be15a6213205c09b9c840b6ea726607b3e052e18 100644 (file)
@@ -523,11 +523,12 @@ static int __exit mpc83xx_spi_remove(struct platform_device *dev)
        return 0;
 }
 
-MODULE_ALIAS("mpc83xx_spi");                   /* for platform bus hotplug */
+MODULE_ALIAS("platform:mpc83xx_spi");
 static struct platform_driver mpc83xx_spi_driver = {
        .remove = __exit_p(mpc83xx_spi_remove),
        .driver = {
-                  .name = "mpc83xx_spi",
+               .name = "mpc83xx_spi",
+               .owner = THIS_MODULE,
        },
 };
 
index 6e834b8b9d2785f51427cd11d3a051e9e9471b03..e75103aac79054706920dabe78301c790c083e3d 100644 (file)
@@ -415,7 +415,7 @@ static int s3c24xx_spi_resume(struct platform_device *pdev)
 #define s3c24xx_spi_resume  NULL
 #endif
 
-MODULE_ALIAS("s3c2410_spi");                   /* for platform bus hotplug */
+MODULE_ALIAS("platform:s3c2410-spi");
 static struct platform_driver s3c24xx_spidrv = {
        .remove         = __exit_p(s3c24xx_spi_remove),
        .suspend        = s3c24xx_spi_suspend,
index 82ae7d7eca386bafffa0c7ee7eb8b4c1388630dc..e33f6145c56065781b0673f746094172689daad9 100644 (file)
@@ -168,6 +168,8 @@ static int s3c2410_spigpio_remove(struct platform_device *dev)
 #define s3c2410_spigpio_suspend NULL
 #define s3c2410_spigpio_resume NULL
 
+/* work with hotplug and coldplug */
+MODULE_ALIAS("platform:spi_s3c24xx_gpio");
 
 static struct platform_driver s3c2410_spigpio_drv = {
        .probe          = s3c2410_spigpio_probe,
index 3dbe71b16d60935912d11697db67cd9b0551e5c4..7d36720eb98299858878c777ffe09b74d6641a96 100644 (file)
@@ -203,3 +203,4 @@ module_exit(sh_sci_spi_exit);
 MODULE_DESCRIPTION("SH SCI SPI Driver");
 MODULE_AUTHOR("Magnus Damm <damm@opensource.se>");
 MODULE_LICENSE("GPL");
+MODULE_ALIAS("platform:spi_sh_sci");
index 363ac8e6882106074478ae74b48cb8383440b770..2296f37ea3c636613a20dc422285093d02ddf52a 100644 (file)
@@ -450,6 +450,9 @@ static int __exit txx9spi_remove(struct platform_device *dev)
        return 0;
 }
 
+/* work with hotplug and coldplug */
+MODULE_ALIAS("platform:spi_txx9");
+
 static struct platform_driver txx9spi_driver = {
        .remove = __exit_p(txx9spi_remove),
        .driver = {
index 5d04f520c12323067e810047afe0aa0e740d1851..cf6aef34fe2595353335875197b671a823d59e3b 100644 (file)
@@ -408,6 +408,9 @@ static int __devexit xilinx_spi_remove(struct platform_device *dev)
        return 0;
 }
 
+/* work with hotplug and coldplug */
+MODULE_ALIAS("platform:" XILINX_SPI_NAME);
+
 static struct platform_driver xilinx_spi_driver = {
        .probe  = xilinx_spi_probe,
        .remove = __devexit_p(xilinx_spi_remove),