Skip to content

Commit

Permalink
ASoC: omap-mcbsp: Check mcbsp->id instead of cpu_dai->id when adding …
Browse files Browse the repository at this point in the history
…ST controls

In ddevice tree booted kernel all device have unique name and their device
id is set to 0.
Use the mcbsp->id for checking to decide which control set we should add
for McBSP sidetone handling.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Jarkko Nikula <jarkko.nikula@bitmer.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
  • Loading branch information
Peter Ujfalusi authored and Mark Brown committed Aug 25, 2012
1 parent eda21d3 commit 28739df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sound/soc/omap/omap-mcbsp.c
Original file line number Diff line number Diff line change
Expand Up @@ -722,7 +722,7 @@ int omap_mcbsp_st_add_controls(struct snd_soc_pcm_runtime *rtd)
if (!mcbsp->st_data)
return -ENODEV;

switch (cpu_dai->id) {
switch (mcbsp->id) {
case 2: /* McBSP 2 */
return snd_soc_add_dai_controls(cpu_dai,
omap_mcbsp2_st_controls,
Expand Down

0 comments on commit 28739df

Please sign in to comment.