On Sat, Aug 14, 2010 at 4:35 AM, Mark Brown <broonie@xxxxxxxxxxxxxxxxxxxxxxxxxxx> wrote: ..... > +static int wm8580_set_sysclk(struct snd_soc_dai *dai, int clk_id, > + unsigned int freq, int dir) > +{ > + struct snd_soc_codec *codec = dai->codec; > + struct wm8580_priv *wm8580 = snd_soc_codec_get_drvdata(codec); > + int sel, sel_mask, sel_shift; > + > + switch (dai->driver->id) { > + case WM8580_DAI_PAIFTX: should be WM8580_DAI_PAIFRX: Because, WM8580_DAI_PAIFTX --> Capture --> ADC. > + sel_mask = 0x3; > + sel_shift = 0; > + break; > + > + case WM8580_DAI_PAIFRX: --> TX should be WM8580_DAI_PAIFTX: Because, WM8580_DAI_PAIFRX --> Playback --> DAC. > + sel_mask = 0xc; > + sel_shift = 3; Shouldn't the shift be 2 ? .... > + /* We really should validate PLL settings but not yet */ > + wm8580->sysclk[dai->id] = freq; > + > + return snd_soc_update_bits(codec, WM8580_CLKSEL, sel, sel_mask); Seems the value and mask arguments are swapped ? Thanks, Claude _______________________________________________ Alsa-devel mailing list Alsa-devel@xxxxxxxxxxxxxxxx http://mailman.alsa-project.org/mailman/listinfo/alsa-devel