aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/atomic.h
diff options
context:
space:
mode:
authorMark Rutland <mark.rutland@arm.com>2021-05-25 15:02:00 +0100
committerPeter Zijlstra <peterz@infradead.org>2021-05-26 13:20:49 +0200
commit9be85de97786a75f62080de1c0c13656f65cba84 (patch)
treefda5463211f1e92135081ba872293f7ebad868e4 /include/linux/atomic.h
parentfutex: Deduplicate cond_resched() invocation in futex_wake_op() (diff)
downloadlinux-dev-9be85de97786a75f62080de1c0c13656f65cba84.tar.xz
linux-dev-9be85de97786a75f62080de1c0c13656f65cba84.zip
locking/atomic: make ARCH_ATOMIC a Kconfig symbol
Subsequent patches will move architectures over to the ARCH_ATOMIC API, after preparing the asm-generic atomic implementations to function with or without ARCH_ATOMIC. As some architectures use the asm-generic implementations exclusively (and don't have a local atomic.h), and to avoid the risk that ARCH_ATOMIC isn't defined in some cases we expect, let's make the ARCH_ATOMIC macro a Kconfig symbol instead, so that we can guarantee it is consistently available where needed. There should be no functional change as a result of this patch. Signed-off-by: Mark Rutland <mark.rutland@arm.com> 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-2-mark.rutland@arm.com
Diffstat (limited to 'include/linux/atomic.h')
-rw-r--r--include/linux/atomic.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/atomic.h b/include/linux/atomic.h
index 571a11008ab5..4f8d83f9e480 100644
--- a/include/linux/atomic.h
+++ b/include/linux/atomic.h
@@ -77,7 +77,7 @@
__ret; \
})
-#ifdef ARCH_ATOMIC
+#ifdef CONFIG_ARCH_ATOMIC
#include <linux/atomic-arch-fallback.h>
#include <asm-generic/atomic-instrumented.h>
#else