aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2/mcbsp.c
diff options
context:
space:
mode:
authorPeter Ujfalusi <peter.ujfalusi@ti.com>2012-02-14 11:20:58 -0500
committerLiam Girdwood <lrg@ti.com>2012-03-12 09:34:19 -0400
commit45656b44f6d1968d838f3abcf3a264ee9fa2fc62 (patch)
treeaf489389d8565bdd83f756115239524814b902d9 /arch/arm/mach-omap2/mcbsp.c
parent219f43164e8c611c6b8e7b628def9183098b430b (diff)
ASoC: omap-mcbsp: Create a single driver for McBSP
The OMAP McBSP driver stack used to contain two different drivers. One of them was used as kind low-level access to the IP, while the other driver was the ASoC DAI driver. There were global, shared structures, in different places, the McBSP instances are reffered with id numbers (sometimes 0 based, in other cases 1 based id numbers). Create one single driver for OMAP McBSP with name: omap-mcbsp. Convert the old omap-mcbsp driver initially to be a library for the omap-mcbsp DAI driver. With this change we can get rid of all global variables, structures. Further cleanup is coming... Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Tested-by: Grazvydas Ignotas <notasas@gmail.com> Tested-by: Janusz Krzysztofik <jkrzyszt@tis.icnet.pl> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: Liam Girdwood <lrg@ti.com>
Diffstat (limited to 'arch/arm/mach-omap2/mcbsp.c')
-rw-r--r--arch/arm/mach-omap2/mcbsp.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/arch/arm/mach-omap2/mcbsp.c b/arch/arm/mach-omap2/mcbsp.c
index b36d443a6fd9..49ff5b80454f 100644
--- a/arch/arm/mach-omap2/mcbsp.c
+++ b/arch/arm/mach-omap2/mcbsp.c
@@ -180,7 +180,6 @@ static int omap_init_mcbsp(struct omap_hwmod *oh, void *unused)
180 name, oh->name); 180 name, oh->name);
181 return PTR_ERR(pdev); 181 return PTR_ERR(pdev);
182 } 182 }
183 omap_mcbsp_count++;
184 return 0; 183 return 0;
185} 184}
186 185
@@ -188,11 +187,6 @@ static int __init omap2_mcbsp_init(void)
188{ 187{
189 omap_hwmod_for_each_by_class("mcbsp", omap_init_mcbsp, NULL); 188 omap_hwmod_for_each_by_class("mcbsp", omap_init_mcbsp, NULL);
190 189
191 mcbsp_ptr = kzalloc(omap_mcbsp_count * sizeof(struct omap_mcbsp *),
192 GFP_KERNEL);
193 if (!mcbsp_ptr)
194 return -ENOMEM;
195
196 return 0; 190 return 0;
197} 191}
198arch_initcall(omap2_mcbsp_init); 192arch_initcall(omap2_mcbsp_init);