Skip to content

Commit

Permalink
nuttx/arch: select ARCH_HAVE_TESTSET if ARCH_HAVE_CUSTOM_TESTSET is on
Browse files Browse the repository at this point in the history
the include/nuttx/spinlock.h#up_testset() function is also controlled by
ARCH_HAVE_TESTSET, so when ARCH_HAVE_CUSTOM_TESTSET is selected by
boards, the include/nuttx/spinlock.h#up_testset() should also not be
build, and using the board specific implementation.
So in this case, if Option ARCH_HAVE_CUSTOM_TESTSET is enabled,
it is assumed that Option ARCH_HAVE_TESTSET is also enabled.
However, when Option ARCH_HAVE_TESTSET is enabled, it doesn't necessarily
mean that Option ARCH_HAVE_CUSTOM_TESTSET is also enabled.
In this way, it can be ensured that the implementation under the
include/nuttx/spinlock.h#up_testset can also be controlled by
Option ARCH_HAVE_CUSTOM_TESTSET.

Signed-off-by: guoshichao <guoshichao@xiaomi.com>
  • Loading branch information
extinguish committed Dec 24, 2024
1 parent 1e6a5ca commit 9d9110d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions arch/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -487,6 +487,7 @@ config ARCH_HAVE_TESTSET
config ARCH_HAVE_CUSTOM_TESTSET
bool
default n
select ARCH_HAVE_TESTSET

config ARCH_HAVE_THREAD_LOCAL
bool
Expand Down

0 comments on commit 9d9110d

Please sign in to comment.