From: Thomas Huth <thuth@redhat.com>
To: Andrew Jones <drjones@redhat.com>, Bill Wendling <morbo@google.com>
Cc: kvm@vger.kernel.org, Nikos Nikoleris <nikos.nikoleris@arm.com>,
lvivier@redhat.com, frankja@linux.ibm.com,
imbrenda@linux.ibm.com, david@redhat.com, pbonzini@redhat.com,
kvmarm@lists.cs.columbia.edu, kvm-ppc@vger.kernel.org,
linux-s390@vger.kernel.org, alexandru.elisei@arm.com,
suzuki.poulose@arm.com, mark.rutland@arm.com
Subject: Re: [kvm-unit-tests PATCH] libfdt: use logical "or" instead of bitwise "or" with boolean operands
Date: Tue, 22 Mar 2022 13:44:36 +0000 [thread overview]
Message-ID: <da339883-fc3a-da42-a071-d6e6c9f88b3e@redhat.com> (raw)
In-Reply-To: <20220318093601.zqhuzrp2ujgswsiw@gator>
On 18/03/2022 10.36, Andrew Jones wrote:
> On Tue, Mar 15, 2022 at 11:02:14PM -0700, Bill Wendling wrote:
>> Clang warns about using a bitwise '|' with boolean operands. This seems
>> to be due to a small typo.
>>
>> lib/libfdt/fdt_rw.c:438:6: warning: use of bitwise '|' with boolean operands [-Werror,-Wbitwise-instead-of-logical]
>> if (can_assume(LIBFDT_ORDER) |
>>
>> Using '||' removes this warnings.
>>
>> Signed-off-by: Bill Wendling <morbo@google.com>
>> ---
>> lib/libfdt/fdt_rw.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/lib/libfdt/fdt_rw.c b/lib/libfdt/fdt_rw.c
>> index 13854253ff86..3320e5559cac 100644
>> --- a/lib/libfdt/fdt_rw.c
>> +++ b/lib/libfdt/fdt_rw.c
>> @@ -435,7 +435,7 @@ int fdt_open_into(const void *fdt, void *buf, int bufsize)
>> return struct_size;
>> }
>>
>> - if (can_assume(LIBFDT_ORDER) |
>> + if (can_assume(LIBFDT_ORDER) ||
>> !fdt_blocks_misordered_(fdt, mem_rsv_size, struct_size)) {
>> /* no further work necessary */
>> err = fdt_move(fdt, buf, bufsize);
>> --
>> 2.35.1.723.g4982287a31-goog
>>
>
> We're not getting as much interest in the submodule discussion as I hoped.
> I see one vote against on this thread and one vote for on a different
> thread[1]. For now I'll just commit a big rebase patch for libfdt. We can
> revisit it again after we decide what to do for QCBOR.
I recently learnt that there are indeed people who ship kvm-unit-tests with
their distro - at least buildroot has a package:
https://git.busybox.net/buildroot/tree/package/kvm-unit-tests
So one more argument for copying the files over instead of using submodules:
The tarballs for tags will be self-contained, e.g.:
https://gitlab.com/kvm-unit-tests/kvm-unit-tests/-/archive/v2022-03-08/kvm-unit-tests-v2022-03-08.tar.gz
If we use submodules, I guess the content of the submodule content will be
missing in there?
Thomas
prev parent reply other threads:[~2022-03-22 13:44 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20220316060214.2200695-1-morbo@google.com>
2022-03-16 7:43 ` [kvm-unit-tests PATCH] libfdt: use logical "or" instead of bitwise "or" with boolean operands Andrew Jones
2022-03-16 7:53 ` Thomas Huth
2022-03-16 18:49 ` Bill Wendling
2022-03-18 9:36 ` Andrew Jones
2022-03-18 13:41 ` Andrew Jones
2022-03-22 13:44 ` Thomas Huth [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=da339883-fc3a-da42-a071-d6e6c9f88b3e@redhat.com \
--to=thuth@redhat.com \
--cc=alexandru.elisei@arm.com \
--cc=david@redhat.com \
--cc=drjones@redhat.com \
--cc=frankja@linux.ibm.com \
--cc=imbrenda@linux.ibm.com \
--cc=kvm-ppc@vger.kernel.org \
--cc=kvm@vger.kernel.org \
--cc=kvmarm@lists.cs.columbia.edu \
--cc=linux-s390@vger.kernel.org \
--cc=lvivier@redhat.com \
--cc=mark.rutland@arm.com \
--cc=morbo@google.com \
--cc=nikos.nikoleris@arm.com \
--cc=pbonzini@redhat.com \
--cc=suzuki.poulose@arm.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 read-only IMAP folder(s) and NNTP newsgroup(s).