qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Filip Navara <filip.navara@gmail.com>
To: qemu-devel <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH] alsa: fix warning
Date: Wed, 17 Jun 2009 13:01:26 +0200	[thread overview]
Message-ID: <5b31733c0906170401o2ea04c46oe6f6e68d90945104@mail.gmail.com> (raw)
In-Reply-To: <5b31733c0906170400n63a2b45ekc14ebb7db05dbf65@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1497 bytes --]

On Wed, Jun 17, 2009 at 12:47 PM, Gerd Hoffmann <kraxel@redhat.com> wrote:

>
> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
> ---
>  audio/alsaaudio.c |    6 ++----
>  1 files changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/audio/alsaaudio.c b/audio/alsaaudio.c
> index 2f6c764..f0752bc 100644
> --- a/audio/alsaaudio.c
> +++ b/audio/alsaaudio.c
> @@ -626,8 +626,7 @@ static int alsa_init_out (HWVoiceOut *hw, struct
> audsettings *as)
>     req.period_size = conf.period_size_out;
>     req.buffer_size = conf.buffer_size_out;
>     req.size_in_usec = conf.size_in_usec_out;
> -    req.override_mask = !!conf.period_size_out_overridden
> -        | (!!conf.buffer_size_out_overridden << 1);
> +    req.override_mask = conf.period_size_out_overridden ? 0x03 : 0x00;


I'm all for fixing warnings, but this changes the
functionality, buffer_size_out_overridden != period_size_out_overridden. I
don't think that was the intent, otherwise please state so in the patch
description.


>
>
>     if (alsa_open (0, &req, &obt, &handle)) {
>         return -1;
> @@ -706,8 +705,7 @@ static int alsa_init_in (HWVoiceIn *hw, struct
> audsettings *as)
>     req.period_size = conf.period_size_in;
>     req.buffer_size = conf.buffer_size_in;
>     req.size_in_usec = conf.size_in_usec_in;
> -    req.override_mask = !!conf.period_size_in_overridden
> -        | (!!conf.buffer_size_in_overridden << 1);
> +    req.override_mask = conf.period_size_in_overridden ? 0x03 : 0x00;


Same here.

F.

[-- Attachment #2: Type: text/html, Size: 2217 bytes --]

      parent reply	other threads:[~2009-06-17 11:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-06-17 10:47 [Qemu-devel] [PATCH] alsa: fix warning Gerd Hoffmann
     [not found] ` <5b31733c0906170400n63a2b45ekc14ebb7db05dbf65@mail.gmail.com>
2009-06-17 11:01   ` Filip Navara [this message]

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=5b31733c0906170401o2ea04c46oe6f6e68d90945104@mail.gmail.com \
    --to=filip.navara@gmail.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).