From mboxrd@z Thu Jan 1 00:00:00 1970 From: Takashi Iwai Subject: Re: Issue with Alsa and PulseAudio Date: Tue, 26 Aug 2008 17:32:16 +0200 Message-ID: References: Mime-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by alsa0.perex.cz (Postfix) with ESMTP id BB8A324368 for ; Tue, 26 Aug 2008 17:32:16 +0200 (CEST) In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: alsa-devel-bounces@alsa-project.org Errors-To: alsa-devel-bounces@alsa-project.org To: Colin Guthrie Cc: alsa-devel@alsa-project.org, Ash List-Id: alsa-devel@alsa-project.org At Tue, 26 Aug 2008 16:21:13 +0100, Colin Guthrie wrote: > > Hi Ash, > > Ash wrote: > > Hello, I have a media application that uses alsa as its sound > > renderer. It has worked on numerous systems without any problems > > until I came across a mandriva distro that bundles with PulseAudio. > > The alsa pulseaudio plugin is installed correctly, however I am > > having weird problems. > > > > When I am setting up my hw params, and I call > > snd_pcm_hw_params_any(), I get an "Operation not permitted" error. I > > am not sure why this is happening, anyone else see this before? I am > > using pulseaudio version 0.9.9 and alsa 1.0.16. > > > > Thanks in advance! > > I'm the Mandriva PulseAudio maintainer. Most distros are now shipping PA > by default now so I doubt your problem will be specific to Mandriva :) > > However, I'm not expert enough in the ALSA API to know specifically what > snd_pcm_hw_params_any() actually does, but I'd imagine (this is just a > guess) that this is something that is either not implemented in the > IOPLUG system (on which the pulseaudio alsa plugin builds) or something > not implemented in the pulseaudio alsa plugin itself. > > Hopefully someone more versed in this can explain the reason why it > fails. :) There is no alsa-lib code that returns -EPERM by itself. Usually this error comes from the ioctl, but in this case, it must be from pulse plugin. And, pcm_pulse.c contains no EPERM, it must come from the pulseaudio itself. So, my rough guess is that PA is running by a different user (e.g. root) that doesn't allow you to connect it. Of course, first I'd do is to upgrade alsa-lib and alsa-plugins. 1.0.16 is fairly old. Takashi