[alsa-devel] Improvements on aloop driver

Takashi Iwai tiwai at suse.de
Wed Dec 10 14:56:37 CET 2008


Hi,

as some people have asked about aloop bugs and developments, I started
working on it a bit.  The fact is that aloop is buggy per design in
two points:
 - Sharing the same buffer for both playback and capture doesn't
   work.  The playback app may change the "available" buffer area
   at any time.  It can update the last played period very quickly.
   OTOH, the capture needs to read the last period.  So, it obviously
   conflicts.
 - We needs to synchronize both playback and capture streams.  In the
   current implementation, both streams are updated individually.
   For example, the capture can start in the middle of the playback
   period.  This results in the partial available samples.

So, I wrote the code and got almost another shape of the driver.  The
result is found in my alsa-driver-build git tree
  git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/alsa-driver-build.git

and the snapshot tarball
  ftp://ftp.kernel.org/pub/linux/kernel/people/tiwai/snapshot/alsa-driver-snapshot.tar.gz

Let me know whether this works for you.  Once after confirmed to work
well enough, we should push this to the upstream -- or abandon if the
driver is conceptually wrong...


thanks,

Takashi


More information about the Alsa-devel mailing list