parisc: add u16 support to cmpxchg()
authorAl Viro <viro@zeniv.linux.org.uk>
Tue, 2 Apr 2024 03:13:17 +0000 (23:13 -0400)
committerPaul E. McKenney <paulmck@kernel.org>
Wed, 10 Apr 2024 05:06:00 +0000 (22:06 -0700)
commitd428032b3524e8fc75cf0bcc86b409df8ddf532b
tree5de0ff2c6e63c7f7e7e4928b4695ea31603375ce
parentc57e5dccb06decf3cb6c272ab138c033727149b5
parisc: add u16 support to cmpxchg()

Add (and export) __cmpxchg_u16(), teach __cmpxchg() to use it.

And get rid of manual truncation down to u8, etc. in there - the
only reason for those is to avoid bogus warnings about constant
truncation from sparse, and those are easy to avoid by turning
that switch into conditional expression.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
arch/parisc/include/asm/cmpxchg.h
arch/parisc/kernel/parisc_ksyms.c
arch/parisc/lib/bitops.c