mirror of
https://github.com/apache/nuttx.git
synced 2026-06-05 15:58:59 +08:00
arch/spinlock: implement the default test-and-set semantics
use the default testset implement on single core platform that does not support test-and-set, more flexibility for SMP drivers(using spinlock) if configured in a single-core mode. Signed-off-by: chao.an <anchao@xiaomi.com>
This commit is contained in:
+1
-1
@@ -232,7 +232,6 @@ menu "Tasks and Scheduling"
|
||||
config SPINLOCK
|
||||
bool "Support Spinlocks"
|
||||
default n
|
||||
depends on ARCH_HAVE_TESTSET
|
||||
---help---
|
||||
Enables support for spinlocks. Spinlocks are used primarily for
|
||||
synchronization in SMP configurations but are available for general
|
||||
@@ -275,6 +274,7 @@ config SMP
|
||||
bool "Symmetric Multi-Processing (SMP)"
|
||||
default n
|
||||
depends on ARCH_HAVE_MULTICPU
|
||||
depends on ARCH_HAVE_TESTSET
|
||||
select SPINLOCK
|
||||
select SCHED_RESUMESCHEDULER
|
||||
select IRQCOUNT
|
||||
|
||||
Reference in New Issue
Block a user