Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
* capture problem with maestro2
@ 2005-03-04 17:26 Michael
  0 siblings, 0 replies; only message in thread
From: Michael @ 2005-03-04 17:26 UTC (permalink / raw)
  To: alsa-devel

Hi

I have a capture problem with ALSA on a 2.6.10 kernel with a maestro2 
soundcard. Teamspeak doesn't work and i get this line in my teamspeak 
log file:

04-03-05 12:14:33,11835,ERROR,All,TOSSioThread.execute,Exception 
EOSSException: OSS error in InputSound: Invalid argument


I examined the problem and found out that with the following changes, 
everything works fine.

diff -rup sound/core/pcm_lib.c sound_new/core/pcm_lib.c
--- sound/core/pcm_lib.c        2005-03-04 12:14:00.951071880 +0100
+++ sound_new/core/pcm_lib.c    2005-03-04 12:23:19.734123944 +0100
@@ -2561,8 +2561,6 @@ snd_pcm_sframes_t snd_pcm_lib_read(snd_p
                }
        }
 #endif
-       if (runtime->access != SNDRV_PCM_ACCESS_RW_INTERLEAVED)
-               return -EINVAL;
        return snd_pcm_lib_read1(substream, (unsigned long)buf, size, 
nonblock, snd_pcm_lib_read_transfer);
 }


The function "snd_pcm_lib_read" gets called from the oss-emulation 
layer. But since the maestro2 only supports non-interleaved capture it 
returns EINVAL. Suprisingly, if the check for 
"SNDRV_PCM_ACCESS_RW_INTERLEAVED" is removed,  mono and stereo recording 
works! I don't know why.
Maybe someone with more ALSA insight could take a look at it and find a 
cleaner solution.




-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2005-03-04 17:26 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-04 17:26 capture problem with maestro2 Michael

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox