Re: [PATCHv2 04/16] atomics/treewide: make atomic_fetch_add_unless() optional

2018-06-04 Thread Palmer Dabbelt
On Tue, 29 May 2018 08:43:34 PDT (-0700), mark.rutl...@arm.com wrote: Several architectures these have a near-identical implementation based on atomic_read() and atomic_cmpxchg() that we can instead define in , so let's do so, using something close to the existing x86 implementation with try_cmpx

[PATCHv2 04/16] atomics/treewide: make atomic_fetch_add_unless() optional

2018-05-29 Thread Mark Rutland
Several architectures these have a near-identical implementation based on atomic_read() and atomic_cmpxchg() that we can instead define in , so let's do so, using something close to the existing x86 implementation with try_cmpxchg(). Where an architecture provides its own atomic_fetch_add_unless()