From: Eric Biggers <ebiggers@kernel.org>
To: linux-riscv@lists.infradead.org
Subject: arch/riscv doesn't support xchg() on bool
Date: Mon, 21 Oct 2019 13:40:27 -0700 [thread overview]
Message-ID: <20191021204026.GE122863@gmail.com> (raw)
Hi,
The kbuild test robot reported a build error on RISC-V in this patch:
https://patchwork.kernel.org/patch/11182389/
... because of the line:
if (!xchg(&mode->logged_impl_name, true)) {
where logged_impl_name is a 'bool'. The problem is that unlike most (or all?)
other kernel architectures, arch/riscv/ doesn't support xchg() on bytes.
See: arch/riscv/include/asm/cmpxchg.h
Is there any chance this could be implemented, to avoid this
architecture-specific quirk? Note, there's at least one other
place in the kernel that also uses xchg() on a bool.
- Eric
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
next reply other threads:[~2019-10-21 20:40 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-21 20:40 Eric Biggers [this message]
2019-10-22 1:23 ` arch/riscv doesn't support xchg() on bool Paul Walmsley
2019-10-22 1:45 ` Eric Biggers
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=20191021204026.GE122863@gmail.com \
--to=ebiggers@kernel.org \
--cc=linux-riscv@lists.infradead.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).