At Tue, 8 Nov 2011 17:16:33 +0800, Scott Jiang wrote:
Hi Takash,
commit bd5389278c96f585afcac4058420e4f3ac201d2a Author: Takashi Iwai tiwai@suse.de Date: Fri Aug 21 01:18:00 2009 +0200
pcm: workaround for avoiding automatic start in mmap mode In the normal mmap mode, the stream isn't started automatically even after the data >= start_threshold has been written. However, in the mmap-emulation mode, the stream is started because it uses snd_pcm_write_areas() internally. As a workaround for this inconsistency, start_threshold value is changed dynamically in sw_parmams and mmap_commit callbacks in mmap-emul plugin. Meanwhile, start_threshold for slave PCM is set to boundary so that only this plugin (or the one over it) can control the start of the stream. This will fix problems in some apps using pulse plugin in the mmap mode. Signed-off-by: Takashi Iwai <tiwai@suse.de>
src/pcm/pcm_mmap_emul.c
This commit caused codec using mmap-emul plugin can't work. My config file list below:
bfin-ad1836.pcm.default { @args [ CARD ] @args.CARD { type string } type plug slave.pcm { type mmap_emul slave.pcm { type hw card $CARD format S32_LE rate 48000 } } }
Alsa will not send SNDRV_PCM_IOCTL_START to driver.
And how are you testing it? The whole background is missing...
Takashi