aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/Kconfig.locks
diff options
context:
space:
mode:
authorJan Beulich <JBeulich@suse.com>2012-09-10 08:01:16 -0400
committerIngo Molnar <mingo@kernel.org>2012-09-13 11:56:13 -0400
commit4fe84fb8c6b5081f7364af63aee8e118a665b966 (patch)
treed82d2eef06ea39bc367da0d394235b92a00841b4 /kernel/Kconfig.locks
parentd094595078d00b63839d0c5ccb8b184ef242cb45 (diff)
locking: Adjust spin lock inlining Kconfig options
Break out the DEBUG_SPINLOCK dependency (requires moving up UNINLINE_SPIN_UNLOCK, as this was the only one in that block not depending on that option). Avoid putting values not selected into the resulting .config - they are not useful for anything, make the output less legible, and just consume space: Use "depends on" rather than directly setting the default from the combined dependency values. Signed-off-by: Jan Beulich <jbeulich@suse.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Link: http://lkml.kernel.org/r/504DF2AC020000780009A2DF@nat28.tlf.novell.com Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel/Kconfig.locks')
-rw-r--r--kernel/Kconfig.locks103
1 files changed, 63 insertions, 40 deletions
diff --git a/kernel/Kconfig.locks b/kernel/Kconfig.locks
index 2251882daf53..44511d100eaa 100644
--- a/kernel/Kconfig.locks
+++ b/kernel/Kconfig.locks
@@ -87,6 +87,9 @@ config ARCH_INLINE_WRITE_UNLOCK_IRQ
87config ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE 87config ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE
88 bool 88 bool
89 89
90config UNINLINE_SPIN_UNLOCK
91 bool
92
90# 93#
91# lock_* functions are inlined when: 94# lock_* functions are inlined when:
92# - DEBUG_SPINLOCK=n and GENERIC_LOCKBREAK=n and ARCH_INLINE_*LOCK=y 95# - DEBUG_SPINLOCK=n and GENERIC_LOCKBREAK=n and ARCH_INLINE_*LOCK=y
@@ -103,100 +106,120 @@ config ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE
103# - DEBUG_SPINLOCK=n and ARCH_INLINE_*LOCK=y 106# - DEBUG_SPINLOCK=n and ARCH_INLINE_*LOCK=y
104# 107#
105 108
109if !DEBUG_SPINLOCK
110
106config INLINE_SPIN_TRYLOCK 111config INLINE_SPIN_TRYLOCK
107 def_bool !DEBUG_SPINLOCK && ARCH_INLINE_SPIN_TRYLOCK 112 def_bool y
113 depends on ARCH_INLINE_SPIN_TRYLOCK
108 114
109config INLINE_SPIN_TRYLOCK_BH 115config INLINE_SPIN_TRYLOCK_BH
110 def_bool !DEBUG_SPINLOCK && ARCH_INLINE_SPIN_TRYLOCK_BH 116 def_bool y
117 depends on ARCH_INLINE_SPIN_TRYLOCK_BH
111 118
112config INLINE_SPIN_LOCK 119config INLINE_SPIN_LOCK
113 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && ARCH_INLINE_SPIN_LOCK 120 def_bool y
121 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_SPIN_LOCK
114 122
115config INLINE_SPIN_LOCK_BH 123config INLINE_SPIN_LOCK_BH
116 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && \ 124 def_bool y
117 ARCH_INLINE_SPIN_LOCK_BH 125 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_SPIN_LOCK_BH
118 126
119config INLINE_SPIN_LOCK_IRQ 127config INLINE_SPIN_LOCK_IRQ
120 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && \ 128 def_bool y
121 ARCH_INLINE_SPIN_LOCK_IRQ 129 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_SPIN_LOCK_IRQ
122 130
123config INLINE_SPIN_LOCK_IRQSAVE 131config INLINE_SPIN_LOCK_IRQSAVE
124 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && \ 132 def_bool y
125 ARCH_INLINE_SPIN_LOCK_IRQSAVE 133 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_SPIN_LOCK_IRQSAVE
126
127config UNINLINE_SPIN_UNLOCK
128 bool
129 134
130config INLINE_SPIN_UNLOCK_BH 135config INLINE_SPIN_UNLOCK_BH
131 def_bool !DEBUG_SPINLOCK && ARCH_INLINE_SPIN_UNLOCK_BH 136 def_bool y
137 depends on ARCH_INLINE_SPIN_UNLOCK_BH
132 138
133config INLINE_SPIN_UNLOCK_IRQ 139config INLINE_SPIN_UNLOCK_IRQ
134 def_bool !DEBUG_SPINLOCK && (!PREEMPT || ARCH_INLINE_SPIN_UNLOCK_BH) 140 def_bool y
141 depends on !PREEMPT || ARCH_INLINE_SPIN_UNLOCK_BH
135 142
136config INLINE_SPIN_UNLOCK_IRQRESTORE 143config INLINE_SPIN_UNLOCK_IRQRESTORE
137 def_bool !DEBUG_SPINLOCK && ARCH_INLINE_SPIN_UNLOCK_IRQRESTORE 144 def_bool y
145 depends on ARCH_INLINE_SPIN_UNLOCK_IRQRESTORE
138 146
139 147
140config INLINE_READ_TRYLOCK 148config INLINE_READ_TRYLOCK
141 def_bool !DEBUG_SPINLOCK && ARCH_INLINE_READ_TRYLOCK 149 def_bool y
150 depends on ARCH_INLINE_READ_TRYLOCK
142 151
143config INLINE_READ_LOCK 152config INLINE_READ_LOCK
144 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && ARCH_INLINE_READ_LOCK 153 def_bool y
154 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_READ_LOCK
145 155
146config INLINE_READ_LOCK_BH 156config INLINE_READ_LOCK_BH
147 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && \ 157 def_bool y
148 ARCH_INLINE_READ_LOCK_BH 158 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_READ_LOCK_BH
149 159
150config INLINE_READ_LOCK_IRQ 160config INLINE_READ_LOCK_IRQ
151 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && \ 161 def_bool y
152 ARCH_INLINE_READ_LOCK_IRQ 162 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_READ_LOCK_IRQ
153 163
154config INLINE_READ_LOCK_IRQSAVE 164config INLINE_READ_LOCK_IRQSAVE
155 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && \ 165 def_bool y
156 ARCH_INLINE_READ_LOCK_IRQSAVE 166 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_READ_LOCK_IRQSAVE
157 167
158config INLINE_READ_UNLOCK 168config INLINE_READ_UNLOCK
159 def_bool !DEBUG_SPINLOCK && (!PREEMPT || ARCH_INLINE_READ_UNLOCK) 169 def_bool y
170 depends on !PREEMPT || ARCH_INLINE_READ_UNLOCK
160 171
161config INLINE_READ_UNLOCK_BH 172config INLINE_READ_UNLOCK_BH
162 def_bool !DEBUG_SPINLOCK && ARCH_INLINE_READ_UNLOCK_BH 173 def_bool y
174 depends on ARCH_INLINE_READ_UNLOCK_BH
163 175
164config INLINE_READ_UNLOCK_IRQ 176config INLINE_READ_UNLOCK_IRQ
165 def_bool !DEBUG_SPINLOCK && (!PREEMPT || ARCH_INLINE_READ_UNLOCK_BH) 177 def_bool y
178 depends on !PREEMPT || ARCH_INLINE_READ_UNLOCK_BH
166 179
167config INLINE_READ_UNLOCK_IRQRESTORE 180config INLINE_READ_UNLOCK_IRQRESTORE
168 def_bool !DEBUG_SPINLOCK && ARCH_INLINE_READ_UNLOCK_IRQRESTORE 181 def_bool y
182 depends on ARCH_INLINE_READ_UNLOCK_IRQRESTORE
169 183
170 184
171config INLINE_WRITE_TRYLOCK 185config INLINE_WRITE_TRYLOCK
172 def_bool !DEBUG_SPINLOCK && ARCH_INLINE_WRITE_TRYLOCK 186 def_bool y
187 depends on ARCH_INLINE_WRITE_TRYLOCK
173 188
174config INLINE_WRITE_LOCK 189config INLINE_WRITE_LOCK
175 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && ARCH_INLINE_WRITE_LOCK 190 def_bool y
191 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_WRITE_LOCK
176 192
177config INLINE_WRITE_LOCK_BH 193config INLINE_WRITE_LOCK_BH
178 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && \ 194 def_bool y
179 ARCH_INLINE_WRITE_LOCK_BH 195 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_WRITE_LOCK_BH
180 196
181config INLINE_WRITE_LOCK_IRQ 197config INLINE_WRITE_LOCK_IRQ
182 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && \ 198 def_bool y
183 ARCH_INLINE_WRITE_LOCK_IRQ 199 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_WRITE_LOCK_IRQ
184 200
185config INLINE_WRITE_LOCK_IRQSAVE 201config INLINE_WRITE_LOCK_IRQSAVE
186 def_bool !DEBUG_SPINLOCK && !GENERIC_LOCKBREAK && \ 202 def_bool y
187 ARCH_INLINE_WRITE_LOCK_IRQSAVE 203 depends on !GENERIC_LOCKBREAK && ARCH_INLINE_WRITE_LOCK_IRQSAVE
188 204
189config INLINE_WRITE_UNLOCK 205config INLINE_WRITE_UNLOCK
190 def_bool !DEBUG_SPINLOCK && (!PREEMPT || ARCH_INLINE_WRITE_UNLOCK) 206 def_bool y
207 depends on !PREEMPT || ARCH_INLINE_WRITE_UNLOCK
191 208
192config INLINE_WRITE_UNLOCK_BH 209config INLINE_WRITE_UNLOCK_BH
193 def_bool !DEBUG_SPINLOCK && ARCH_INLINE_WRITE_UNLOCK_BH 210 def_bool y
211 depends on ARCH_INLINE_WRITE_UNLOCK_BH
194 212
195config INLINE_WRITE_UNLOCK_IRQ 213config INLINE_WRITE_UNLOCK_IRQ
196 def_bool !DEBUG_SPINLOCK && (!PREEMPT || ARCH_INLINE_WRITE_UNLOCK_BH) 214 def_bool y
215 depends on !PREEMPT || ARCH_INLINE_WRITE_UNLOCK_BH
197 216
198config INLINE_WRITE_UNLOCK_IRQRESTORE 217config INLINE_WRITE_UNLOCK_IRQRESTORE
199 def_bool !DEBUG_SPINLOCK && ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE 218 def_bool y
219 depends on ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE
220
221endif
200 222
201config MUTEX_SPIN_ON_OWNER 223config MUTEX_SPIN_ON_OWNER
202 def_bool SMP && !DEBUG_MUTEXES 224 def_bool y
225 depends on SMP && !DEBUG_MUTEXES