OSDN Git Service

drm: Fix HDCP failures when SRM fw is missing
[tomoyo/tomoyo-test1.git] / arch / powerpc / platforms / Kconfig.cputype
1 # SPDX-License-Identifier: GPL-2.0
2 config PPC32
3         bool
4         default y if !PPC64
5         select KASAN_VMALLOC if KASAN && MODULES
6
7 config PPC64
8         bool "64-bit kernel"
9         select ZLIB_DEFLATE
10         help
11           This option selects whether a 32-bit or a 64-bit kernel
12           will be built.
13
14 config PPC_BOOK3S_32
15         bool
16
17 menu "Processor support"
18 choice
19         prompt "Processor Type"
20         depends on PPC32
21         help
22           There are five families of 32 bit PowerPC chips supported.
23           The most common ones are the desktop and server CPUs (601, 603,
24           604, 740, 750, 74xx) CPUs from Freescale and IBM, with their
25           embedded 512x/52xx/82xx/83xx/86xx counterparts.
26           The other embedded parts, namely 4xx, 8xx, e200 (55xx) and e500
27           (85xx) each form a family of their own that is not compatible
28           with the others.
29
30           If unsure, select 52xx/6xx/7xx/74xx/82xx/83xx/86xx.
31
32 config PPC_BOOK3S_6xx
33         bool "512x/52xx/6xx/7xx/74xx/82xx/83xx/86xx except 601"
34         select PPC_BOOK3S_32
35         select PPC_FPU
36         select PPC_HAVE_PMU_SUPPORT
37         select PPC_HAVE_KUEP
38         select PPC_HAVE_KUAP
39         select HAVE_ARCH_VMAP_STACK
40
41 config PPC_BOOK3S_601
42         bool "PowerPC 601"
43         select PPC_BOOK3S_32
44         select PPC_FPU
45         select PPC_HAVE_KUAP
46         select HAVE_ARCH_VMAP_STACK
47
48 config PPC_85xx
49         bool "Freescale 85xx"
50         select E500
51
52 config PPC_8xx
53         bool "Freescale 8xx"
54         select FSL_SOC
55         select SYS_SUPPORTS_HUGETLBFS
56         select PPC_HAVE_KUEP
57         select PPC_HAVE_KUAP
58         select PPC_MM_SLICES if HUGETLB_PAGE
59         select HAVE_ARCH_VMAP_STACK
60
61 config 40x
62         bool "AMCC 40x"
63         select PPC_DCR_NATIVE
64         select PPC_UDBG_16550
65         select 4xx_SOC
66         select HAVE_PCI
67
68 config 44x
69         bool "AMCC 44x, 46x or 47x"
70         select PPC_DCR_NATIVE
71         select PPC_UDBG_16550
72         select 4xx_SOC
73         select HAVE_PCI
74         select PHYS_64BIT
75
76 config E200
77         bool "Freescale e200"
78
79 endchoice
80
81 choice
82         prompt "Processor Type"
83         depends on PPC64
84         help
85           There are two families of 64 bit PowerPC chips supported.
86           The most common ones are the desktop and server CPUs
87           (POWER5, 970, POWER5+, POWER6, POWER7, POWER8, POWER9 ...)
88
89           The other are the "embedded" processors compliant with the
90           "Book 3E" variant of the architecture
91
92 config PPC_BOOK3S_64
93         bool "Server processors"
94         select PPC_FPU
95         select PPC_HAVE_PMU_SUPPORT
96         select SYS_SUPPORTS_HUGETLBFS
97         select HAVE_ARCH_TRANSPARENT_HUGEPAGE
98         select ARCH_ENABLE_THP_MIGRATION if TRANSPARENT_HUGEPAGE
99         select ARCH_SUPPORTS_NUMA_BALANCING
100         select IRQ_WORK
101         select PPC_MM_SLICES
102
103 config PPC_BOOK3E_64
104         bool "Embedded processors"
105         select PPC_FPU # Make it a choice ?
106         select PPC_SMP_MUXED_IPI
107         select PPC_DOORBELL
108
109 endchoice
110
111 choice
112         prompt "CPU selection"
113         default GENERIC_CPU
114         help
115           This will create a kernel which is optimised for a particular CPU.
116           The resulting kernel may not run on other CPUs, so use this with care.
117
118           If unsure, select Generic.
119
120 config GENERIC_CPU
121         bool "Generic (POWER4 and above)"
122         depends on PPC64 && !CPU_LITTLE_ENDIAN
123
124 config GENERIC_CPU
125         bool "Generic (POWER8 and above)"
126         depends on PPC64 && CPU_LITTLE_ENDIAN
127         select ARCH_HAS_FAST_MULTIPLIER
128
129 config GENERIC_CPU
130         bool "Generic 32 bits powerpc"
131         depends on PPC32 && !PPC_8xx
132
133 config CELL_CPU
134         bool "Cell Broadband Engine"
135         depends on PPC_BOOK3S_64 && !CPU_LITTLE_ENDIAN
136
137 config POWER5_CPU
138         bool "POWER5"
139         depends on PPC_BOOK3S_64 && !CPU_LITTLE_ENDIAN
140
141 config POWER6_CPU
142         bool "POWER6"
143         depends on PPC_BOOK3S_64 && !CPU_LITTLE_ENDIAN
144
145 config POWER7_CPU
146         bool "POWER7"
147         depends on PPC_BOOK3S_64
148         select ARCH_HAS_FAST_MULTIPLIER
149
150 config POWER8_CPU
151         bool "POWER8"
152         depends on PPC_BOOK3S_64
153         select ARCH_HAS_FAST_MULTIPLIER
154
155 config POWER9_CPU
156         bool "POWER9"
157         depends on PPC_BOOK3S_64
158         select ARCH_HAS_FAST_MULTIPLIER
159
160 config E5500_CPU
161         bool "Freescale e5500"
162         depends on E500
163
164 config E6500_CPU
165         bool "Freescale e6500"
166         depends on E500
167
168 config 860_CPU
169         bool "8xx family"
170         depends on PPC_8xx
171
172 config E300C2_CPU
173         bool "e300c2 (832x)"
174         depends on PPC_BOOK3S_32
175
176 config E300C3_CPU
177         bool "e300c3 (831x)"
178         depends on PPC_BOOK3S_32
179
180 config G4_CPU
181         bool "G4 (74xx)"
182         depends on PPC_BOOK3S_32
183         select ALTIVEC
184
185 endchoice
186
187 config TARGET_CPU_BOOL
188         bool
189         default !GENERIC_CPU
190
191 config TARGET_CPU
192         string
193         depends on TARGET_CPU_BOOL
194         default "cell" if CELL_CPU
195         default "power5" if POWER5_CPU
196         default "power6" if POWER6_CPU
197         default "power7" if POWER7_CPU
198         default "power8" if POWER8_CPU
199         default "power9" if POWER9_CPU
200         default "860" if 860_CPU
201         default "e300c2" if E300C2_CPU
202         default "e300c3" if E300C3_CPU
203         default "G4" if G4_CPU
204
205 config PPC_BOOK3S
206         def_bool y
207         depends on PPC_BOOK3S_32 || PPC_BOOK3S_64
208
209 config PPC_BOOK3E
210         def_bool y
211         depends on PPC_BOOK3E_64
212
213 config E500
214         select FSL_EMB_PERFMON
215         select PPC_FSL_BOOK3E
216         bool
217
218 config PPC_E500MC
219         bool "e500mc Support"
220         select PPC_FPU
221         select COMMON_CLK
222         depends on E500
223         help
224           This must be enabled for running on e500mc (and derivatives
225           such as e5500/e6500), and must be disabled for running on
226           e500v1 or e500v2.
227
228 config PPC_FPU
229         bool
230         default y if PPC64
231
232 config FSL_EMB_PERFMON
233         bool "Freescale Embedded Perfmon"
234         depends on E500 || PPC_83xx
235         help
236           This is the Performance Monitor support found on the e500 core
237           and some e300 cores (c3 and c4).  Select this only if your
238           core supports the Embedded Performance Monitor APU
239
240 config FSL_EMB_PERF_EVENT
241         bool
242         depends on FSL_EMB_PERFMON && PERF_EVENTS && !PPC_PERF_CTRS
243         default y
244
245 config FSL_EMB_PERF_EVENT_E500
246         bool
247         depends on FSL_EMB_PERF_EVENT && E500
248         default y
249
250 config 4xx
251         bool
252         depends on 40x || 44x
253         default y
254
255 config BOOKE
256         bool
257         depends on E200 || E500 || 44x || PPC_BOOK3E
258         default y
259
260 config FSL_BOOKE
261         bool
262         depends on (E200 || E500) && PPC32
263         default y
264
265 # this is for common code between PPC32 & PPC64 FSL BOOKE
266 config PPC_FSL_BOOK3E
267         bool
268         select FSL_EMB_PERFMON
269         select PPC_SMP_MUXED_IPI
270         select SYS_SUPPORTS_HUGETLBFS if PHYS_64BIT || PPC64
271         select PPC_DOORBELL
272         default y if FSL_BOOKE
273
274 config PTE_64BIT
275         bool
276         depends on 44x || E500 || PPC_86xx
277         default y if PHYS_64BIT
278
279 config PHYS_64BIT
280         bool 'Large physical address support' if E500 || PPC_86xx
281         depends on (44x || E500 || PPC_86xx) && !PPC_83xx && !PPC_82xx
282         select PHYS_ADDR_T_64BIT
283         ---help---
284           This option enables kernel support for larger than 32-bit physical
285           addresses.  This feature may not be available on all cores.
286
287           If you have more than 3.5GB of RAM or so, you also need to enable
288           SWIOTLB under Kernel Options for this to work.  The actual number
289           is platform-dependent.
290
291           If in doubt, say N here.
292
293 config ALTIVEC
294         bool "AltiVec Support"
295         depends on PPC_BOOK3S_32 || PPC_BOOK3S_64 || (PPC_E500MC && PPC64)
296         ---help---
297           This option enables kernel support for the Altivec extensions to the
298           PowerPC processor. The kernel currently supports saving and restoring
299           altivec registers, and turning on the 'altivec enable' bit so user
300           processes can execute altivec instructions.
301
302           This option is only usefully if you have a processor that supports
303           altivec (G4, otherwise known as 74xx series), but does not have
304           any affect on a non-altivec cpu (it does, however add code to the
305           kernel).
306
307           If in doubt, say Y here.
308
309 config VSX
310         bool "VSX Support"
311         depends on PPC_BOOK3S_64 && ALTIVEC && PPC_FPU
312         ---help---
313
314           This option enables kernel support for the Vector Scaler extensions
315           to the PowerPC processor. The kernel currently supports saving and
316           restoring VSX registers, and turning on the 'VSX enable' bit so user
317           processes can execute VSX instructions.
318
319           This option is only useful if you have a processor that supports
320           VSX (P7 and above), but does not have any affect on a non-VSX
321           CPUs (it does, however add code to the kernel).
322
323           If in doubt, say Y here.
324
325 config SPE_POSSIBLE
326         def_bool y
327         depends on E200 || (E500 && !PPC_E500MC)
328
329 config SPE
330         bool "SPE Support"
331         depends on SPE_POSSIBLE
332         default y
333         ---help---
334           This option enables kernel support for the Signal Processing
335           Extensions (SPE) to the PowerPC processor. The kernel currently
336           supports saving and restoring SPE registers, and turning on the
337           'spe enable' bit so user processes can execute SPE instructions.
338
339           This option is only useful if you have a processor that supports
340           SPE (e500, otherwise known as 85xx series), but does not have any
341           effect on a non-spe cpu (it does, however add code to the kernel).
342
343           If in doubt, say Y here.
344
345 config ARCH_ENABLE_SPLIT_PMD_PTLOCK
346         def_bool y
347         depends on PPC_BOOK3S_64
348
349 config PPC_RADIX_MMU
350         bool "Radix MMU Support"
351         depends on PPC_BOOK3S_64
352         select ARCH_HAS_GIGANTIC_PAGE
353         select PPC_HAVE_KUEP
354         select PPC_HAVE_KUAP
355         default y
356         help
357           Enable support for the Power ISA 3.0 Radix style MMU. Currently this
358           is only implemented by IBM Power9 CPUs, if you don't have one of them
359           you can probably disable this.
360
361 config PPC_RADIX_MMU_DEFAULT
362         bool "Default to using the Radix MMU when possible"
363         depends on PPC_RADIX_MMU
364         default y
365         help
366           When the hardware supports the Radix MMU, default to using it unless
367           "disable_radix[=yes]" is specified on the kernel command line.
368
369           If this option is disabled, the Hash MMU will be used by default,
370           unless "disable_radix=no" is specified on the kernel command line.
371
372           If you're unsure, say Y.
373
374 config PPC_HAVE_KUEP
375         bool
376
377 config PPC_KUEP
378         bool "Kernel Userspace Execution Prevention"
379         depends on PPC_HAVE_KUEP
380         default y
381         help
382           Enable support for Kernel Userspace Execution Prevention (KUEP)
383
384           If you're unsure, say Y.
385
386 config PPC_HAVE_KUAP
387         bool
388
389 config PPC_KUAP
390         bool "Kernel Userspace Access Protection"
391         depends on PPC_HAVE_KUAP
392         default y
393         help
394           Enable support for Kernel Userspace Access Protection (KUAP)
395
396           If you're unsure, say Y.
397
398 config PPC_KUAP_DEBUG
399         bool "Extra debugging for Kernel Userspace Access Protection"
400         depends on PPC_KUAP && (PPC_RADIX_MMU || PPC_32)
401         help
402           Add extra debugging for Kernel Userspace Access Protection (KUAP)
403           If you're unsure, say N.
404
405 config ARCH_ENABLE_HUGEPAGE_MIGRATION
406         def_bool y
407         depends on PPC_BOOK3S_64 && HUGETLB_PAGE && MIGRATION
408
409
410 config PPC_MMU_NOHASH
411         def_bool y
412         depends on !PPC_BOOK3S
413
414 config PPC_MMU_NOHASH_32
415         def_bool y
416         depends on PPC_MMU_NOHASH && PPC32
417
418 config PPC_BOOK3E_MMU
419         def_bool y
420         depends on FSL_BOOKE || PPC_BOOK3E
421
422 config PPC_MM_SLICES
423         bool
424
425 config PPC_HAVE_PMU_SUPPORT
426         bool
427
428 config PMU_SYSFS
429         bool "Create PMU SPRs sysfs file"
430         default n
431         help
432           This option enables sysfs file creation for PMU SPRs like MMCR* and PMC*.
433
434 config PPC_PERF_CTRS
435         def_bool y
436         depends on PERF_EVENTS && PPC_HAVE_PMU_SUPPORT
437         help
438          This enables the powerpc-specific perf_event back-end.
439
440 config FORCE_SMP
441         # Allow platforms to force SMP=y by selecting this
442         bool
443         select SMP
444
445 config SMP
446         depends on PPC_BOOK3S || PPC_BOOK3E || FSL_BOOKE || PPC_47x
447         select GENERIC_IRQ_MIGRATION
448         bool "Symmetric multi-processing support" if !FORCE_SMP
449         ---help---
450           This enables support for systems with more than one CPU. If you have
451           a system with only one CPU, say N. If you have a system with more
452           than one CPU, say Y.  Note that the kernel does not currently
453           support SMP machines with 603/603e/603ev or PPC750 ("G3") processors
454           since they have inadequate hardware support for multiprocessor
455           operation.
456
457           If you say N here, the kernel will run on single and multiprocessor
458           machines, but will use only one CPU of a multiprocessor machine. If
459           you say Y here, the kernel will run on single-processor machines.
460           On a single-processor machine, the kernel will run faster if you say
461           N here.
462
463           If you don't know what to do here, say N.
464
465 config NR_CPUS
466         int "Maximum number of CPUs (2-8192)"
467         range 2 8192
468         depends on SMP
469         default "32" if PPC64
470         default "4"
471
472 config NOT_COHERENT_CACHE
473         bool
474         depends on 4xx || PPC_8xx || E200 || PPC_MPC512x || \
475                 GAMECUBE_COMMON || AMIGAONE
476         select ARCH_HAS_DMA_PREP_COHERENT
477         select ARCH_HAS_SYNC_DMA_FOR_DEVICE
478         select ARCH_HAS_SYNC_DMA_FOR_CPU
479         select DMA_DIRECT_REMAP
480         default n if PPC_47x
481         default y
482
483 config CHECK_CACHE_COHERENCY
484         bool
485
486 config PPC_DOORBELL
487         bool
488
489 endmenu
490
491 config VDSO32
492         def_bool y
493         depends on PPC32 || CPU_BIG_ENDIAN
494         help
495           This symbol controls whether we build the 32-bit VDSO. We obviously
496           want to do that if we're building a 32-bit kernel. If we're building
497           a 64-bit kernel then we only want a 32-bit VDSO if we're building for
498           big endian. That is because the only little endian configuration we
499           support is ppc64le which is 64-bit only.
500
501 choice
502         prompt "Endianness selection"
503         default CPU_BIG_ENDIAN
504         help
505           This option selects whether a big endian or little endian kernel will
506           be built.
507
508 config CPU_BIG_ENDIAN
509         bool "Build big endian kernel"
510         help
511           Build a big endian kernel.
512
513           If unsure, select this option.
514
515 config CPU_LITTLE_ENDIAN
516         bool "Build little endian kernel"
517         depends on PPC_BOOK3S_64
518         select PPC64_BOOT_WRAPPER
519         help
520           Build a little endian kernel.
521
522           Note that if cross compiling a little endian kernel,
523           CROSS_COMPILE must point to a toolchain capable of targeting
524           little endian powerpc.
525
526 endchoice
527
528 config PPC64_BOOT_WRAPPER
529         def_bool n
530         depends on CPU_LITTLE_ENDIAN