linux/include/asm-generic
Mark Rutland d0e03218ca locking/atomic: atomic: simplify ifdeffery
Now that asm-generic/atomic.h is only used by architectures without any
architecture-specific atomic definitions, we know that there will be no
architecture-specific implementations to override, and can remove the
ifdeffery this has previously required, bringing it into line with
asm-generic/atomic64.h.

At the same time, we can implement atomic_add() and atomic_sub()
directly using ATOMIC_OP(), since we know architectures won't provide
atomic_add_return() or atomic_sub_return().

There should be no functional change as a result of this patch.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Boqun Feng <boqun.feng@gmail.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Will Deacon <will@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/r/20210525140232.53872-9-mark.rutland@arm.com
2021-05-26 13:20:50 +02:00
..
2017-11-15 13:28:48 -08:00
2021-04-08 16:04:20 -07:00
2021-05-07 00:26:34 -07:00
2021-02-24 16:32:23 -08:00
2020-01-23 10:41:16 -08:00
2021-01-20 09:30:45 +01:00
2018-03-09 23:19:56 +01:00
2018-05-07 07:15:41 +02:00
2021-04-08 16:04:20 -07:00