]> git.ipfire.org Git - thirdparty/linux.git/blame - kernel/time/Kconfig
Merge tag 'rtc-5.3' of git://git.kernel.org/pub/scm/linux/kernel/git/abelloni/linux
[thirdparty/linux.git] / kernel / time / Kconfig
CommitLineData
ec8f24b7 1# SPDX-License-Identifier: GPL-2.0-only
79bf2bb3
TG
2#
3# Timer subsystem related configuration options
4#
3872c48b 5
b5e498ad
TG
6# Options selectable by arch Kconfig
7
8# Watchdog function for clocksources to detect instabilities
9config CLOCKSOURCE_WATCHDOG
10 bool
11
12# Architecture has extra clocksource data
13config ARCH_CLOCKSOURCE_DATA
14 bool
15
d67f34c1
TG
16# Architecture has extra clocksource init called from registration
17config ARCH_CLOCKSOURCE_INIT
18 bool
19
09ec5442
TG
20# Clocksources require validation of the clocksource against the last
21# cycle update - x86/TSC misfeature
22config CLOCKSOURCE_VALIDATE_LAST_CYCLE
23 bool
24
576094b7
JS
25# Timekeeping vsyscall support
26config GENERIC_TIME_VSYSCALL
27 bool
28
b5e498ad
TG
29# Old style timekeeping
30config ARCH_USES_GETTIMEOFFSET
31 bool
32
33# The generic clock events infrastructure
34config GENERIC_CLOCKEVENTS
35 bool
36
12ad1000
MR
37# Architecture can handle broadcast in a driver-agnostic way
38config ARCH_HAS_TICK_BROADCAST
39 bool
40
b5e498ad
TG
41# Clockevents broadcasting infrastructure
42config GENERIC_CLOCKEVENTS_BROADCAST
43 bool
44 depends on GENERIC_CLOCKEVENTS
45
764e0da1
TG
46# Automatically adjust the min. reprogramming time for
47# clock event device
48config GENERIC_CLOCKEVENTS_MIN_ADJUST
49 bool
50
b5e498ad
TG
51# Generic update of CMOS clock
52config GENERIC_CMOS_UPDATE
53 bool
764e0da1
TG
54
55if GENERIC_CLOCKEVENTS
56menu "Timers subsystem"
57
3451d024 58# Core internal switch. Selected by NO_HZ_COMMON / HIGH_RES_TIMERS. This is
764e0da1 59# only related to the tick functionality. Oneshot clockevent devices
6082a6e4 60# are supported independent of this.
764e0da1
TG
61config TICK_ONESHOT
62 bool
63
3451d024
FW
64config NO_HZ_COMMON
65 bool
66 depends on !ARCH_USES_GETTIMEOFFSET && GENERIC_CLOCKEVENTS
67 select TICK_ONESHOT
68
3ca277e4
FW
69choice
70 prompt "Timer tick handling"
71 default NO_HZ_IDLE if NO_HZ
72
5b533f4f 73config HZ_PERIODIC
3ca277e4
FW
74 bool "Periodic timer ticks (constant rate, no dynticks)"
75 help
76 This option keeps the tick running periodically at a constant
77 rate, even when the CPU doesn't need it.
78
79config NO_HZ_IDLE
80 bool "Idle dynticks system (tickless idle)"
764e0da1 81 depends on !ARCH_USES_GETTIMEOFFSET && GENERIC_CLOCKEVENTS
3451d024 82 select NO_HZ_COMMON
764e0da1 83 help
3ca277e4
FW
84 This option enables a tickless idle system: timer interrupts
85 will only trigger on an as-needed basis when the system is idle.
86 This is usually interesting for energy saving.
87
88 Most of the time you want to say Y here.
764e0da1 89
c5bfece2 90config NO_HZ_FULL
fae30dd6 91 bool "Full dynticks system (tickless)"
3451d024 92 # NO_HZ_COMMON dependency
ab71d36d 93 depends on !ARCH_USES_GETTIMEOFFSET && GENERIC_CLOCKEVENTS
fae30dd6
FW
94 # We need at least one periodic CPU for timekeeping
95 depends on SMP
fae30dd6 96 depends on HAVE_CONTEXT_TRACKING
c58b0df1 97 # VIRT_CPU_ACCOUNTING_GEN dependency
554b0004 98 depends on HAVE_VIRT_CPU_ACCOUNTING_GEN
3451d024 99 select NO_HZ_COMMON
ab71d36d 100 select RCU_NOCB_CPU
c58b0df1 101 select VIRT_CPU_ACCOUNTING_GEN
76c24fb0 102 select IRQ_WORK
bf29cb23 103 select CPU_ISOLATION
ab71d36d
FW
104 help
105 Adaptively try to shutdown the tick whenever possible, even when
a831881b
FW
106 the CPU is running tasks. Typically this requires running a single
107 task on the CPU. Chances for running tickless are maximized when
108 the task mostly runs in userspace and has few kernel activity.
109
c5bfece2 110 You need to fill up the nohz_full boot parameter with the
a831881b
FW
111 desired range of dynticks CPUs.
112
113 This is implemented at the expense of some overhead in user <-> kernel
114 transitions: syscalls, exceptions and interrupts. Even when it's
115 dynamically off.
116
117 Say N.
118
3ca277e4
FW
119endchoice
120
a4cffdad
PM
121config CONTEXT_TRACKING
122 bool
123
124config CONTEXT_TRACKING_FORCE
125 bool "Force context tracking"
126 depends on CONTEXT_TRACKING
127 default y if !NO_HZ_FULL
128 help
129 The major pre-requirement for full dynticks to work is to
130 support the context tracking subsystem. But there are also
131 other dependencies to provide in order to make the full
132 dynticks working.
133
134 This option stands for testing when an arch implements the
135 context tracking backend but doesn't yet fullfill all the
136 requirements to make the full dynticks feature working.
137 Without the full dynticks, there is no way to test the support
138 for context tracking and the subsystems that rely on it: RCU
139 userspace extended quiescent state and tickless cputime
140 accounting. This option copes with the absence of the full
141 dynticks subsystem by forcing the context tracking on all
142 CPUs in the system.
143
144 Say Y only if you're working on the development of an
145 architecture backend for the context tracking.
146
147 Say N otherwise, this option brings an overhead that you
148 don't want in production.
149
0644ca5c
FW
150config NO_HZ
151 bool "Old Idle dynticks config"
152 depends on !ARCH_USES_GETTIMEOFFSET && GENERIC_CLOCKEVENTS
153 help
154 This is the old config entry that enables dynticks idle.
155 We keep it around for a little while to enforce backward
156 compatibility with older config files.
157
764e0da1
TG
158config HIGH_RES_TIMERS
159 bool "High Resolution Timer Support"
160 depends on !ARCH_USES_GETTIMEOFFSET && GENERIC_CLOCKEVENTS
161 select TICK_ONESHOT
162 help
163 This option enables high resolution timer support. If your
164 hardware is not capable then this option only increases
165 the size of the kernel image.
166
167endmenu
168endif