diff --git a/arch/xtensa/Kconfig b/arch/xtensa/Kconfig index 042a9bfbade..77cfbef977d 100644 --- a/arch/xtensa/Kconfig +++ b/arch/xtensa/Kconfig @@ -34,6 +34,7 @@ config XTENSA_OMIT_HIGH_INTERRUPTS config XTENSA_ASM2 bool "New-style Xtensa context switch & interrupt layer" select USE_SWITCH + select USE_SWITCH_SUPPORTED help This selects a new implementation of context switching and interrupt handling. Advantages are a much lower interrupt diff --git a/kernel/Kconfig b/kernel/Kconfig index 96bc4a68ac3..33643673ebf 100644 --- a/kernel/Kconfig +++ b/kernel/Kconfig @@ -650,8 +650,10 @@ config MAX_DOMAIN_PARTITIONS Configure the maximum number of partitions per memory domain. menu "SMP Options" + config USE_SWITCH bool "Use new-style _arch_switch instead of __swap" + depends on USE_SWITCH_SUPPORTED help The _arch_switch() API is a lower level context switching primitive than the original __swap mechanism. It is required @@ -660,6 +662,13 @@ config USE_SWITCH architecture provides both, _arch_switch incurs more somewhat overhead and may be slower. +config USE_SWITCH_SUPPORTED + bool + help + Indicates whether _arch_switch() API is supported by the + currently enabled platform. This option should be selected by + platforms that implement it. + config SMP bool "Enable symmetric multithreading support" depends on USE_SWITCH