aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPeter Ujfalusi <peter.ujfalusi@ti.com>2014-04-16 08:46:16 -0400
committerMark Brown <broonie@linaro.org>2014-04-18 13:00:35 -0400
commit64241425b8eaf46c971b6ba400c21f71979e6782 (patch)
tree3b77d480607f5d6e6ad1622cfc8a495d168fd1c1
parent3fe856b3127744ce30d4369ba760459b6ac9f820 (diff)
ASoC: omap-mcbsp: Bind the platform driver to the dai driver when loading
Use the same device for the platform driver when registering as the dai driver. This will enable us to clean up some DT booted cases. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Mark Brown <broonie@linaro.org>
-rw-r--r--sound/soc/omap/omap-mcbsp.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c
index 4525190d5599..af2764adf252 100644
--- a/sound/soc/omap/omap-mcbsp.c
+++ b/sound/soc/omap/omap-mcbsp.c
@@ -38,6 +38,7 @@
38#include <linux/platform_data/asoc-ti-mcbsp.h> 38#include <linux/platform_data/asoc-ti-mcbsp.h>
39#include "mcbsp.h" 39#include "mcbsp.h"
40#include "omap-mcbsp.h" 40#include "omap-mcbsp.h"
41#include "omap-pcm.h"
41 42
42#define OMAP_MCBSP_RATES (SNDRV_PCM_RATE_8000_96000) 43#define OMAP_MCBSP_RATES (SNDRV_PCM_RATE_8000_96000)
43 44
@@ -800,11 +801,15 @@ static int asoc_mcbsp_probe(struct platform_device *pdev)
800 platform_set_drvdata(pdev, mcbsp); 801 platform_set_drvdata(pdev, mcbsp);
801 802
802 ret = omap_mcbsp_init(pdev); 803 ret = omap_mcbsp_init(pdev);
803 if (!ret) 804 if (ret)
804 return snd_soc_register_component(&pdev->dev, &omap_mcbsp_component, 805 return ret;
805 &omap_mcbsp_dai, 1);
806 806
807 return ret; 807 ret = snd_soc_register_component(&pdev->dev, &omap_mcbsp_component,
808 &omap_mcbsp_dai, 1);
809 if (ret)
810 return ret;
811
812 return omap_pcm_platform_register(&pdev->dev);
808} 813}
809 814
810static int asoc_mcbsp_remove(struct platform_device *pdev) 815static int asoc_mcbsp_remove(struct platform_device *pdev)