Commit ba0a7e02 authored by Axel Lin's avatar Axel Lin Committed by Mark Brown

ASoC: Convert fsl directory to module_platform_driver

Factor out some boilerplate code.
Signed-off-by: default avatarAxel Lin <axel.lin@gmail.com>
Acked-by: default avatarTimur Tabi <timur@freescale.com>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent 6524c8e3
......@@ -992,20 +992,7 @@ static struct platform_driver fsl_soc_dma_driver = {
.remove = __devexit_p(fsl_soc_dma_remove),
};
static int __init fsl_soc_dma_init(void)
{
pr_info("Freescale Elo DMA ASoC PCM Driver\n");
return platform_driver_register(&fsl_soc_dma_driver);
}
static void __exit fsl_soc_dma_exit(void)
{
platform_driver_unregister(&fsl_soc_dma_driver);
}
module_init(fsl_soc_dma_init);
module_exit(fsl_soc_dma_exit);
module_platform_driver(fsl_soc_dma_driver);
MODULE_AUTHOR("Timur Tabi <timur@freescale.com>");
MODULE_DESCRIPTION("Freescale Elo DMA ASoC PCM Driver");
......
......@@ -793,20 +793,7 @@ static struct platform_driver fsl_ssi_driver = {
.remove = fsl_ssi_remove,
};
static int __init fsl_ssi_init(void)
{
printk(KERN_INFO "Freescale Synchronous Serial Interface (SSI) ASoC Driver\n");
return platform_driver_register(&fsl_ssi_driver);
}
static void __exit fsl_ssi_exit(void)
{
platform_driver_unregister(&fsl_ssi_driver);
}
module_init(fsl_ssi_init);
module_exit(fsl_ssi_exit);
module_platform_driver(fsl_ssi_driver);
MODULE_AUTHOR("Timur Tabi <timur@freescale.com>");
MODULE_DESCRIPTION("Freescale Synchronous Serial Interface (SSI) ASoC Driver");
......
......@@ -526,17 +526,7 @@ static struct platform_driver mpc5200_hpcd_of_driver = {
}
};
static int __init mpc5200_hpcd_init(void)
{
return platform_driver_register(&mpc5200_hpcd_of_driver);
}
module_init(mpc5200_hpcd_init);
static void __exit mpc5200_hpcd_exit(void)
{
platform_driver_unregister(&mpc5200_hpcd_of_driver);
}
module_exit(mpc5200_hpcd_exit);
module_platform_driver(mpc5200_hpcd_of_driver);
MODULE_AUTHOR("Grant Likely <grant.likely@secretlab.ca>");
MODULE_DESCRIPTION("Freescale MPC5200 PSC in DMA mode ASoC Driver");
......
......@@ -325,21 +325,7 @@ static struct platform_driver psc_ac97_driver = {
},
};
/* ---------------------------------------------------------------------
* Module setup and teardown; simply register the of_platform driver
* for the PSC in AC97 mode.
*/
static int __init psc_ac97_init(void)
{
return platform_driver_register(&psc_ac97_driver);
}
module_init(psc_ac97_init);
static void __exit psc_ac97_exit(void)
{
platform_driver_unregister(&psc_ac97_driver);
}
module_exit(psc_ac97_exit);
module_platform_driver(psc_ac97_driver);
MODULE_AUTHOR("Jon Smirl <jonsmirl@gmail.com>");
MODULE_DESCRIPTION("mpc5200 AC97 module");
......
......@@ -222,21 +222,7 @@ static struct platform_driver psc_i2s_driver = {
},
};
/* ---------------------------------------------------------------------
* Module setup and teardown; simply register the of_platform driver
* for the PSC in I2S mode.
*/
static int __init psc_i2s_init(void)
{
return platform_driver_register(&psc_i2s_driver);
}
module_init(psc_i2s_init);
static void __exit psc_i2s_exit(void)
{
platform_driver_unregister(&psc_i2s_driver);
}
module_exit(psc_i2s_exit);
module_platform_driver(psc_i2s_driver);
MODULE_AUTHOR("Grant Likely <grant.likely@secretlab.ca>");
MODULE_DESCRIPTION("Freescale MPC5200 PSC in I2S mode ASoC Driver");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment