From: Takashi Iwai Subject: Re: pcm_multi poll timeout error Date: Fri, 09 Dec 2005 12:40:05 +0100 Message-ID: References: Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Return-path: In-Reply-To: Sender: alsa-devel-admin@lists.sourceforge.net Errors-To: alsa-devel-admin@lists.sourceforge.net List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , List-Archive: To: John Rigg Cc: alsa-devel@lists.sourceforge.net List-Id: alsa-devel@alsa-project.org At Thu, 08 Dec 2005 19:13:40 +0000, John Rigg wrote: > > On Sat, Dec 03, 2005 at 03:23:18PM +0000, John Rigg wrote: > > The pcm_multi plugin doesn't work currently with jackd in duplex mode. > > It's OK for either capture or playback with multi cards, but a poll time out > > occurs in duplex mode. Several users have experienced this problem with > > multiple ice1712 and RME cards. > > After some testing I found the following: > > > > alsa-lib-1.0.8 works > > alsa-lib-1.0.9rc1 onwards gives poll time out > > I got my two Delta 1010s working with jackd and pcm_multi in duplex mode by > removing three functions that were added in pcm_multi.c rev 1.89: > snd_pcm_multi_link_fd_failed() > snd_pcm_multi_link_fd() > snd_pcm_multi_unlink() > along with two associated members of snd_pcm_multi_fast_ops structure: > .link_fd = snd_pcm_multi_link_fd > .unlink = snd_pcm_multi_unlink > > I then started trying to debug the code causing the problem. Adding extra > printf's showed that none of the extra functions executed unless jackd was > started with both -C and -P devices (ie. duplex), and then only > snd_pcm_multi_link_fd(). This executed twice (once for capture and once for > playback presumably). Neither of the two other new functions was used when the > poll time out occurred. > > Unfortunately I'm now getting a little out of my depth. I've been studying the > docs and the source code, but the source is a little sparse on comments and > hard to follow for someone of my limited programming experience. > Does anyone have any pointers for a dumb sound engineer/musician trying to > understand what this extra linking code in pcm_multi.c is supposed to be doing? The link_fd returns the file descriptor for linking multiple PCM streams. If you comment it out, it means that no link is possible. It means that snd_pcm_link() didn't do anything in fact after your patch. The recent version of multi plugin returns only one pollfd of the master, and this seems breaking the stuff in JACK. And, I think checking only the master is a bad solution. Takashi ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_id=7637&alloc_id=16865&op=click