[alsa-devel] [PATCH] ALSA: ASoC: support more sample rates on raumfeld devices

Daniel Mack daniel at caiaq.de
Wed Jan 13 16:43:20 CET 2010

On Wed, Jan 13, 2010 at 01:02:09PM +0000, Mark Brown wrote:
> On Wed, Jan 13, 2010 at 11:25:38AM +0100, Daniel Mack wrote:
> > Add support for sample rates other than 44100Khz on raumfeld audio
> > devices. Force the codec's supported sample rates as the table of
> > supported rates which is calculated at run-time does not suffice: if we
> > call snd_soc_dai_set_sysclk() at stream startup, half of the possible
> > rates are missing.
> I'm not massively enthusiastic about this - 

Me neither, and I agree to your objections.

> I'd much rather be able to
> give the CODEC a hook to let it know what MCLK rates it can have and a
> callback to update them.  It's a perfect case for the clock API but of
> course we can't use that off-SoC :/

I thought about this too and disliked it as well. It would make the
codec be in charge of dealing with clock changes, which is - in this
case particularily at least - not apropriate as the codec is slave to
all clocks.

For this application, the codec driver would need to be as dumb as
possible: I would just get the information about which MCLK and LRCLK it
runs with and it could reject invalid configurations by return value.
But that would imply major changes to the clocking logic in the cs4270
driver, which is fine as-is when it acts as master.

I'm uncertain and hence I just went the other way which bypasses this
logic for now, also not to break existing platforms.


More information about the Alsa-devel mailing list