15 Mar
2012
15 Mar
'12
6:53 p.m.
On Thu, Mar 15, 2012 at 03:23:04PM +0530, Ramesh Babu wrote:
I need to make sure that all simultaneous playback and capture (across the all dai_links) needs to be of same frequency family. If the sampling frequency of a new request is different from ongoing playback/capture, then it needs to be rejected.
How do I handle it in machine driver?
Why do you need to do this in the machine driver? Such a constraint sounds like it's coming from one of the chips in the system rather than from the machine itself so it'd seem sensible for the chip itself to impose the constraint so that other machines don't need to replicate the code.
See wm8988 for an example of adding sample rate constraints, obviously you can change the criteria dynamically.