diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2008-12-03 14:58:17 -0500 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2008-12-09 05:49:28 -0500 |
commit | 958e792c7c8f06a9e666adb0ed94fff2cf90156f (patch) | |
tree | 2acc96b83738a593cb19551101583046000ff275 /sound/soc/fsl | |
parent | 12a48a8c0087ba39d926cf1d63938ccbdb9752c3 (diff) |
ASoC: Register platform drivers
This is done at modprobe time, mirroring current behaviour, except for
mpc5200_psc_i2s where we do registration at the same time as we register
with soc-of-simple. Since the core currently ignores registration this
has no practical impact.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/fsl')
-rw-r--r-- | sound/soc/fsl/fsl_dma.c | 12 | ||||
-rw-r--r-- | sound/soc/fsl/mpc5200_psc_i2s.c | 4 |
2 files changed, 16 insertions, 0 deletions
diff --git a/sound/soc/fsl/fsl_dma.c b/sound/soc/fsl/fsl_dma.c index bf92331b4768..646c807163ab 100644 --- a/sound/soc/fsl/fsl_dma.c +++ b/sound/soc/fsl/fsl_dma.c | |||
@@ -853,6 +853,18 @@ int fsl_dma_configure(struct fsl_dma_info *dma_info) | |||
853 | } | 853 | } |
854 | EXPORT_SYMBOL_GPL(fsl_dma_configure); | 854 | EXPORT_SYMBOL_GPL(fsl_dma_configure); |
855 | 855 | ||
856 | static int __devinit fsl_soc_platform_init(void) | ||
857 | { | ||
858 | return snd_soc_register_platform(&fsl_soc_platform); | ||
859 | } | ||
860 | module_init(fsl_soc_platform_init); | ||
861 | |||
862 | static void __exit fsl_soc_platform_exit(void) | ||
863 | { | ||
864 | snd_soc_unregister_platform(&fsl_soc_platform); | ||
865 | } | ||
866 | module_exit(fsl_soc_platform_exit); | ||
867 | |||
856 | MODULE_AUTHOR("Timur Tabi <timur@freescale.com>"); | 868 | MODULE_AUTHOR("Timur Tabi <timur@freescale.com>"); |
857 | MODULE_DESCRIPTION("Freescale Elo DMA ASoC PCM module"); | 869 | MODULE_DESCRIPTION("Freescale Elo DMA ASoC PCM module"); |
858 | MODULE_LICENSE("GPL"); | 870 | MODULE_LICENSE("GPL"); |
diff --git a/sound/soc/fsl/mpc5200_psc_i2s.c b/sound/soc/fsl/mpc5200_psc_i2s.c index 9ad8f9a2d8e9..9eb1ce185bd0 100644 --- a/sound/soc/fsl/mpc5200_psc_i2s.c +++ b/sound/soc/fsl/mpc5200_psc_i2s.c | |||
@@ -828,6 +828,8 @@ static int __devinit psc_i2s_of_probe(struct of_device *op, | |||
828 | if (rc) | 828 | if (rc) |
829 | dev_info(psc_i2s->dev, "error creating sysfs files\n"); | 829 | dev_info(psc_i2s->dev, "error creating sysfs files\n"); |
830 | 830 | ||
831 | snd_soc_register_platform(&psc_i2s_pcm_soc_platform); | ||
832 | |||
831 | /* Tell the ASoC OF helpers about it */ | 833 | /* Tell the ASoC OF helpers about it */ |
832 | of_snd_soc_register_platform(&psc_i2s_pcm_soc_platform, op->node, | 834 | of_snd_soc_register_platform(&psc_i2s_pcm_soc_platform, op->node, |
833 | &psc_i2s->dai); | 835 | &psc_i2s->dai); |
@@ -841,6 +843,8 @@ static int __devexit psc_i2s_of_remove(struct of_device *op) | |||
841 | 843 | ||
842 | dev_dbg(&op->dev, "psc_i2s_remove()\n"); | 844 | dev_dbg(&op->dev, "psc_i2s_remove()\n"); |
843 | 845 | ||
846 | snd_soc_unregister_platform(&psc_i2s_pcm_soc_platform); | ||
847 | |||
844 | bcom_gen_bd_rx_release(psc_i2s->capture.bcom_task); | 848 | bcom_gen_bd_rx_release(psc_i2s->capture.bcom_task); |
845 | bcom_gen_bd_tx_release(psc_i2s->playback.bcom_task); | 849 | bcom_gen_bd_tx_release(psc_i2s->playback.bcom_task); |
846 | 850 | ||