aboutsummaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorGravatar Yann E. MORIN <yann.morin.1998@free.fr>2014-08-17 21:29:40 +0200
committerGravatar Peter Korsgaard <peter@korsgaard.com>2014-08-18 10:56:35 +0200
commit1b5f0fc8dfdad74649d4e12737c83e727e116535 (patch)
treefddfd5b45691f77c7539e743efbab0cf43d90742 /arch
parent2289c34a193174967a87b432b56527cf82e0b3c2 (diff)
downloadbuildroot-1b5f0fc8dfdad74649d4e12737c83e727e116535.tar.gz
buildroot-1b5f0fc8dfdad74649d4e12737c83e727e116535.tar.bz2
arch: add an option to specify if the arch has atomic ops
The fact that atomic operations are available is not really a specificity of the toolchain, but rather of the architecture. So, add a new option that architectures that have atomic operations can select. This in turn selects the current toolchain atomic option, until all packages have been converted, at which point the old toolchain option can be removed. Reported-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Anton Kolesov <Anton.Kolesov@synopsys.com> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/Config.in6
-rw-r--r--arch/Config.in.arc2
2 files changed, 7 insertions, 1 deletions
diff --git a/arch/Config.in b/arch/Config.in
index 9cd85a589a..5cee0d7839 100644
--- a/arch/Config.in
+++ b/arch/Config.in
@@ -250,6 +250,12 @@ config BR2_GCC_TARGET_FLOAT_ABI
config BR2_GCC_TARGET_MODE
string
+# If the architecture has atomic operations, select this:
+config BR2_ARCH_HAS_ATOMICS
+ bool
+ default y if !BR2_arc
+ select BR2_TOOLCHAIN_HAS_ATOMIC_INTRINSICS
+
# Set up target binary format
choice
prompt "Target Binary Format"
diff --git a/arch/Config.in.arc b/arch/Config.in.arc
index 836cfef638..8a7f290f52 100644
--- a/arch/Config.in.arc
+++ b/arch/Config.in.arc
@@ -1,7 +1,7 @@
# Choise of atomic instructions presence
config BR2_ARC_ATOMIC_EXT
bool "Atomic extension (LLOCK/SCOND instructions)"
- select BR2_TOOLCHAIN_HAS_ATOMIC_INTRINSICS
+ select BR2_ARCH_HAS_ATOMICS
config BR2_ARCH
default "arc" if BR2_arcle