Training courses

Kernel and Embedded Linux

Bootlin training courses

Embedded Linux, kernel,
Yocto Project, Buildroot, real-time,
graphics, boot time, debugging...

Bootlin logo

Elixir Cross Referencer

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
config CONFIG_PPC64
	bool "64-bit kernel"
	default n
	select CONFIG_ZLIB_DEFLATE
	help
	  This option selects whether a 32-bit or a 64-bit kernel
	  will be built.

menu "Processor support"
choice
	prompt "Processor Type"
	depends on CONFIG_PPC32
	help
	  There are five families of 32 bit PowerPC chips supported.
	  The most common ones are the desktop and server CPUs (601, 603,
	  604, 740, 750, 74xx) CPUs from Freescale and IBM, with their
	  embedded 512x/52xx/82xx/83xx/86xx counterparts.
	  The other embedded parts, namely CONFIG_4xx, CONFIG_8xx, e200 (55xx) and e500
	  (85xx) each form a family of their own that is not compatible
	  with the others.

	  If unsure, select 52xx/CONFIG_6xx/7xx/74xx/82xx/83xx/86xx.

config CONFIG_PPC_BOOK3S_32
	bool "512x/52xx/6xx/7xx/74xx/82xx/83xx/86xx"
	select CONFIG_PPC_FPU

config CONFIG_PPC_85xx
	bool "Freescale 85xx"
	select CONFIG_E500

config CONFIG_PPC_8xx
	bool "Freescale 8xx"
	select CONFIG_FSL_SOC
	select CONFIG_8xx
	select CONFIG_PPC_LIB_RHEAP
	select CONFIG_SYS_SUPPORTS_HUGETLBFS

config CONFIG_40x
	bool "AMCC 40x"
	select CONFIG_PPC_DCR_NATIVE
	select CONFIG_PPC_UDBG_16550
	select CONFIG_4xx_SOC
	select CONFIG_PPC_PCI_CHOICE

config CONFIG_44x
	bool "AMCC 44x, 46x or 47x"
	select CONFIG_PPC_DCR_NATIVE
	select CONFIG_PPC_UDBG_16550
	select CONFIG_4xx_SOC
	select CONFIG_PPC_PCI_CHOICE
	select CONFIG_PHYS_64BIT

config CONFIG_E200
	bool "Freescale e200"

endchoice

choice
	prompt "Processor Type"
	depends on CONFIG_PPC64
	help
	  There are two families of 64 bit PowerPC chips supported.
	  The most common ones are the desktop and server CPUs
	  (POWER4, POWER5, 970, POWER5+, POWER6, POWER7, POWER8 ...)

	  The other are the "embedded" processors compliant with the
	  "Book 3E" variant of the architecture

config CONFIG_PPC_BOOK3S_64
	bool "Server processors"
	select CONFIG_PPC_FPU
	select CONFIG_PPC_HAVE_PMU_SUPPORT
	select CONFIG_SYS_SUPPORTS_HUGETLBFS
	select CONFIG_HAVE_ARCH_TRANSPARENT_HUGEPAGE
	select CONFIG_ARCH_SUPPORTS_NUMA_BALANCING
	select CONFIG_IRQ_WORK
	select CONFIG_HAVE_KERNEL_XZ

config CONFIG_PPC_BOOK3E_64
	bool "Embedded processors"
	select CONFIG_PPC_FPU # Make it a choice ?
	select CONFIG_PPC_SMP_MUXED_IPI
	select CONFIG_PPC_DOORBELL

endchoice

choice
	prompt "CPU selection"
	depends on CONFIG_PPC64
	default CONFIG_POWER8_CPU if CONFIG_CPU_LITTLE_ENDIAN
	default CONFIG_GENERIC_CPU
	help
	  This will create a kernel which is optimised for a particular CPU.
	  The resulting kernel may not run on other CPUs, so use this with care.

	  If unsure, select Generic.

config CONFIG_GENERIC_CPU
	bool "Generic"
	depends on !CONFIG_CPU_LITTLE_ENDIAN

config CONFIG_CELL_CPU
	bool "Cell Broadband Engine"
	depends on CONFIG_PPC_BOOK3S_64 && !CONFIG_CPU_LITTLE_ENDIAN

config CONFIG_POWER4_CPU
	bool "POWER4"
	depends on CONFIG_PPC_BOOK3S_64 && !CONFIG_CPU_LITTLE_ENDIAN

config CONFIG_POWER5_CPU
	bool "POWER5"
	depends on CONFIG_PPC_BOOK3S_64 && !CONFIG_CPU_LITTLE_ENDIAN

config CONFIG_POWER6_CPU
	bool "POWER6"
	depends on CONFIG_PPC_BOOK3S_64 && !CONFIG_CPU_LITTLE_ENDIAN

config CONFIG_POWER7_CPU
	bool "POWER7"
	depends on CONFIG_PPC_BOOK3S_64
	select CONFIG_ARCH_HAS_FAST_MULTIPLIER

config CONFIG_POWER8_CPU
	bool "POWER8"
	depends on CONFIG_PPC_BOOK3S_64
	select CONFIG_ARCH_HAS_FAST_MULTIPLIER

config CONFIG_E5500_CPU
	bool "Freescale e5500"
	depends on CONFIG_E500

config CONFIG_E6500_CPU
	bool "Freescale e6500"
	depends on CONFIG_E500

endchoice

config CONFIG_PPC_BOOK3S
	def_bool y
	depends on CONFIG_PPC_BOOK3S_32 || CONFIG_PPC_BOOK3S_64

config CONFIG_PPC_BOOK3E
	def_bool y
	depends on CONFIG_PPC_BOOK3E_64

config CONFIG_6xx
	def_bool y
	depends on CONFIG_PPC32 && CONFIG_PPC_BOOK3S
	select CONFIG_PPC_HAVE_PMU_SUPPORT

# this is temp to handle compat with arch=ppc
config CONFIG_8xx
	bool

config CONFIG_E500
	select CONFIG_FSL_EMB_PERFMON
	select CONFIG_PPC_FSL_BOOK3E
	bool

config CONFIG_PPC_E500MC
	bool "e500mc Support"
	select CONFIG_PPC_FPU
	select CONFIG_COMMON_CLK
	depends on CONFIG_E500
	help
	  This must be enabled for running on e500mc (and derivatives
	  such as e5500/e6500), and must be disabled for running on
	  e500v1 or e500v2.

config CONFIG_PPC_FPU
	bool
	default y if CONFIG_PPC64

config CONFIG_FSL_EMB_PERFMON
	bool "Freescale Embedded Perfmon"
	depends on CONFIG_E500 || CONFIG_PPC_83xx
	help
	  This is the Performance Monitor support found on the e500 core
	  and some e300 cores (c3 and c4).  Select this only if your
	  core supports the Embedded Performance Monitor APU

config CONFIG_FSL_EMB_PERF_EVENT
	bool
	depends on CONFIG_FSL_EMB_PERFMON && CONFIG_PERF_EVENTS && !CONFIG_PPC_PERF_CTRS
	default y

config CONFIG_FSL_EMB_PERF_EVENT_E500
	bool
	depends on CONFIG_FSL_EMB_PERF_EVENT && CONFIG_E500
	default y

config CONFIG_4xx
	bool
	depends on CONFIG_40x || CONFIG_44x
	default y

config CONFIG_BOOKE
	bool
	depends on CONFIG_E200 || CONFIG_E500 || CONFIG_44x || CONFIG_PPC_BOOK3E
	default y

config CONFIG_FSL_BOOKE
	bool
	depends on (CONFIG_E200 || CONFIG_E500) && CONFIG_PPC32
	default y

# this is for common code between CONFIG_PPC32 & CONFIG_PPC64 FSL CONFIG_BOOKE
config CONFIG_PPC_FSL_BOOK3E
	bool
	select CONFIG_FSL_EMB_PERFMON
	select CONFIG_PPC_SMP_MUXED_IPI
	select CONFIG_SYS_SUPPORTS_HUGETLBFS if CONFIG_PHYS_64BIT || CONFIG_PPC64
	select CONFIG_PPC_DOORBELL
	default y if CONFIG_FSL_BOOKE

config CONFIG_PTE_64BIT
	bool
	depends on CONFIG_44x || CONFIG_E500 || CONFIG_PPC_86xx
	default y if CONFIG_PHYS_64BIT

config CONFIG_PHYS_64BIT
	bool 'Large physical address support' if CONFIG_E500 || CONFIG_PPC_86xx
	depends on (CONFIG_44x || CONFIG_E500 || CONFIG_PPC_86xx) && !CONFIG_PPC_83xx && !CONFIG_PPC_82xx
	---help---
	  This option enables kernel support for larger than 32-bit physical
	  addresses.  This feature may not be available on all cores.

	  If you have more than 3.5GB of RAM or so, you also need to enable
	  CONFIG_SWIOTLB under Kernel Options for this to work.  The actual number
	  is platform-dependent.

	  If in doubt, say N here.

config CONFIG_ALTIVEC
	bool "AltiVec Support"
	depends on CONFIG_6xx || CONFIG_PPC_BOOK3S_64 || (CONFIG_PPC_E500MC && CONFIG_PPC64)
	---help---
	  This option enables kernel support for the Altivec extensions to the
	  PowerPC processor. The kernel currently supports saving and restoring
	  altivec registers, and turning on the 'altivec enable' bit so user
	  processes can execute altivec instructions.

	  This option is only usefully if you have a processor that supports
	  altivec (G4, otherwise known as 74xx series), but does not have
	  any affect on a non-altivec cpu (it does, however add code to the
	  kernel).

	  If in doubt, say Y here.

config CONFIG_VSX
	bool "VSX Support"
	depends on CONFIG_PPC_BOOK3S_64 && CONFIG_ALTIVEC && CONFIG_PPC_FPU
	---help---

	  This option enables kernel support for the Vector Scaler extensions
	  to the PowerPC processor. The kernel currently supports saving and
	  restoring CONFIG_VSX registers, and turning on the 'CONFIG_VSX enable' bit so user
	  processes can execute CONFIG_VSX instructions.

	  This option is only useful if you have a processor that supports
	  CONFIG_VSX (P7 and above), but does not have any affect on a non-CONFIG_VSX
	  CPUs (it does, however add code to the kernel).

	  If in doubt, say Y here.

config CONFIG_PPC_ICSWX
	bool "Support for PowerPC icswx coprocessor instruction"
	depends on CONFIG_PPC_BOOK3S_64
	default n
	---help---

	  This option enables kernel support for the PowerPC Initiate
	  Coprocessor Store Word (icswx) coprocessor instruction on POWER7
	  or newer processors.

	  This option is only useful if you have a processor that supports
	  the icswx coprocessor instruction. It does not have any effect
	  on processors without the icswx coprocessor instruction.

	  This option slightly increases kernel memory usage.

	  If in doubt, say N here.

config CONFIG_PPC_ICSWX_PID
	bool "icswx requires direct PID management"
	depends on CONFIG_PPC_ICSWX
	default y
	---help---
	  The PID register in server is used explicitly for ICSWX.  In
	  embedded systems PID management is done by the system.

config CONFIG_PPC_ICSWX_USE_SIGILL
	bool "Should a bad CT cause a SIGILL?"
	depends on CONFIG_PPC_ICSWX
	default n
	---help---
	  Should a bad CT used for "non-record form ICSWX" cause an
	  illegal instruction signal or should it be silent as
	  architected.

	  If in doubt, say N here.

config CONFIG_SPE_POSSIBLE
	def_bool y
	depends on CONFIG_E200 || (CONFIG_E500 && !CONFIG_PPC_E500MC)

config CONFIG_SPE
	bool "SPE Support"
	depends on CONFIG_SPE_POSSIBLE
	default y
	---help---
	  This option enables kernel support for the Signal Processing
	  Extensions (CONFIG_SPE) to the PowerPC processor. The kernel currently
	  supports saving and restoring CONFIG_SPE registers, and turning on the
	  'spe enable' bit so user processes can execute CONFIG_SPE instructions.

	  This option is only useful if you have a processor that supports
	  CONFIG_SPE (e500, otherwise known as 85xx series), but does not have any
	  effect on a non-spe cpu (it does, however add code to the kernel).

	  If in doubt, say Y here.

config CONFIG_PPC_STD_MMU
	def_bool y
	depends on CONFIG_PPC_BOOK3S

config CONFIG_PPC_STD_MMU_32
	def_bool y
	depends on CONFIG_PPC_STD_MMU && CONFIG_PPC32

config CONFIG_PPC_STD_MMU_64
	def_bool y
	depends on CONFIG_PPC_STD_MMU && CONFIG_PPC64

