qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Volker Rümelin" <vr_qemu@t-online.de>
To: marcandre.lureau@redhat.com, Gerd Hoffmann <kraxel@redhat.com>
Cc: dbassey@redhat.com, qemu-devel@nongnu.org
Subject: Re: [PATCH 10/12] audio/pw: simplify error reporting in stream creation
Date: Sun, 7 May 2023 17:33:04 +0200	[thread overview]
Message-ID: <ba44ad60-596c-71f2-f073-10b0bbd8211f@t-online.de> (raw)
In-Reply-To: <20230506163735.3481387-11-marcandre.lureau@redhat.com>

> From: Marc-André Lureau<marcandre.lureau@redhat.com>
>
> create_stream() now reports on all error paths.
>
> Signed-off-by: Marc-André Lureau<marcandre.lureau@redhat.com>
> ---
>   audio/pwaudio.c | 12 +-----------
>   1 file changed, 1 insertion(+), 11 deletions(-)

Reviewed-by: Volker Rümelin <vr_qemu@t-online.de>

> diff --git a/audio/pwaudio.c b/audio/pwaudio.c
> index 5c706a9fde..38905f5be2 100644
> --- a/audio/pwaudio.c
> +++ b/audio/pwaudio.c
> @@ -486,8 +486,6 @@ static int
>   qpw_stream_new(pwaudio *c, PWVoice *v, const char *stream_name,
>                  const char *name, enum spa_direction dir)
>   {
> -    int r;
> -
>       switch (v->info.channels) {
>       case 8:
>           v->info.position[0] = SPA_AUDIO_CHANNEL_FL;
> @@ -540,13 +538,7 @@ qpw_stream_new(pwaudio *c, PWVoice *v, const char *stream_name,
>       }
>   
>       /* create a new unconnected pwstream */
> -    r = create_stream(c, v, stream_name, name, dir);
> -    if (r < 0) {
> -        AUD_log(AUDIO_CAP, "Failed to create stream.");
> -        return -1;
> -    }
> -
> -    return r;
> +    return create_stream(c, v, stream_name, name, dir);
>   }
>   
>   static int
> @@ -577,7 +569,6 @@ qpw_init_out(HWVoiceOut *hw, struct audsettings *as, void *drv_opaque)
>       r = qpw_stream_new(c, v, ppdo->stream_name ? : c->dev->id,
>                          ppdo->name, SPA_DIRECTION_OUTPUT);
>       if (r < 0) {
> -        error_report("qpw_stream_new for playback failed");
>           pw_thread_loop_unlock(c->thread_loop);
>           return -1;
>       }
> @@ -621,7 +612,6 @@ qpw_init_in(HWVoiceIn *hw, struct audsettings *as, void *drv_opaque)
>       r = qpw_stream_new(c, v, ppdo->stream_name ? : c->dev->id,
>                          ppdo->name, SPA_DIRECTION_INPUT);
>       if (r < 0) {
> -        error_report("qpw_stream_new for recording failed");
>           pw_thread_loop_unlock(c->thread_loop);
>           return -1;
>       }



  reply	other threads:[~2023-05-07 15:33 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-06 16:37 [PATCH 00/12] audio: pipewire backend improvements marcandre.lureau
2023-05-06 16:37 ` [PATCH 01/12] libvirt-ci: update submodule to cover pipewire marcandre.lureau
2023-05-06 16:37 ` [PATCH 02/12] tests/lcitool: add pipewire marcandre.lureau
2023-05-10  7:35   ` Philippe Mathieu-Daudé
2023-05-06 16:37 ` [PATCH 03/12] audio/pw: Pipewire->PipeWire case fix for user-visible text marcandre.lureau
2023-05-07 14:56   ` Volker Rümelin
2023-05-10  7:36   ` Philippe Mathieu-Daudé
2023-05-06 16:37 ` [PATCH 04/12] audio/pw: drop needless case statement marcandre.lureau
2023-05-07 14:58   ` Volker Rümelin
2023-05-06 16:37 ` [PATCH 05/12] audio/pw: needless check for NULL marcandre.lureau
2023-05-07 15:01   ` Volker Rümelin
2023-05-06 16:37 ` [PATCH 06/12] audio/pw: trace during init before calling pipewire API marcandre.lureau
2023-05-07 15:03   ` Volker Rümelin
2023-05-10  7:37   ` Philippe Mathieu-Daudé
2023-05-06 16:37 ` [PATCH 07/12] audio/pw: add more details on error marcandre.lureau
2023-05-07 15:31   ` Volker Rümelin
2023-05-06 16:37 ` [PATCH 08/12] audio/pw: factorize some common code marcandre.lureau
2023-05-07 15:07   ` Volker Rümelin
2023-05-06 16:37 ` [PATCH 09/12] audio/pw: add more error reporting marcandre.lureau
2023-05-07 15:32   ` Volker Rümelin
2023-05-06 16:37 ` [PATCH 10/12] audio/pw: simplify error reporting in stream creation marcandre.lureau
2023-05-07 15:33   ` Volker Rümelin [this message]
2023-05-06 16:37 ` [PATCH 11/12] audio/pw: remove wrong comment marcandre.lureau
2023-05-07 15:11   ` Volker Rümelin
2023-05-06 16:37 ` [PATCH 12/12] audio/pw: improve channel position code marcandre.lureau
2023-05-07 15:13   ` Volker Rümelin

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=ba44ad60-596c-71f2-f073-10b0bbd8211f@t-online.de \
    --to=vr_qemu@t-online.de \
    --cc=dbassey@redhat.com \
    --cc=kraxel@redhat.com \
    --cc=marcandre.lureau@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).