All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Henningsson <david.henningsson@canonical.com>
To: Takashi Iwai <tiwai@suse.de>, alsa-devel@alsa-project.org
Subject: Re: [PATCH] pcm: route: Don't handle no matching chmap as a serious error
Date: Tue, 18 Mar 2014 17:19:29 +0100	[thread overview]
Message-ID: <53287211.1040803@canonical.com> (raw)
In-Reply-To: <1395152876-28480-1-git-send-email-tiwai@suse.de>

On 03/18/2014 03:27 PM, Takashi Iwai wrote:
> When find_matching_chmap() returns an error for the non-matching
> chmap, the caller, snd_pcm_route_open(), also returns an error
> although it shouldn't be handled as the fatal error.  This results in
> the probe error with PulseAudio and it gives no real output in the
> end.

Hmm, could you give a more specific example? In case the driver does not
support channel maps at all, that case is handled in the beginning of
the function.

So this only happens if the driver supports channel maps, but only
non-compatible with the requested map. In which case I believe it's
correct that the probing should fail...?

> 
> Signed-off-by: Takashi Iwai <tiwai@suse.de>
> ---
>  src/pcm/pcm_route.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/src/pcm/pcm_route.c b/src/pcm/pcm_route.c
> index ab17fa78be2c..ac11bdc8adfd 100644
> --- a/src/pcm/pcm_route.c
> +++ b/src/pcm/pcm_route.c
> @@ -940,10 +940,8 @@ static int find_matching_chmap(snd_pcm_t *spcm, snd_pcm_chmap_t *tt_chmap,
>  
>  	snd_pcm_free_chmaps(chmaps);
>  
> -	if (*found_chmap == NULL) {
> +	if (*found_chmap == NULL)
>  		SNDERR("Found no matching channel map");
> -		return -EINVAL;
> -	}
>  	return 0;
>  }
>  
> 



-- 
David Henningsson, Canonical Ltd.
https://launchpad.net/~diwic

  reply	other threads:[~2014-03-18 16:19 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-18 14:27 [PATCH] pcm: route: Don't handle no matching chmap as a serious error Takashi Iwai
2014-03-18 16:19 ` David Henningsson [this message]
2014-03-18 16:34   ` Takashi Iwai
2014-03-18 22:13     ` David Henningsson
2014-03-19  9:57       ` Takashi Iwai
2014-03-19 12:10         ` David Henningsson
2014-03-19 13:17           ` Takashi Iwai

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=53287211.1040803@canonical.com \
    --to=david.henningsson@canonical.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=tiwai@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.