config CONFIG_PPC_RADIX_MMU
	bool "Radix MMU Support"
	depends on CONFIG_PPC_BOOK3S_64
	default y
	help
	  Enable support for the Power CONFIG_ISA 3.0 Radix style CONFIG_MMU. Currently this
	  is only implemented by IBM Power9 CPUs, if you don't have one of them
	  you can probably disable this.

config CONFIG_PPC_MMU_NOHASH
	def_bool y
	depends on !CONFIG_PPC_STD_MMU

config CONFIG_PPC_BOOK3E_MMU
	def_bool y
	depends on CONFIG_FSL_BOOKE || CONFIG_PPC_BOOK3E

config CONFIG_PPC_MM_SLICES
	bool
	default y if (!CONFIG_PPC_FSL_BOOK3E && CONFIG_PPC64 && CONFIG_HUGETLB_PAGE) || (CONFIG_PPC_STD_MMU_64 && CONFIG_PPC_64K_PAGES)
	default n

config CONFIG_PPC_HAVE_PMU_SUPPORT
       bool

config CONFIG_PPC_PERF_CTRS
       def_bool y
       depends on CONFIG_PERF_EVENTS && CONFIG_PPC_HAVE_PMU_SUPPORT
       help
         This enables the powerpc-specific perf_event back-end.

config CONFIG_SMP
	depends on CONFIG_PPC_BOOK3S || CONFIG_PPC_BOOK3E || CONFIG_FSL_BOOKE || CONFIG_PPC_47x
	bool "Symmetric multi-processing support"
	---help---
	  This enables support for systems with more than one CPU. If you have
	  a system with only one CPU, say N. If you have a system with more
	  than one CPU, say Y.  Note that the kernel does not currently
	  support CONFIG_SMP machines with 603/603e/603ev or PPC750 ("G3") processors
	  since they have inadequate hardware support for multiprocessor
	  operation.

	  If you say N here, the kernel will run on single and multiprocessor
	  machines, but will use only one CPU of a multiprocessor machine. If
	  you say Y here, the kernel will run on single-processor machines.
	  On a single-processor machine, the kernel will run faster if you say
	  N here.

	  If you don't know what to do here, say N.

config CONFIG_NR_CPUS
	int "Maximum number of CPUs (2-8192)"
	range 2 8192
	depends on CONFIG_SMP
	default "32" if CONFIG_PPC64
	default "4"

config CONFIG_NOT_COHERENT_CACHE
	bool
	depends on CONFIG_4xx || CONFIG_8xx || CONFIG_E200 || CONFIG_PPC_MPC512x || CONFIG_GAMECUBE_COMMON
	default n if CONFIG_PPC_47x
	default y

config CONFIG_CHECK_CACHE_COHERENCY
	bool

config CONFIG_PPC_DOORBELL
	bool
	default n

endmenu

config CONFIG_VDSO32
	def_bool y
	depends on CONFIG_PPC32 || CONFIG_CPU_BIG_ENDIAN
	help
	  This symbol controls whether we build the 32-bit CONFIG_VDSO. We obviously
	  want to do that if we're building a 32-bit kernel. If we're building
	  a 64-bit kernel then we only want a 32-bit CONFIG_VDSO if we're building for
	  big endian. That is because the only little endian configuration we
	  support is ppc64le which is 64-bit only.

choice
	prompt "Endianness selection"
	default CONFIG_CPU_BIG_ENDIAN
	help
	  This option selects whether a big endian or little endian kernel will
	  be built.

config CONFIG_CPU_BIG_ENDIAN
	bool "Build big endian kernel"
	help
	  Build a big endian kernel.

	  If unsure, select this option.

config CONFIG_CPU_LITTLE_ENDIAN
	bool "Build little endian kernel"
	depends on CONFIG_PPC_BOOK3S_64
	select CONFIG_PPC64_BOOT_WRAPPER
	help
	  Build a little endian kernel.

	  Note that if cross compiling a little endian kernel,
	  CONFIG_CROSS_COMPILE must point to a toolchain capable of targeting
	  little endian powerpc.

endchoice

config CONFIG_PPC64_BOOT_WRAPPER
	def_bool n
	depends on CONFIG_CPU_LITTLE_ENDIAN