CONFIG_SWAP_NONATOMIC

(No prompt – not directly user assignable.)

Type: bool

Help

On some architectures, the _Swap() primitive cannot be made atomic with respect to the irq_lock being released. That is, interrupts may be received between the entry to _Swap and the completion of the context switch. There are a handful of workaround cases in the kernel that need to be enabled when this is true. Currently, this only happens on ARM when the PendSV exception priority sits below that of Zephyr-handled interrupts.

Defaults

No defaults. Implicitly defaults to n.

Symbols that select this symbol

Kconfig definition

At <Zephyr>/kernel/Kconfig:526

Included via <Zephyr>/Kconfig:8<Zephyr>/Kconfig.zephyr:30

Menu path: (Top) → General Kernel Options

config SWAP_NONATOMIC
    bool
    help
      On some architectures, the _Swap() primitive cannot be made
      atomic with respect to the irq_lock being released.  That
      is, interrupts may be received between the entry to _Swap
      and the completion of the context switch.  There are a
      handful of workaround cases in the kernel that need to be
      enabled when this is true.  Currently, this only happens on
      ARM when the PendSV exception priority sits below that of
      Zephyr-handled interrupts.

(The ‘depends on’ condition includes propagated dependencies from ifs and menus.)