All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: "Bedia, Vaibhav" <vaibhav.bedia@ti.com>
Cc: "alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
	"Afzal, Mohammed" <afzal@ti.com>,
	"lrg@slimlogic.co.uk" <lrg@slimlogic.co.uk>
Subject: Re: [RFC][PATCH] ASoC: Move symmetric rate check for substreams to hw_params
Date: Mon, 7 Mar 2011 15:00:57 +0000	[thread overview]
Message-ID: <20110307150057.GL13471@opensource.wolfsonmicro.com> (raw)
In-Reply-To: <FCCFB4CDC6E5564B9182F639FC3560870370843B37@dbde02.ent.ti.com>

On Mon, Mar 07, 2011 at 06:21:32PM +0530, Bedia, Vaibhav wrote:
> On Monday, March 07, 2011 5:39 PM, Mark Brown wrote:

> > This means that applications won't be constrained by the
> > current settings so can't automatically choose the required
> > rate.  ALSA is just fundamentally racy here, if you want to
> > reliably open bidirectional streams you need to serialise the
> > startup of the two directions.    

> When a custom application is written then the race condition can be avoided. 

> However right now a simple test like "arecord -f dat | aplay -f dat" fails. One way to make it work
> is to make sure that a call to arecord/aplay (or some dummy app which just sets some valid rate and returns) 
> has been made before both are invoked simultaneously.

For command line testing you can do something like:

  arecord -f dat | (sleep 1; aplay -f dat -) 

to insert a delay if required.  Obviously not all systems will hit the
race.

      reply	other threads:[~2011-03-07 15:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-07 11:56 [RFC][PATCH] ASoC: Move symmetric rate check for substreams to hw_params Vaibhav Bedia
2011-03-07 12:09 ` Mark Brown
2011-03-07 12:51   ` Bedia, Vaibhav
2011-03-07 15:00     ` Mark Brown [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110307150057.GL13471@opensource.wolfsonmicro.com \
    --to=broonie@opensource.wolfsonmicro.com \
    --cc=afzal@ti.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=lrg@slimlogic.co.uk \
    --cc=vaibhav.bedia@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.