* Re: [PATCH 3/3] MIPS: fix truncation in __cmpxchg_small for short values
[not found] <20190211043829.30096-4-michaeljclark@mac.com>
@ 2019-02-11 20:03 ` Paul Burton
0 siblings, 0 replies; only message in thread
From: Paul Burton @ 2019-02-11 20:03 UTC (permalink / raw)
To: Michael Clark
Cc: Linux RISC-V, Michael Clark, RISC-V Patches, Linux MIPS, linux-mips
Hello,
Michael Clark wrote:
> __cmpxchg_small erroneously uses u8 for load comparison which can
> be either char or short. This patch changes the local varialble to
> u32 which is sufficiently sized, as the loaded value is already
> masked and shifted appropriately. Using an integer size avoids
> any unnecessary canonicalization from use of non native widths.
>
> This patch is part of a series that adapts the MIPS small word
> atomics code for xchg and cmpxchg on short and char to RISC-V.
>
> Cc: RISC-V Patches <patches@groups.riscv.org>
> Cc: Linux RISC-V <linux-riscv@lists.infradead.org>
> Cc: Linux MIPS <linux-mips@linux-mips.org>
> Signed-off-by: Michael Clark <michaeljclark@mac.com>
Applied to mips-fixes.
Thanks,
Paul
[ This message was auto-generated; if you believe anything is incorrect
then please email paul.burton@mips.com to report it. ]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2019-02-11 20:03 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <20190211043829.30096-4-michaeljclark@mac.com>
2019-02-11 20:03 ` [PATCH 3/3] MIPS: fix truncation in __cmpxchg_small for short values Paul Burton
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).