RCU Subsystem
CONFIG_TREE_RCU
This option selects the RCU implementation that is designed for very large SMP system with hundreds or thousands of CPUs. It also scales down nicely to smaller systems.
- Selects
CONTEXT_TRACKING_IDLE
CONFIG_PREEMPT_RCU
This option selects the RCU implementation that is designed for very large SMP systems with hundreds or thousands of CPUs, but for which real-time response is also required. It also scales down nicely to smaller systems.
Select this option if you are unsure.
- Selects
TREE_RCU
CONFIG_TINY_RCU
This option selects the RCU implementation that is designed for UP systems from which real-time response is not required. This option greatly reduces the memory footprint of RCU.
CONFIG_RCU_EXPERT Make expert-level adjustments to RCU configuration
This option needs to be enabled if you wish to make expert-level adjustments to RCU configuration. By default, no such adjustments can be made, which has the often-beneficial side-effect of preventing "make oldconfig" from asking you all sorts of detailed questions about how you would like numerous obscure RCU options to be set up.
Say Y if you need to make expert-level adjustments to RCU.
Say N if you are unsure.
CONFIG_TINY_SRCU
This option selects the single-CPU non-preemptible version of SRCU.
CONFIG_TREE_SRCU
This option selects the full-fledged version of SRCU.
CONFIG_FORCE_NEED_SRCU_NMI_SAFE Force selection of NEED_SRCU_NMI_SAFE
This option forces selection of the NEED_SRCU_NMI_SAFE Kconfig option, allowing testing of srcu_read_lock_nmisafe() and srcu_read_unlock_nmisafe() on architectures (like x86) that select the ARCH_HAS_NMI_SAFE_THIS_CPU_OPS Kconfig option.
- Depends on
!TINY_SRCU && RCU_EXPERT && ARCH_HAS_NMI_SAFE_THIS_CPU_OPS - Selects
NEED_SRCU_NMI_SAFE if !TINY_SRCU && RCU_EXPERT && ARCH_HAS_NMI_SAFE_THIS_CPU_OPS
CONFIG_NEED_SRCU_NMI_SAFE
CONFIG_TASKS_RCU_GENERIC
This option enables generic infrastructure code supporting task-based RCU implementations. Not for manual selection.
CONFIG_FORCE_TASKS_RCU Force selection of TASKS_RCU
This option force-enables a task-based RCU implementation that uses only voluntary context switch (not preemption!), idle, and user-mode execution as quiescent states. Not for manual selection in most cases.
- Depends on
RCU_EXPERT - Selects
TASKS_RCU if RCU_EXPERT
CONFIG_NEED_TASKS_RCU
CONFIG_TASKS_RCU
- Selects
IRQ_WORK
CONFIG_FORCE_TASKS_RUDE_RCU Force selection of Tasks Rude RCU
This option force-enables a task-based RCU implementation that uses only context switch (including preemption) and user-mode execution as quiescent states. It forces IPIs and context switches on all online CPUs, including idle ones, so use with caution. Not for manual selection in most cases.
- Depends on
RCU_EXPERT - Selects
TASKS_RUDE_RCU if RCU_EXPERT
CONFIG_TASKS_RUDE_RCU
- Selects
IRQ_WORK
CONFIG_FORCE_TASKS_TRACE_RCU Force selection of Tasks Trace RCU
This option enables a task-based RCU implementation that uses explicit rcu_read_lock_trace() read-side markers, and allows these readers to appear in the idle loop as well as on the CPU hotplug code paths. It can force IPIs on online CPUs, including idle ones, so use with caution. Not for manual selection in most cases.
- Depends on
RCU_EXPERT - Selects
TASKS_TRACE_RCU if RCU_EXPERT
CONFIG_TASKS_TRACE_RCU
CONFIG_TASKS_TRACE_RCU_NO_MB Override RCU Tasks Trace inclusion of read-side memory barriers
This option prevents the use of read-side memory barriers in rcu_read_lock_tasks_trace() and rcu_read_unlock_tasks_trace() even in kernels built with CONFIG_ARCH_WANTS_NO_INSTR=n, that is, in kernels that do not have noinstr set up in entry/exit code. By setting this option, you are promising to carefully review use of ftrace, BPF, and friends to ensure that no tracing operation is attached to a function that runs in that portion of the entry/exit code that RCU does not watch, that is, where rcu_is_watching() returns false. Alternatively, you might choose to never remove traces except by rebooting.
Those wishing to disable read-side memory barriers for an entire architecture can select this Kconfig option, hence the polarity.
Say Y here if you need speed and will review use of tracing. Say N here for certain esoteric testing of RCU itself. Take the default if you are unsure.
- Depends on
RCU_EXPERT && TASKS_TRACE_RCU
CONFIG_RCU_STALL_COMMON
This option enables RCU CPU stall code that is common between the TINY and TREE variants of RCU. The purpose is to allow the tiny variants to disable RCU CPU stall warnings, while making these warnings mandatory for the tree variants.
CONFIG_RCU_NEED_SEGCBLIST
CONFIG_RCU_DEFER
- Selects
IRQ_WORK
CONFIG_RCU_FANOUT Tree-based hierarchical RCU fanout value
This option controls the fanout of hierarchical implementations of RCU, allowing RCU to work efficiently on machines with large numbers of CPUs. This value must be at least the fourth root of NR_CPUS, which allows NR_CPUS to be insanely large. The default value of RCU_FANOUT should be used for production systems, but if you are stress-testing the RCU implementation itself, small RCU_FANOUT values allow you to test large-system code paths on small(er) systems.
Select a specific number if testing RCU itself. Take the default if unsure.
- Depends on
TREE_RCU && RCU_EXPERT - Range
[2 64] if TREE_RCU && RCU_EXPERT && - Range
[2 32] if TREE_RCU && RCU_EXPERT && !
CONFIG_RCU_FANOUT_LEAF Tree-based hierarchical RCU leaf-level fanout value
This option controls the leaf-level fanout of hierarchical implementations of RCU, and allows trading off cache misses against lock contention. Systems that synchronize their scheduling-clock interrupts for energy-efficiency reasons will want the default because the smaller leaf-level fanout keeps lock contention levels acceptably low. Very large systems (hundreds or thousands of CPUs) will instead want to set this value to the maximum value possible in order to reduce the number of cache misses incurred during RCU's grace-period initialization. These systems tend to run CPU-bound, and thus are not helped by synchronized interrupts, and thus tend to skew them, which reduces lock contention enough that large leaf-level fanouts work well. That said, setting leaf-level fanout to a large number will likely cause problematic lock contention on the leaf-level rcu_node structures unless you boot with the skew_tick kernel parameter.
Select a specific number if testing RCU itself.
Select the maximum permissible value for large systems, but please understand that you may also need to set the skew_tick kernel boot parameter to avoid contention on the rcu_node structure's locks.
Take the default if unsure.
- Depends on
TREE_RCU && RCU_EXPERT - Range
[2 64] if TREE_RCU && RCU_EXPERT && && !RCU_STRICT_GRACE_PERIOD - Range
[2 32] if TREE_RCU && RCU_EXPERT && ! && !RCU_STRICT_GRACE_PERIOD - Range
[2 3] if TREE_RCU && RCU_EXPERT && RCU_STRICT_GRACE_PERIOD
CONFIG_RCU_BOOST Enable RCU priority boosting
This option boosts the priority of preempted RCU readers that block the current preemptible RCU grace period for too long. This option also prevents heavy loads from blocking RCU callback invocation.
Say Y here if you are working with real-time apps or heavy loads Say N here if you are unsure.
- Depends on
RT_MUTEXES && PREEMPT_RCU && RCU_EXPERT || PREEMPT_RT
If RCU_BOOST
CONFIG_RCU_BOOST_DELAY Milliseconds to delay boosting after RCU grace-period start
This option specifies the time to wait after the beginning of a given grace period before priority-boosting preempted RCU readers blocking that grace period. Note that any RCU reader blocking an expedited RCU grace period is boosted immediately.
Accept the default if unsure.
- Range
[0 3000] if RCU_BOOST
CONFIG_RCU_EXP_KTHREAD Perform RCU expedited work in a real-time kthread
Use this option to further reduce the latencies of expedited grace periods at the expense of being more disruptive.
This option is disabled by default on PREEMPT_RT=y kernels which disable expedited grace periods after boot by unconditionally setting rcupdate.rcu_normal_after_boot=1.
Accept the default if unsure.
- Depends on
RCU_BOOST && RCU_EXPERT
CONFIG_RCU_NOCB_CPU Offload RCU callback processing from boot-selected CPUs
Use this option to reduce OS jitter for aggressive HPC or real-time workloads. It can also be used to offload RCU callback invocation to energy-efficient CPUs in battery-powered asymmetric multiprocessors. The price of this reduced jitter is that the overhead of call_rcu() increases and that some workloads will incur significant increases in context-switch rates.
This option offloads callback invocation from the set of CPUs specified at boot time by the rcu_nocbs parameter. For each such CPU, a kthread ("rcuox/N") will be created to invoke callbacks, where the "N" is the CPU being offloaded, and where the "x" is "p" for RCU-preempt (PREEMPTION kernels) and "s" for RCU-sched (!PREEMPTION kernels). This option also creates another kthread for each sqrt(nr_cpu_ids) CPUs ("rcuog/N", where N is the first CPU in that group to come online), which handles grace periods for its group. Nothing prevents these kthreads from running on the specified CPUs, but (1) the kthreads may be preempted between each callback, and (2) affinity or cgroups can be used to force the kthreads to run on whatever set of CPUs is desired.
The sqrt(nr_cpu_ids) grouping may be overridden using the rcutree.rcu_nocb_gp_stride kernel boot parameter. This can be especially helpful for smaller numbers of CPUs, where sqrt(nr_cpu_ids) can be a bit of a blunt instrument.
Say Y here if you need reduced OS jitter, despite added overhead. Say N here if you are unsure.
- Depends on
TREE_RCU && (RCU_EXPERT || NO_HZ_FULL)
If RCU_NOCB_CPU
CONFIG_RCU_NOCB_CPU_DEFAULT_ALL Offload RCU callback processing from all CPUs by default
Use this option to offload callback processing from all CPUs by default, in the absence of the rcu_nocbs or nohz_full boot parameter. This also avoids the need to use any boot parameters to achieve the effect of offloading all CPUs on boot.
Say Y here if you want offload all CPUs by default on boot. Say N here if you are unsure.
CONFIG_RCU_NOCB_CPU_CB_BOOST Offload RCU callback from real-time kthread
Use this option to invoke offloaded callbacks as SCHED_FIFO to avoid starvation by heavy SCHED_OTHER background load. Of course, running as SCHED_FIFO during callback floods will cause the rcuo[ps] kthreads to monopolize the CPU for hundreds of milliseconds or more. Therefore, when enabling this option, it is your responsibility to ensure that latency-sensitive tasks either run with higher priority or run on some other CPU.
Say Y here if you want to set RT priority for offloading kthreads. Say N here if you are building a !PREEMPT_RT kernel and are unsure.
- Depends on
RCU_NOCB_CPU && RCU_BOOST
CONFIG_RCU_LAZY RCU callback lazy invocation functionality
To save power, batch RCU callbacks and delay starting the corresponding grace period for multiple seconds. The grace period will be started after this delay, in case of memory pressure, or if the corresponding CPU's callback list grows too large.
These delays happen only on rcu_nocbs CPUs, that is, CPUs whose callbacks have been offloaded.
Use the rcutree.enable_rcu_lazy=0 kernel-boot parameter to globally disable these delays.
If RCU_LAZY
CONFIG_RCU_LAZY_DEFAULT_OFF Turn RCU lazy invocation off by default
Build the kernel with CONFIG_RCU_LAZY=y, but cause the kernel to boot with these energy-efficiency delays disabled. Use the rcutree.enable_rcu_lazy=0 kernel-boot parameter to override the this option at boot time, thus re-enabling these delays.
CONFIG_RCU_DOUBLE_CHECK_CB_TIME RCU callback-batch backup time check
Use this option to provide more precise enforcement of the rcutree.rcu_resched_ns module parameter in situations where a single RCU callback might run for hundreds of microseconds, thus defeating the 32-callback batching used to amortize the cost of the fine-grained but expensive local_clock() function.
This option rounds rcutree.rcu_resched_ns up to the next jiffy, and overrides the 32-callback batching if this limit is exceeded.
Say Y here if you need tighter callback-limit enforcement. Say N here if you are unsure.
- Depends on
RCU_EXPERT
- arch/alpha/Kconfig:465
- arch/arc/Kconfig:167
- arch/arm/Kconfig:910
- arch/arm64/Kconfig:358
- arch/csky/Kconfig:313
- arch/hexagon/Kconfig:104
- arch/loongarch/Kconfig:513
- arch/mips/Kconfig:2700
- arch/openrisc/Kconfig:191
- arch/parisc/Kconfig:314
- arch/powerpc/platforms/Kconfig.cputype:550
- arch/riscv/Kconfig:437
- arch/s390/Kconfig:530
- arch/sh/Kconfig:560
- arch/sparc/Kconfig:158
- arch/um/Kconfig:97
- arch/x86/Kconfig:437
- arch/xtensa/Kconfig:245
- arch/alpha/Kconfig:484
- arch/arc/Kconfig:175
- arch/arm/Kconfig:1063
- arch/arm64/Kconfig:1702
- arch/csky/Kconfig:318
- arch/hexagon/Kconfig:109
- arch/loongarch/Kconfig:542
- arch/m68k/Kconfig.cpu:552
- arch/microblaze/Kconfig:123
- arch/mips/Kconfig:2756
- arch/nios2/Kconfig:72
- arch/openrisc/Kconfig:185
- arch/parisc/Kconfig:367
- arch/powerpc/platforms/Kconfig.cputype:570
- arch/riscv/Kconfig:450
- arch/s390/Kconfig:533
- arch/sh/Kconfig:582
- arch/sparc/Kconfig:180
- arch/um/Kconfig:132
- arch/x86/Kconfig:1037
- arch/xtensa/Kconfig:253