1 # SPDX-License-Identifier: GPL-2.0-only 1 # SPDX-License-Identifier: GPL-2.0-only 2 # 2 # 3 # RCU-related debugging configuration options 3 # RCU-related debugging configuration options 4 # 4 # 5 5 6 menu "RCU Debugging" 6 menu "RCU Debugging" 7 7 8 config PROVE_RCU 8 config PROVE_RCU 9 def_bool PROVE_LOCKING 9 def_bool PROVE_LOCKING 10 10 11 config PROVE_RCU_LIST 11 config PROVE_RCU_LIST 12 bool "RCU list lockdep debugging" 12 bool "RCU list lockdep debugging" 13 depends on PROVE_RCU && RCU_EXPERT 13 depends on PROVE_RCU && RCU_EXPERT 14 default n 14 default n 15 help 15 help 16 Enable RCU lockdep checking for list 16 Enable RCU lockdep checking for list usages. By default it is 17 turned off since there are several l 17 turned off since there are several list RCU users that still 18 need to be converted to pass a lockd 18 need to be converted to pass a lockdep expression. To prevent 19 false-positive splats, we keep it de 19 false-positive splats, we keep it default disabled but once all 20 users are converted, we can remove t 20 users are converted, we can remove this config option. 21 21 22 config TORTURE_TEST 22 config TORTURE_TEST 23 tristate 23 tristate 24 default n 24 default n 25 25 26 config RCU_SCALE_TEST 26 config RCU_SCALE_TEST 27 tristate "performance tests for RCU" 27 tristate "performance tests for RCU" 28 depends on DEBUG_KERNEL 28 depends on DEBUG_KERNEL 29 select TORTURE_TEST 29 select TORTURE_TEST >> 30 select SRCU >> 31 select TASKS_RCU >> 32 select TASKS_RUDE_RCU >> 33 select TASKS_TRACE_RCU 30 default n 34 default n 31 help 35 help 32 This option provides a kernel module 36 This option provides a kernel module that runs performance 33 tests on the RCU infrastructure. Th 37 tests on the RCU infrastructure. The kernel module may be built 34 after the fact on the running kernel 38 after the fact on the running kernel to be tested, if desired. 35 39 36 Say Y here if you want RCU performan 40 Say Y here if you want RCU performance tests to be built into 37 the kernel. 41 the kernel. 38 Say M if you want the RCU performanc 42 Say M if you want the RCU performance tests to build as a module. 39 Say N if you are unsure. 43 Say N if you are unsure. 40 44 41 config RCU_TORTURE_TEST 45 config RCU_TORTURE_TEST 42 tristate "torture tests for RCU" 46 tristate "torture tests for RCU" 43 depends on DEBUG_KERNEL 47 depends on DEBUG_KERNEL 44 select TORTURE_TEST 48 select TORTURE_TEST >> 49 select SRCU >> 50 select TASKS_RCU >> 51 select TASKS_RUDE_RCU >> 52 select TASKS_TRACE_RCU 45 default n 53 default n 46 help 54 help 47 This option provides a kernel module 55 This option provides a kernel module that runs torture tests 48 on the RCU infrastructure. The kern 56 on the RCU infrastructure. The kernel module may be built 49 after the fact on the running kernel 57 after the fact on the running kernel to be tested, if desired. 50 58 51 Say Y here if you want RCU torture t 59 Say Y here if you want RCU torture tests to be built into 52 the kernel. 60 the kernel. 53 Say M if you want the RCU torture te 61 Say M if you want the RCU torture tests to build as a module. 54 Say N if you are unsure. 62 Say N if you are unsure. 55 63 56 config RCU_REF_SCALE_TEST 64 config RCU_REF_SCALE_TEST 57 tristate "Scalability tests for read-s 65 tristate "Scalability tests for read-side synchronization (RCU and others)" 58 depends on DEBUG_KERNEL 66 depends on DEBUG_KERNEL 59 select TORTURE_TEST 67 select TORTURE_TEST >> 68 select SRCU >> 69 select TASKS_RCU >> 70 select TASKS_RUDE_RCU >> 71 select TASKS_TRACE_RCU 60 default n 72 default n 61 help 73 help 62 This option provides a kernel module 74 This option provides a kernel module that runs performance tests 63 useful comparing RCU with various re 75 useful comparing RCU with various read-side synchronization mechanisms. 64 The kernel module may be built after 76 The kernel module may be built after the fact on the running kernel to be 65 tested, if desired. 77 tested, if desired. 66 78 67 Say Y here if you want these perform 79 Say Y here if you want these performance tests built into the kernel. 68 Say M if you want to build it as a m 80 Say M if you want to build it as a module instead. 69 Say N if you are unsure. 81 Say N if you are unsure. 70 82 71 config RCU_CPU_STALL_TIMEOUT 83 config RCU_CPU_STALL_TIMEOUT 72 int "RCU CPU stall timeout in seconds" 84 int "RCU CPU stall timeout in seconds" 73 depends on RCU_STALL_COMMON 85 depends on RCU_STALL_COMMON 74 range 3 300 86 range 3 300 75 default 21 87 default 21 76 help 88 help 77 If a given RCU grace period extends 89 If a given RCU grace period extends more than the specified 78 number of seconds, a CPU stall warni 90 number of seconds, a CPU stall warning is printed. If the 79 RCU grace period persists, additiona 91 RCU grace period persists, additional CPU stall warnings are 80 printed at more widely spaced interv 92 printed at more widely spaced intervals. 81 93 82 config RCU_EXP_CPU_STALL_TIMEOUT << 83 int "Expedited RCU CPU stall timeout i << 84 depends on RCU_STALL_COMMON << 85 range 0 300000 << 86 default 0 << 87 help << 88 If a given expedited RCU grace perio << 89 specified number of milliseconds, a << 90 If the RCU grace period persists, ad << 91 are printed at more widely spaced in << 92 says to use the RCU_CPU_STALL_TIMEOU << 93 seconds to milliseconds. << 94 << 95 config RCU_CPU_STALL_CPUTIME << 96 bool "Provide additional RCU stall deb << 97 depends on RCU_STALL_COMMON << 98 default n << 99 help << 100 Collect statistics during the sampli << 101 (hard interrupts, soft interrupts, t << 102 (hard interrupts, soft interrupts, k << 103 RCU stall report. For multiple conti << 104 periods begin at half of the first R << 105 The boot option rcupdate.rcu_cpu_sta << 106 as this one, but will override this << 107 << 108 config RCU_CPU_STALL_NOTIFIER << 109 bool "Provide RCU CPU-stall notifiers" << 110 depends on RCU_STALL_COMMON << 111 depends on DEBUG_KERNEL << 112 depends on RCU_EXPERT << 113 default n << 114 help << 115 WARNING: You almost certainly do no << 116 << 117 Enable RCU CPU-stall notifiers, whic << 118 printing the RCU CPU stall warning. << 119 callbacks can prevent stall warnings << 120 And the whole reason that a stall wa << 121 that something is hung up somewhere. << 122 callbacks must be written extremely << 123 containing only lockless code. Afte << 124 that the whole reason that the RCU C << 125 the first place is that someone forg << 126 that you are thinking of acquiring. << 127 notifier callback acquire that lock << 128 RCU CPU stall warning from appearing << 129 << 130 Say Y here if you want RCU CPU stall << 131 Say N if you are unsure. << 132 << 133 config RCU_TRACE 94 config RCU_TRACE 134 bool "Enable tracing for RCU" 95 bool "Enable tracing for RCU" 135 depends on DEBUG_KERNEL 96 depends on DEBUG_KERNEL 136 default y if TREE_RCU 97 default y if TREE_RCU 137 select TRACE_CLOCK 98 select TRACE_CLOCK 138 help 99 help 139 This option enables additional trace 100 This option enables additional tracepoints for ftrace-style 140 event tracing. 101 event tracing. 141 102 142 Say Y here if you want to enable RCU 103 Say Y here if you want to enable RCU tracing 143 Say N if you are unsure. 104 Say N if you are unsure. 144 105 145 config RCU_EQS_DEBUG 106 config RCU_EQS_DEBUG 146 bool "Provide debugging asserts for ad 107 bool "Provide debugging asserts for adding NO_HZ support to an arch" 147 depends on DEBUG_KERNEL 108 depends on DEBUG_KERNEL 148 help 109 help 149 This option provides consistency che 110 This option provides consistency checks in RCU's handling of 150 NO_HZ. These checks have proven qui 111 NO_HZ. These checks have proven quite helpful in detecting 151 bugs in arch-specific NO_HZ code. 112 bugs in arch-specific NO_HZ code. 152 113 153 Say N here if you need ultimate kern 114 Say N here if you need ultimate kernel/user switch latencies 154 Say Y if you are unsure 115 Say Y if you are unsure 155 116 156 config RCU_STRICT_GRACE_PERIOD 117 config RCU_STRICT_GRACE_PERIOD 157 bool "Provide debug RCU implementation 118 bool "Provide debug RCU implementation with short grace periods" 158 depends on DEBUG_KERNEL && RCU_EXPERT !! 119 depends on DEBUG_KERNEL && RCU_EXPERT && NR_CPUS <= 4 159 default n 120 default n 160 select PREEMPT_COUNT if PREEMPT=n 121 select PREEMPT_COUNT if PREEMPT=n 161 help 122 help 162 Select this option to build an RCU v 123 Select this option to build an RCU variant that is strict about 163 grace periods, making them as short 124 grace periods, making them as short as it can. This limits 164 scalability, destroys real-time resp 125 scalability, destroys real-time response, degrades battery 165 lifetime and kills performance. Don 126 lifetime and kills performance. Don't try this on large 166 machines, as in systems with more th 127 machines, as in systems with more than about 10 or 20 CPUs. 167 But in conjunction with tools like K 128 But in conjunction with tools like KASAN, it can be helpful 168 when looking for certain types of RC 129 when looking for certain types of RCU usage bugs, for example, 169 too-short RCU read-side critical sec 130 too-short RCU read-side critical sections. 170 131 171 endmenu # "RCU Debugging" 132 endmenu # "RCU Debugging"
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.