From: "Philippe Mathieu-Daudé" <philmd@redhat.com>
To: Thomas Huth <thuth@redhat.com>,
qemu-s390x@nongnu.org, Cornelia Huck <cohuck@redhat.com>,
Christian Borntraeger <borntraeger@de.ibm.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [PATCH] pc-bios/s390-ccw/bootmap: Silence compiler warning from Clang
Date: Wed, 21 Apr 2021 18:37:14 +0200 [thread overview]
Message-ID: <41029be3-5876-f766-b1f1-5e1684a46710@redhat.com> (raw)
In-Reply-To: <20210421163331.358178-1-thuth@redhat.com>
On 4/21/21 6:33 PM, Thomas Huth wrote:
> When compiling the s390-ccw bios with Clang, the compiler complains:
>
> pc-bios/s390-ccw/bootmap.c:302:9: warning: logical not is only applied
> to the left hand side of this comparison [-Wlogical-not-parentheses]
> if (!mbr->dev_type == DEV_TYPE_ECKD) {
> ^ ~~
>
> The code works (more or less by accident), since dev_type can only be
> 0 or 1, but it's better of course to use the intended != operator here
> instead.
>
> Fixes: 5dc739f343 ("Allow booting in case the first virtio-blk disk is bad")
> Signed-off-by: Thomas Huth <thuth@redhat.com>
> ---
> pc-bios/s390-ccw/bootmap.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
next prev parent reply other threads:[~2021-04-21 16:44 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-21 16:33 [PATCH] pc-bios/s390-ccw/bootmap: Silence compiler warning from Clang Thomas Huth
2021-04-21 16:37 ` Philippe Mathieu-Daudé [this message]
2021-04-21 16:37 ` Christian Borntraeger
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=41029be3-5876-f766-b1f1-5e1684a46710@redhat.com \
--to=philmd@redhat.com \
--cc=borntraeger@de.ibm.com \
--cc=cohuck@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-s390x@nongnu.org \
--cc=thuth@redhat.com \
/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).