]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blob - arch/arm64/Kconfig
arm64: Add MIDR encoding for Arm Cortex-A55 and Cortex-A35
[mirror_ubuntu-bionic-kernel.git] / arch / arm64 / Kconfig
1 config ARM64
2 def_bool y
3 select ACPI_CCA_REQUIRED if ACPI
4 select ACPI_GENERIC_GSI if ACPI
5 select ACPI_GTDT if ACPI
6 select ACPI_IORT if ACPI
7 select ACPI_REDUCED_HARDWARE_ONLY if ACPI
8 select ACPI_MCFG if ACPI
9 select ACPI_SPCR_TABLE if ACPI
10 select ACPI_PPTT if ACPI
11 select ARCH_CLOCKSOURCE_DATA
12 select ARCH_HAS_DEBUG_VIRTUAL
13 select ARCH_HAS_DEVMEM_IS_ALLOWED
14 select ARCH_HAS_ACPI_TABLE_UPGRADE if ACPI
15 select ARCH_HAS_ELF_RANDOMIZE
16 select ARCH_HAS_FORTIFY_SOURCE
17 select ARCH_HAS_GCOV_PROFILE_ALL
18 select ARCH_HAS_GIGANTIC_PAGE if (MEMORY_ISOLATION && COMPACTION) || CMA
19 select ARCH_HAS_KCOV
20 select ARCH_HAS_SET_MEMORY
21 select ARCH_HAS_SG_CHAIN
22 select ARCH_HAS_STRICT_KERNEL_RWX
23 select ARCH_HAS_STRICT_MODULE_RWX
24 select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST
25 select ARCH_HAVE_NMI_SAFE_CMPXCHG
26 select ARCH_INLINE_READ_LOCK if !PREEMPT
27 select ARCH_INLINE_READ_LOCK_BH if !PREEMPT
28 select ARCH_INLINE_READ_LOCK_IRQ if !PREEMPT
29 select ARCH_INLINE_READ_LOCK_IRQSAVE if !PREEMPT
30 select ARCH_INLINE_READ_UNLOCK if !PREEMPT
31 select ARCH_INLINE_READ_UNLOCK_BH if !PREEMPT
32 select ARCH_INLINE_READ_UNLOCK_IRQ if !PREEMPT
33 select ARCH_INLINE_READ_UNLOCK_IRQRESTORE if !PREEMPT
34 select ARCH_INLINE_WRITE_LOCK if !PREEMPT
35 select ARCH_INLINE_WRITE_LOCK_BH if !PREEMPT
36 select ARCH_INLINE_WRITE_LOCK_IRQ if !PREEMPT
37 select ARCH_INLINE_WRITE_LOCK_IRQSAVE if !PREEMPT
38 select ARCH_INLINE_WRITE_UNLOCK if !PREEMPT
39 select ARCH_INLINE_WRITE_UNLOCK_BH if !PREEMPT
40 select ARCH_INLINE_WRITE_UNLOCK_IRQ if !PREEMPT
41 select ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE if !PREEMPT
42 select ARCH_USE_CMPXCHG_LOCKREF
43 select ARCH_USE_QUEUED_RWLOCKS
44 select ARCH_SUPPORTS_MEMORY_FAILURE
45 select ARCH_SUPPORTS_ATOMIC_RMW
46 select ARCH_SUPPORTS_NUMA_BALANCING
47 select ARCH_WANT_COMPAT_IPC_PARSE_VERSION
48 select ARCH_WANT_FRAME_POINTERS
49 select ARCH_HAS_UBSAN_SANITIZE_ALL
50 select ARM_AMBA
51 select ARM_ARCH_TIMER
52 select ARM_GIC
53 select AUDIT_ARCH_COMPAT_GENERIC
54 select ARM_GIC_V2M if PCI
55 select ARM_GIC_V3
56 select ARM_GIC_V3_ITS if PCI
57 select ARM_PSCI_FW
58 select BUILDTIME_EXTABLE_SORT
59 select CLONE_BACKWARDS
60 select COMMON_CLK
61 select CPU_PM if (SUSPEND || CPU_IDLE)
62 select DCACHE_WORD_ACCESS
63 select EDAC_SUPPORT
64 select FRAME_POINTER
65 select GENERIC_ALLOCATOR
66 select GENERIC_ARCH_TOPOLOGY
67 select GENERIC_CLOCKEVENTS
68 select GENERIC_CLOCKEVENTS_BROADCAST
69 select GENERIC_CPU_AUTOPROBE
70 select GENERIC_EARLY_IOREMAP
71 select GENERIC_IDLE_POLL_SETUP
72 select GENERIC_IRQ_PROBE
73 select GENERIC_IRQ_SHOW
74 select GENERIC_IRQ_SHOW_LEVEL
75 select GENERIC_PCI_IOMAP
76 select GENERIC_SCHED_CLOCK
77 select GENERIC_SMP_IDLE_THREAD
78 select GENERIC_STRNCPY_FROM_USER
79 select GENERIC_STRNLEN_USER
80 select GENERIC_TIME_VSYSCALL
81 select HANDLE_DOMAIN_IRQ
82 select HARDIRQS_SW_RESEND
83 select HAVE_ACPI_APEI if (ACPI && EFI)
84 select HAVE_ALIGNED_STRUCT_PAGE if SLUB
85 select HAVE_ARCH_AUDITSYSCALL
86 select HAVE_ARCH_BITREVERSE
87 select HAVE_ARCH_HUGE_VMAP
88 select HAVE_ARCH_JUMP_LABEL
89 select HAVE_ARCH_KASAN if !(ARM64_16K_PAGES && ARM64_VA_BITS_48)
90 select HAVE_ARCH_KGDB
91 select HAVE_ARCH_MMAP_RND_BITS
92 select HAVE_ARCH_MMAP_RND_COMPAT_BITS if COMPAT
93 select HAVE_ARCH_SECCOMP_FILTER
94 select HAVE_ARCH_TRACEHOOK
95 select HAVE_ARCH_TRANSPARENT_HUGEPAGE
96 select HAVE_ARCH_VMAP_STACK
97 select HAVE_ARM_SMCCC
98 select HAVE_EBPF_JIT
99 select HAVE_C_RECORDMCOUNT
100 select HAVE_CC_STACKPROTECTOR
101 select HAVE_CMPXCHG_DOUBLE
102 select HAVE_CMPXCHG_LOCAL
103 select HAVE_CONTEXT_TRACKING
104 select HAVE_DEBUG_BUGVERBOSE
105 select HAVE_DEBUG_KMEMLEAK
106 select HAVE_DMA_API_DEBUG
107 select HAVE_DMA_CONTIGUOUS
108 select HAVE_DYNAMIC_FTRACE
109 select HAVE_EFFICIENT_UNALIGNED_ACCESS
110 select HAVE_FTRACE_MCOUNT_RECORD
111 select HAVE_FUNCTION_TRACER
112 select HAVE_FUNCTION_GRAPH_TRACER
113 select HAVE_GCC_PLUGINS
114 select HAVE_GENERIC_DMA_COHERENT
115 select HAVE_HW_BREAKPOINT if PERF_EVENTS
116 select HAVE_IRQ_TIME_ACCOUNTING
117 select HAVE_MEMBLOCK
118 select HAVE_MEMBLOCK_NODE_MAP if NUMA
119 select HAVE_NMI
120 select HAVE_PATA_PLATFORM
121 select HAVE_PERF_EVENTS
122 select HAVE_PERF_REGS
123 select HAVE_PERF_USER_STACK_DUMP
124 select HAVE_REGS_AND_STACK_ACCESS_API
125 select HAVE_RCU_TABLE_FREE
126 select HAVE_SYSCALL_TRACEPOINTS
127 select HAVE_KPROBES
128 select HAVE_KRETPROBES
129 select IOMMU_DMA if IOMMU_SUPPORT
130 select IRQ_DOMAIN
131 select IRQ_FORCED_THREADING
132 select MODULES_USE_ELF_RELA
133 select NO_BOOTMEM
134 select OF
135 select OF_EARLY_FLATTREE
136 select OF_RESERVED_MEM
137 select PCI_ECAM if ACPI
138 select POWER_RESET
139 select POWER_SUPPLY
140 select REFCOUNT_FULL
141 select SPARSE_IRQ
142 select SYSCTL_EXCEPTION_TRACE
143 select THREAD_INFO_IN_TASK
144 help
145 ARM 64-bit (AArch64) Linux support.
146
147 config 64BIT
148 def_bool y
149
150 config ARCH_PHYS_ADDR_T_64BIT
151 def_bool y
152
153 config MMU
154 def_bool y
155
156 config ARM64_PAGE_SHIFT
157 int
158 default 16 if ARM64_64K_PAGES
159 default 14 if ARM64_16K_PAGES
160 default 12
161
162 config ARM64_CONT_SHIFT
163 int
164 default 5 if ARM64_64K_PAGES
165 default 7 if ARM64_16K_PAGES
166 default 4
167
168 config ARCH_MMAP_RND_BITS_MIN
169 default 14 if ARM64_64K_PAGES
170 default 16 if ARM64_16K_PAGES
171 default 18
172
173 # max bits determined by the following formula:
174 # VA_BITS - PAGE_SHIFT - 3
175 config ARCH_MMAP_RND_BITS_MAX
176 default 19 if ARM64_VA_BITS=36
177 default 24 if ARM64_VA_BITS=39
178 default 27 if ARM64_VA_BITS=42
179 default 30 if ARM64_VA_BITS=47
180 default 29 if ARM64_VA_BITS=48 && ARM64_64K_PAGES
181 default 31 if ARM64_VA_BITS=48 && ARM64_16K_PAGES
182 default 33 if ARM64_VA_BITS=48
183 default 14 if ARM64_64K_PAGES
184 default 16 if ARM64_16K_PAGES
185 default 18
186
187 config ARCH_MMAP_RND_COMPAT_BITS_MIN
188 default 7 if ARM64_64K_PAGES
189 default 9 if ARM64_16K_PAGES
190 default 11
191
192 config ARCH_MMAP_RND_COMPAT_BITS_MAX
193 default 16
194
195 config NO_IOPORT_MAP
196 def_bool y if !PCI
197
198 config STACKTRACE_SUPPORT
199 def_bool y
200
201 config ILLEGAL_POINTER_VALUE
202 hex
203 default 0xdead000000000000
204
205 config LOCKDEP_SUPPORT
206 def_bool y
207
208 config TRACE_IRQFLAGS_SUPPORT
209 def_bool y
210
211 config RWSEM_XCHGADD_ALGORITHM
212 def_bool y
213
214 config GENERIC_BUG
215 def_bool y
216 depends on BUG
217
218 config GENERIC_BUG_RELATIVE_POINTERS
219 def_bool y
220 depends on GENERIC_BUG
221
222 config GENERIC_HWEIGHT
223 def_bool y
224
225 config GENERIC_CSUM
226 def_bool y
227
228 config GENERIC_CALIBRATE_DELAY
229 def_bool y
230
231 config ZONE_DMA
232 def_bool y
233
234 config HAVE_GENERIC_GUP
235 def_bool y
236
237 config ARCH_DMA_ADDR_T_64BIT
238 def_bool y
239
240 config NEED_DMA_MAP_STATE
241 def_bool y
242
243 config NEED_SG_DMA_LENGTH
244 def_bool y
245
246 config SMP
247 def_bool y
248
249 config SWIOTLB
250 def_bool y
251
252 config IOMMU_HELPER
253 def_bool SWIOTLB
254
255 config KERNEL_MODE_NEON
256 def_bool y
257
258 config FIX_EARLYCON_MEM
259 def_bool y
260
261 config PGTABLE_LEVELS
262 int
263 default 2 if ARM64_16K_PAGES && ARM64_VA_BITS_36
264 default 2 if ARM64_64K_PAGES && ARM64_VA_BITS_42
265 default 3 if ARM64_64K_PAGES && ARM64_VA_BITS_48
266 default 3 if ARM64_4K_PAGES && ARM64_VA_BITS_39
267 default 3 if ARM64_16K_PAGES && ARM64_VA_BITS_47
268 default 4 if !ARM64_64K_PAGES && ARM64_VA_BITS_48
269
270 config ARCH_SUPPORTS_UPROBES
271 def_bool y
272
273 config ARCH_PROC_KCORE_TEXT
274 def_bool y
275
276 source "init/Kconfig"
277
278 source "kernel/Kconfig.freezer"
279
280 source "arch/arm64/Kconfig.platforms"
281
282 menu "Bus support"
283
284 config PCI
285 bool "PCI support"
286 help
287 This feature enables support for PCI bus system. If you say Y
288 here, the kernel will include drivers and infrastructure code
289 to support PCI bus devices.
290
291 config PCI_DOMAINS
292 def_bool PCI
293
294 config PCI_DOMAINS_GENERIC
295 def_bool PCI
296
297 config PCI_SYSCALL
298 def_bool PCI
299
300 source "drivers/pci/Kconfig"
301
302 endmenu
303
304 menu "Kernel Features"
305
306 menu "ARM errata workarounds via the alternatives framework"
307
308 config ARM64_ERRATUM_826319
309 bool "Cortex-A53: 826319: System might deadlock if a write cannot complete until read data is accepted"
310 default y
311 help
312 This option adds an alternative code sequence to work around ARM
313 erratum 826319 on Cortex-A53 parts up to r0p2 with an AMBA 4 ACE or
314 AXI master interface and an L2 cache.
315
316 If a Cortex-A53 uses an AMBA AXI4 ACE interface to other processors
317 and is unable to accept a certain write via this interface, it will
318 not progress on read data presented on the read data channel and the
319 system can deadlock.
320
321 The workaround promotes data cache clean instructions to
322 data cache clean-and-invalidate.
323 Please note that this does not necessarily enable the workaround,
324 as it depends on the alternative framework, which will only patch
325 the kernel if an affected CPU is detected.
326
327 If unsure, say Y.
328
329 config ARM64_ERRATUM_827319
330 bool "Cortex-A53: 827319: Data cache clean instructions might cause overlapping transactions to the interconnect"
331 default y
332 help
333 This option adds an alternative code sequence to work around ARM
334 erratum 827319 on Cortex-A53 parts up to r0p2 with an AMBA 5 CHI
335 master interface and an L2 cache.
336
337 Under certain conditions this erratum can cause a clean line eviction
338 to occur at the same time as another transaction to the same address
339 on the AMBA 5 CHI interface, which can cause data corruption if the
340 interconnect reorders the two transactions.
341
342 The workaround promotes data cache clean instructions to
343 data cache clean-and-invalidate.
344 Please note that this does not necessarily enable the workaround,
345 as it depends on the alternative framework, which will only patch
346 the kernel if an affected CPU is detected.
347
348 If unsure, say Y.
349
350 config ARM64_ERRATUM_824069
351 bool "Cortex-A53: 824069: Cache line might not be marked as clean after a CleanShared snoop"
352 default y
353 help
354 This option adds an alternative code sequence to work around ARM
355 erratum 824069 on Cortex-A53 parts up to r0p2 when it is connected
356 to a coherent interconnect.
357
358 If a Cortex-A53 processor is executing a store or prefetch for
359 write instruction at the same time as a processor in another
360 cluster is executing a cache maintenance operation to the same
361 address, then this erratum might cause a clean cache line to be
362 incorrectly marked as dirty.
363
364 The workaround promotes data cache clean instructions to
365 data cache clean-and-invalidate.
366 Please note that this option does not necessarily enable the
367 workaround, as it depends on the alternative framework, which will
368 only patch the kernel if an affected CPU is detected.
369
370 If unsure, say Y.
371
372 config ARM64_ERRATUM_819472
373 bool "Cortex-A53: 819472: Store exclusive instructions might cause data corruption"
374 default y
375 help
376 This option adds an alternative code sequence to work around ARM
377 erratum 819472 on Cortex-A53 parts up to r0p1 with an L2 cache
378 present when it is connected to a coherent interconnect.
379
380 If the processor is executing a load and store exclusive sequence at
381 the same time as a processor in another cluster is executing a cache
382 maintenance operation to the same address, then this erratum might
383 cause data corruption.
384
385 The workaround promotes data cache clean instructions to
386 data cache clean-and-invalidate.
387 Please note that this does not necessarily enable the workaround,
388 as it depends on the alternative framework, which will only patch
389 the kernel if an affected CPU is detected.
390
391 If unsure, say Y.
392
393 config ARM64_ERRATUM_832075
394 bool "Cortex-A57: 832075: possible deadlock on mixing exclusive memory accesses with device loads"
395 default y
396 help
397 This option adds an alternative code sequence to work around ARM
398 erratum 832075 on Cortex-A57 parts up to r1p2.
399
400 Affected Cortex-A57 parts might deadlock when exclusive load/store
401 instructions to Write-Back memory are mixed with Device loads.
402
403 The workaround is to promote device loads to use Load-Acquire
404 semantics.
405 Please note that this does not necessarily enable the workaround,
406 as it depends on the alternative framework, which will only patch
407 the kernel if an affected CPU is detected.
408
409 If unsure, say Y.
410
411 config ARM64_ERRATUM_834220
412 bool "Cortex-A57: 834220: Stage 2 translation fault might be incorrectly reported in presence of a Stage 1 fault"
413 depends on KVM
414 default y
415 help
416 This option adds an alternative code sequence to work around ARM
417 erratum 834220 on Cortex-A57 parts up to r1p2.
418
419 Affected Cortex-A57 parts might report a Stage 2 translation
420 fault as the result of a Stage 1 fault for load crossing a
421 page boundary when there is a permission or device memory
422 alignment fault at Stage 1 and a translation fault at Stage 2.
423
424 The workaround is to verify that the Stage 1 translation
425 doesn't generate a fault before handling the Stage 2 fault.
426 Please note that this does not necessarily enable the workaround,
427 as it depends on the alternative framework, which will only patch
428 the kernel if an affected CPU is detected.
429
430 If unsure, say Y.
431
432 config ARM64_ERRATUM_845719
433 bool "Cortex-A53: 845719: a load might read incorrect data"
434 depends on COMPAT
435 default y
436 help
437 This option adds an alternative code sequence to work around ARM
438 erratum 845719 on Cortex-A53 parts up to r0p4.
439
440 When running a compat (AArch32) userspace on an affected Cortex-A53
441 part, a load at EL0 from a virtual address that matches the bottom 32
442 bits of the virtual address used by a recent load at (AArch64) EL1
443 might return incorrect data.
444
445 The workaround is to write the contextidr_el1 register on exception
446 return to a 32-bit task.
447 Please note that this does not necessarily enable the workaround,
448 as it depends on the alternative framework, which will only patch
449 the kernel if an affected CPU is detected.
450
451 If unsure, say Y.
452
453 config ARM64_ERRATUM_843419
454 bool "Cortex-A53: 843419: A load or store might access an incorrect address"
455 default y
456 select ARM64_MODULE_PLTS if MODULES
457 help
458 This option links the kernel with '--fix-cortex-a53-843419' and
459 enables PLT support to replace certain ADRP instructions, which can
460 cause subsequent memory accesses to use an incorrect address on
461 Cortex-A53 parts up to r0p4.
462
463 If unsure, say Y.
464
465 config ARM64_ERRATUM_1024718
466 bool "Cortex-A55: 1024718: Update of DBM/AP bits without break before make might result in incorrect update"
467 default y
468 help
469 This option adds work around for Arm Cortex-A55 Erratum 1024718.
470
471 Affected Cortex-A55 cores (r0p0, r0p1, r1p0) could cause incorrect
472 update of the hardware dirty bit when the DBM/AP bits are updated
473 without a break-before-make. The work around is to disable the usage
474 of hardware DBM locally on the affected cores. CPUs not affected by
475 erratum will continue to use the feature.
476
477 If unsure, say Y.
478
479 config ARM64_ERRATUM_1024718
480 bool "Cortex-A55: 1024718: Update of DBM/AP bits without break before make might result in incorrect update"
481 default y
482 help
483 This option adds work around for Arm Cortex-A55 Erratum 1024718.
484
485 Affected Cortex-A55 cores (r0p0, r0p1, r1p0) could cause incorrect
486 update of the hardware dirty bit when the DBM/AP bits are updated
487 without a break-before-make. The work around is to disable the usage
488 of hardware DBM locally on the affected cores. CPUs not affected by
489 erratum will continue to use the feature.
490
491 If unsure, say Y.
492
493 config CAVIUM_ERRATUM_22375
494 bool "Cavium erratum 22375, 24313"
495 default y
496 help
497 Enable workaround for erratum 22375, 24313.
498
499 This implements two gicv3-its errata workarounds for ThunderX. Both
500 with small impact affecting only ITS table allocation.
501
502 erratum 22375: only alloc 8MB table size
503 erratum 24313: ignore memory access type
504
505 The fixes are in ITS initialization and basically ignore memory access
506 type and table size provided by the TYPER and BASER registers.
507
508 If unsure, say Y.
509
510 config CAVIUM_ERRATUM_23144
511 bool "Cavium erratum 23144: ITS SYNC hang on dual socket system"
512 depends on NUMA
513 default y
514 help
515 ITS SYNC command hang for cross node io and collections/cpu mapping.
516
517 If unsure, say Y.
518
519 config CAVIUM_ERRATUM_23154
520 bool "Cavium erratum 23154: Access to ICC_IAR1_EL1 is not sync'ed"
521 default y
522 help
523 The gicv3 of ThunderX requires a modified version for
524 reading the IAR status to ensure data synchronization
525 (access to icc_iar1_el1 is not sync'ed before and after).
526
527 If unsure, say Y.
528
529 config CAVIUM_ERRATUM_27456
530 bool "Cavium erratum 27456: Broadcast TLBI instructions may cause icache corruption"
531 default y
532 help
533 On ThunderX T88 pass 1.x through 2.1 parts, broadcast TLBI
534 instructions may cause the icache to become corrupted if it
535 contains data for a non-current ASID. The fix is to
536 invalidate the icache when changing the mm context.
537
538 If unsure, say Y.
539
540 config CAVIUM_ERRATUM_30115
541 bool "Cavium erratum 30115: Guest may disable interrupts in host"
542 default y
543 help
544 On ThunderX T88 pass 1.x through 2.2, T81 pass 1.0 through
545 1.2, and T83 Pass 1.0, KVM guest execution may disable
546 interrupts in host. Trapping both GICv3 group-0 and group-1
547 accesses sidesteps the issue.
548
549 If unsure, say Y.
550
551 config QCOM_FALKOR_ERRATUM_1003
552 bool "Falkor E1003: Incorrect translation due to ASID change"
553 default y
554 help
555 On Falkor v1, an incorrect ASID may be cached in the TLB when ASID
556 and BADDR are changed together in TTBRx_EL1. Since we keep the ASID
557 in TTBR1_EL1, this situation only occurs in the entry trampoline and
558 then only for entries in the walk cache, since the leaf translation
559 is unchanged. Work around the erratum by invalidating the walk cache
560 entries for the trampoline before entering the kernel proper.
561
562 config QCOM_FALKOR_ERRATUM_1009
563 bool "Falkor E1009: Prematurely complete a DSB after a TLBI"
564 default y
565 help
566 On Falkor v1, the CPU may prematurely complete a DSB following a
567 TLBI xxIS invalidate maintenance operation. Repeat the TLBI operation
568 one more time to fix the issue.
569
570 If unsure, say Y.
571
572 config QCOM_QDF2400_ERRATUM_0065
573 bool "QDF2400 E0065: Incorrect GITS_TYPER.ITT_Entry_size"
574 default y
575 help
576 On Qualcomm Datacenter Technologies QDF2400 SoC, ITS hardware reports
577 ITE size incorrectly. The GITS_TYPER.ITT_Entry_size field should have
578 been indicated as 16Bytes (0xf), not 8Bytes (0x7).
579
580 If unsure, say Y.
581
582 config SOCIONEXT_SYNQUACER_PREITS
583 bool "Socionext Synquacer: Workaround for GICv3 pre-ITS"
584 default y
585 help
586 Socionext Synquacer SoCs implement a separate h/w block to generate
587 MSI doorbell writes with non-zero values for the device ID.
588
589 If unsure, say Y.
590
591 config HISILICON_ERRATUM_161600802
592 bool "Hip07 161600802: Erroneous redistributor VLPI base"
593 default y
594 help
595 The HiSilicon Hip07 SoC usees the wrong redistributor base
596 when issued ITS commands such as VMOVP and VMAPP, and requires
597 a 128kB offset to be applied to the target address in this commands.
598
599 If unsure, say Y.
600
601 config QCOM_FALKOR_ERRATUM_E1041
602 bool "Falkor E1041: Speculative instruction fetches might cause errant memory access"
603 default y
604 help
605 Falkor CPU may speculatively fetch instructions from an improper
606 memory location when MMU translation is changed from SCTLR_ELn[M]=1
607 to SCTLR_ELn[M]=0. Prefix an ISB instruction to fix the problem.
608
609 If unsure, say Y.
610
611 endmenu
612
613
614 choice
615 prompt "Page size"
616 default ARM64_4K_PAGES
617 help
618 Page size (translation granule) configuration.
619
620 config ARM64_4K_PAGES
621 bool "4KB"
622 help
623 This feature enables 4KB pages support.
624
625 config ARM64_16K_PAGES
626 bool "16KB"
627 help
628 The system will use 16KB pages support. AArch32 emulation
629 requires applications compiled with 16K (or a multiple of 16K)
630 aligned segments.
631
632 config ARM64_64K_PAGES
633 bool "64KB"
634 help
635 This feature enables 64KB pages support (4KB by default)
636 allowing only two levels of page tables and faster TLB
637 look-up. AArch32 emulation requires applications compiled
638 with 64K aligned segments.
639
640 endchoice
641
642 choice
643 prompt "Virtual address space size"
644 default ARM64_VA_BITS_39 if ARM64_4K_PAGES
645 default ARM64_VA_BITS_47 if ARM64_16K_PAGES
646 default ARM64_VA_BITS_42 if ARM64_64K_PAGES
647 help
648 Allows choosing one of multiple possible virtual address
649 space sizes. The level of translation table is determined by
650 a combination of page size and virtual address space size.
651
652 config ARM64_VA_BITS_36
653 bool "36-bit" if EXPERT
654 depends on ARM64_16K_PAGES
655
656 config ARM64_VA_BITS_39
657 bool "39-bit"
658 depends on ARM64_4K_PAGES
659
660 config ARM64_VA_BITS_42
661 bool "42-bit"
662 depends on ARM64_64K_PAGES
663
664 config ARM64_VA_BITS_47
665 bool "47-bit"
666 depends on ARM64_16K_PAGES
667
668 config ARM64_VA_BITS_48
669 bool "48-bit"
670
671 endchoice
672
673 config ARM64_VA_BITS
674 int
675 default 36 if ARM64_VA_BITS_36
676 default 39 if ARM64_VA_BITS_39
677 default 42 if ARM64_VA_BITS_42
678 default 47 if ARM64_VA_BITS_47
679 default 48 if ARM64_VA_BITS_48
680
681 config CPU_BIG_ENDIAN
682 bool "Build big-endian kernel"
683 help
684 Say Y if you plan on running a kernel in big-endian mode.
685
686 config SCHED_MC
687 bool "Multi-core scheduler support"
688 help
689 Multi-core scheduler support improves the CPU scheduler's decision
690 making when dealing with multi-core CPU chips at a cost of slightly
691 increased overhead in some places. If unsure say N here.
692
693 config SCHED_SMT
694 bool "SMT scheduler support"
695 help
696 Improves the CPU scheduler's decision making when dealing with
697 MultiThreading at a cost of slightly increased overhead in some
698 places. If unsure say N here.
699
700 config NR_CPUS
701 int "Maximum number of CPUs (2-4096)"
702 range 2 4096
703 # These have to remain sorted largest to smallest
704 default "64"
705
706 config HOTPLUG_CPU
707 bool "Support for hot-pluggable CPUs"
708 select GENERIC_IRQ_MIGRATION
709 help
710 Say Y here to experiment with turning CPUs off and on. CPUs
711 can be controlled through /sys/devices/system/cpu.
712
713 # Common NUMA Features
714 config NUMA
715 bool "Numa Memory Allocation and Scheduler Support"
716 select ACPI_NUMA if ACPI
717 select OF_NUMA
718 help
719 Enable NUMA (Non Uniform Memory Access) support.
720
721 The kernel will try to allocate memory used by a CPU on the
722 local memory of the CPU and add some more
723 NUMA awareness to the kernel.
724
725 config NODES_SHIFT
726 int "Maximum NUMA Nodes (as a power of 2)"
727 range 1 10
728 default "2"
729 depends on NEED_MULTIPLE_NODES
730 help
731 Specify the maximum number of NUMA Nodes available on the target
732 system. Increases memory reserved to accommodate various tables.
733
734 config USE_PERCPU_NUMA_NODE_ID
735 def_bool y
736 depends on NUMA
737
738 config HAVE_SETUP_PER_CPU_AREA
739 def_bool y
740 depends on NUMA
741
742 config NEED_PER_CPU_EMBED_FIRST_CHUNK
743 def_bool y
744 depends on NUMA
745
746 config HOLES_IN_ZONE
747 def_bool y
748
749 source kernel/Kconfig.preempt
750 source kernel/Kconfig.hz
751
752 config ARCH_SUPPORTS_DEBUG_PAGEALLOC
753 def_bool y
754
755 config ARCH_HAS_HOLES_MEMORYMODEL
756 def_bool y if SPARSEMEM
757
758 config ARCH_SPARSEMEM_ENABLE
759 def_bool y
760 select SPARSEMEM_VMEMMAP_ENABLE
761
762 config ARCH_SPARSEMEM_DEFAULT
763 def_bool ARCH_SPARSEMEM_ENABLE
764
765 config ARCH_SELECT_MEMORY_MODEL
766 def_bool ARCH_SPARSEMEM_ENABLE
767
768 config HAVE_ARCH_PFN_VALID
769 def_bool ARCH_HAS_HOLES_MEMORYMODEL || !SPARSEMEM
770
771 config HW_PERF_EVENTS
772 def_bool y
773 depends on ARM_PMU
774
775 config SYS_SUPPORTS_HUGETLBFS
776 def_bool y
777
778 config ARCH_WANT_HUGE_PMD_SHARE
779 def_bool y if ARM64_4K_PAGES || (ARM64_16K_PAGES && !ARM64_VA_BITS_36)
780
781 config ARCH_HAS_CACHE_LINE_SIZE
782 def_bool y
783
784 source "mm/Kconfig"
785
786 config SECCOMP
787 bool "Enable seccomp to safely compute untrusted bytecode"
788 ---help---
789 This kernel feature is useful for number crunching applications
790 that may need to compute untrusted bytecode during their
791 execution. By using pipes or other transports made available to
792 the process as file descriptors supporting the read/write
793 syscalls, it's possible to isolate those applications in
794 their own address space using seccomp. Once seccomp is
795 enabled via prctl(PR_SET_SECCOMP), it cannot be disabled
796 and the task is only allowed to execute a few safe syscalls
797 defined by each seccomp mode.
798
799 config PARAVIRT
800 bool "Enable paravirtualization code"
801 help
802 This changes the kernel so it can modify itself when it is run
803 under a hypervisor, potentially improving performance significantly
804 over full virtualization.
805
806 config PARAVIRT_TIME_ACCOUNTING
807 bool "Paravirtual steal time accounting"
808 select PARAVIRT
809 default n
810 help
811 Select this option to enable fine granularity task steal time
812 accounting. Time spent executing other tasks in parallel with
813 the current vCPU is discounted from the vCPU power. To account for
814 that, there can be a small performance impact.
815
816 If in doubt, say N here.
817
818 config KEXEC
819 depends on PM_SLEEP_SMP
820 select KEXEC_CORE
821 bool "kexec system call"
822 ---help---
823 kexec is a system call that implements the ability to shutdown your
824 current kernel, and to start another kernel. It is like a reboot
825 but it is independent of the system firmware. And like a reboot
826 you can start any kernel with it, not just Linux.
827
828 config CRASH_DUMP
829 bool "Build kdump crash kernel"
830 help
831 Generate crash dump after being started by kexec. This should
832 be normally only set in special crash dump kernels which are
833 loaded in the main kernel with kexec-tools into a specially
834 reserved region and then later executed after a crash by
835 kdump/kexec.
836
837 For more details see Documentation/kdump/kdump.txt
838
839 config XEN_DOM0
840 def_bool y
841 depends on XEN
842
843 config XEN
844 bool "Xen guest support on ARM64"
845 depends on ARM64 && OF
846 select SWIOTLB_XEN
847 select PARAVIRT
848 help
849 Say Y if you want to run Linux in a Virtual Machine on Xen on ARM64.
850
851 config FORCE_MAX_ZONEORDER
852 int
853 default "14" if (ARM64_64K_PAGES && TRANSPARENT_HUGEPAGE)
854 default "13" if (ARCH_THUNDER && ARM64_4K_PAGES)
855 default "12" if (ARM64_16K_PAGES && TRANSPARENT_HUGEPAGE)
856 default "11"
857 help
858 The kernel memory allocator divides physically contiguous memory
859 blocks into "zones", where each zone is a power of two number of
860 pages. This option selects the largest power of two that the kernel
861 keeps in the memory allocator. If you need to allocate very large
862 blocks of physically contiguous memory, then you may need to
863 increase this value.
864
865 This config option is actually maximum order plus one. For example,
866 a value of 11 means that the largest free memory block is 2^10 pages.
867
868 We make sure that we can allocate upto a HugePage size for each configuration.
869 Hence we have :
870 MAX_ORDER = (PMD_SHIFT - PAGE_SHIFT) + 1 => PAGE_SHIFT - 2
871
872 However for 4K, we choose a higher default value, 11 as opposed to 10, giving us
873 4M allocations matching the default size used by generic code.
874
875 config UNMAP_KERNEL_AT_EL0
876 bool "Unmap kernel when running in userspace (aka \"KAISER\")" if EXPERT
877 default y
878 help
879 Speculation attacks against some high-performance processors can
880 be used to bypass MMU permission checks and leak kernel data to
881 userspace. This can be defended against by unmapping the kernel
882 when running in userspace, mapping it back in on exception entry
883 via a trampoline page in the vector table.
884
885 If unsure, say Y.
886
887 config HARDEN_BRANCH_PREDICTOR
888 bool "Harden the branch predictor against aliasing attacks" if EXPERT
889 default y
890 help
891 Speculation attacks against some high-performance processors rely on
892 being able to manipulate the branch predictor for a victim context by
893 executing aliasing branches in the attacker context. Such attacks
894 can be partially mitigated against by clearing internal branch
895 predictor state and limiting the prediction logic in some situations.
896
897 This config option will take CPU-specific actions to harden the
898 branch predictor against aliasing attacks and may rely on specific
899 instruction sequences or control bits being set by the system
900 firmware.
901
902 If unsure, say Y.
903
904 config ARM64_SSBD
905 bool "Speculative Store Bypass Disable" if EXPERT
906 default y
907 help
908 This enables mitigation of the bypassing of previous stores
909 by speculative loads.
910
911 If unsure, say Y.
912
913 menuconfig ARMV8_DEPRECATED
914 bool "Emulate deprecated/obsolete ARMv8 instructions"
915 depends on COMPAT
916 depends on SYSCTL
917 help
918 Legacy software support may require certain instructions
919 that have been deprecated or obsoleted in the architecture.
920
921 Enable this config to enable selective emulation of these
922 features.
923
924 If unsure, say Y
925
926 if ARMV8_DEPRECATED
927
928 config SWP_EMULATION
929 bool "Emulate SWP/SWPB instructions"
930 help
931 ARMv8 obsoletes the use of A32 SWP/SWPB instructions such that
932 they are always undefined. Say Y here to enable software
933 emulation of these instructions for userspace using LDXR/STXR.
934
935 In some older versions of glibc [<=2.8] SWP is used during futex
936 trylock() operations with the assumption that the code will not
937 be preempted. This invalid assumption may be more likely to fail
938 with SWP emulation enabled, leading to deadlock of the user
939 application.
940
941 NOTE: when accessing uncached shared regions, LDXR/STXR rely
942 on an external transaction monitoring block called a global
943 monitor to maintain update atomicity. If your system does not
944 implement a global monitor, this option can cause programs that
945 perform SWP operations to uncached memory to deadlock.
946
947 If unsure, say Y
948
949 config CP15_BARRIER_EMULATION
950 bool "Emulate CP15 Barrier instructions"
951 help
952 The CP15 barrier instructions - CP15ISB, CP15DSB, and
953 CP15DMB - are deprecated in ARMv8 (and ARMv7). It is
954 strongly recommended to use the ISB, DSB, and DMB
955 instructions instead.
956
957 Say Y here to enable software emulation of these
958 instructions for AArch32 userspace code. When this option is
959 enabled, CP15 barrier usage is traced which can help
960 identify software that needs updating.
961
962 If unsure, say Y
963
964 config SETEND_EMULATION
965 bool "Emulate SETEND instruction"
966 help
967 The SETEND instruction alters the data-endianness of the
968 AArch32 EL0, and is deprecated in ARMv8.
969
970 Say Y here to enable software emulation of the instruction
971 for AArch32 userspace code.
972
973 Note: All the cpus on the system must have mixed endian support at EL0
974 for this feature to be enabled. If a new CPU - which doesn't support mixed
975 endian - is hotplugged in after this feature has been enabled, there could
976 be unexpected results in the applications.
977
978 If unsure, say Y
979 endif
980
981 config ARM64_SW_TTBR0_PAN
982 bool "Emulate Privileged Access Never using TTBR0_EL1 switching"
983 help
984 Enabling this option prevents the kernel from accessing
985 user-space memory directly by pointing TTBR0_EL1 to a reserved
986 zeroed area and reserved ASID. The user access routines
987 restore the valid TTBR0_EL1 temporarily.
988
989 menu "ARMv8.1 architectural features"
990
991 config ARM64_HW_AFDBM
992 bool "Support for hardware updates of the Access and Dirty page flags"
993 default y
994 help
995 The ARMv8.1 architecture extensions introduce support for
996 hardware updates of the access and dirty information in page
997 table entries. When enabled in TCR_EL1 (HA and HD bits) on
998 capable processors, accesses to pages with PTE_AF cleared will
999 set this bit instead of raising an access flag fault.
1000 Similarly, writes to read-only pages with the DBM bit set will
1001 clear the read-only bit (AP[2]) instead of raising a
1002 permission fault.
1003
1004 Kernels built with this configuration option enabled continue
1005 to work on pre-ARMv8.1 hardware and the performance impact is
1006 minimal. If unsure, say Y.
1007
1008 config ARM64_PAN
1009 bool "Enable support for Privileged Access Never (PAN)"
1010 default y
1011 help
1012 Privileged Access Never (PAN; part of the ARMv8.1 Extensions)
1013 prevents the kernel or hypervisor from accessing user-space (EL0)
1014 memory directly.
1015
1016 Choosing this option will cause any unprotected (not using
1017 copy_to_user et al) memory access to fail with a permission fault.
1018
1019 The feature is detected at runtime, and will remain as a 'nop'
1020 instruction if the cpu does not implement the feature.
1021
1022 config ARM64_LSE_ATOMICS
1023 bool "Atomic instructions"
1024 help
1025 As part of the Large System Extensions, ARMv8.1 introduces new
1026 atomic instructions that are designed specifically to scale in
1027 very large systems.
1028
1029 Say Y here to make use of these instructions for the in-kernel
1030 atomic routines. This incurs a small overhead on CPUs that do
1031 not support these instructions and requires the kernel to be
1032 built with binutils >= 2.25.
1033
1034 config ARM64_VHE
1035 bool "Enable support for Virtualization Host Extensions (VHE)"
1036 default y
1037 help
1038 Virtualization Host Extensions (VHE) allow the kernel to run
1039 directly at EL2 (instead of EL1) on processors that support
1040 it. This leads to better performance for KVM, as they reduce
1041 the cost of the world switch.
1042
1043 Selecting this option allows the VHE feature to be detected
1044 at runtime, and does not affect processors that do not
1045 implement this feature.
1046
1047 endmenu
1048
1049 menu "ARMv8.2 architectural features"
1050
1051 config ARM64_UAO
1052 bool "Enable support for User Access Override (UAO)"
1053 default y
1054 help
1055 User Access Override (UAO; part of the ARMv8.2 Extensions)
1056 causes the 'unprivileged' variant of the load/store instructions to
1057 be overridden to be privileged.
1058
1059 This option changes get_user() and friends to use the 'unprivileged'
1060 variant of the load/store instructions. This ensures that user-space
1061 really did have access to the supplied memory. When addr_limit is
1062 set to kernel memory the UAO bit will be set, allowing privileged
1063 access to kernel memory.
1064
1065 Choosing this option will cause copy_to_user() et al to use user-space
1066 memory permissions.
1067
1068 The feature is detected at runtime, the kernel will use the
1069 regular load/store instructions if the cpu does not implement the
1070 feature.
1071
1072 config ARM64_PMEM
1073 bool "Enable support for persistent memory"
1074 select ARCH_HAS_PMEM_API
1075 select ARCH_HAS_UACCESS_FLUSHCACHE
1076 help
1077 Say Y to enable support for the persistent memory API based on the
1078 ARMv8.2 DCPoP feature.
1079
1080 The feature is detected at runtime, and the kernel will use DC CVAC
1081 operations if DC CVAP is not supported (following the behaviour of
1082 DC CVAP itself if the system does not define a point of persistence).
1083
1084 config ARM64_RAS_EXTN
1085 bool "Enable support for RAS CPU Extensions"
1086 default y
1087 help
1088 CPUs that support the Reliability, Availability and Serviceability
1089 (RAS) Extensions, part of ARMv8.2 are able to track faults and
1090 errors, classify them and report them to software.
1091
1092 On CPUs with these extensions system software can use additional
1093 barriers to determine if faults are pending and read the
1094 classification from a new set of registers.
1095
1096 Selecting this feature will allow the kernel to use these barriers
1097 and access the new registers if the system supports the extension.
1098 Platform RAS features may additionally depend on firmware support.
1099
1100 endmenu
1101
1102 config ARM64_SVE
1103 bool "ARM Scalable Vector Extension support"
1104 default y
1105 help
1106 The Scalable Vector Extension (SVE) is an extension to the AArch64
1107 execution state which complements and extends the SIMD functionality
1108 of the base architecture to support much larger vectors and to enable
1109 additional vectorisation opportunities.
1110
1111 To enable use of this extension on CPUs that implement it, say Y.
1112
1113 config ARM64_MODULE_PLTS
1114 bool
1115 select HAVE_MOD_ARCH_SPECIFIC
1116
1117 config RELOCATABLE
1118 bool
1119 help
1120 This builds the kernel as a Position Independent Executable (PIE),
1121 which retains all relocation metadata required to relocate the
1122 kernel binary at runtime to a different virtual address than the
1123 address it was linked at.
1124 Since AArch64 uses the RELA relocation format, this requires a
1125 relocation pass at runtime even if the kernel is loaded at the
1126 same address it was linked at.
1127
1128 config RANDOMIZE_BASE
1129 bool "Randomize the address of the kernel image"
1130 select ARM64_MODULE_PLTS if MODULES
1131 select RELOCATABLE
1132 help
1133 Randomizes the virtual address at which the kernel image is
1134 loaded, as a security feature that deters exploit attempts
1135 relying on knowledge of the location of kernel internals.
1136
1137 It is the bootloader's job to provide entropy, by passing a
1138 random u64 value in /chosen/kaslr-seed at kernel entry.
1139
1140 When booting via the UEFI stub, it will invoke the firmware's
1141 EFI_RNG_PROTOCOL implementation (if available) to supply entropy
1142 to the kernel proper. In addition, it will randomise the physical
1143 location of the kernel Image as well.
1144
1145 If unsure, say N.
1146
1147 config RANDOMIZE_MODULE_REGION_FULL
1148 bool "Randomize the module region over a 4 GB range"
1149 depends on RANDOMIZE_BASE
1150 default y
1151 help
1152 Randomizes the location of the module region inside a 4 GB window
1153 covering the core kernel. This way, it is less likely for modules
1154 to leak information about the location of core kernel data structures
1155 but it does imply that function calls between modules and the core
1156 kernel will need to be resolved via veneers in the module PLT.
1157
1158 When this option is not set, the module region will be randomized over
1159 a limited range that contains the [_stext, _etext] interval of the
1160 core kernel, so branch relocations are always in range.
1161
1162 endmenu
1163
1164 menu "Boot options"
1165
1166 config ARM64_ACPI_PARKING_PROTOCOL
1167 bool "Enable support for the ARM64 ACPI parking protocol"
1168 depends on ACPI
1169 help
1170 Enable support for the ARM64 ACPI parking protocol. If disabled
1171 the kernel will not allow booting through the ARM64 ACPI parking
1172 protocol even if the corresponding data is present in the ACPI
1173 MADT table.
1174
1175 config CMDLINE
1176 string "Default kernel command string"
1177 default ""
1178 help
1179 Provide a set of default command-line options at build time by
1180 entering them here. As a minimum, you should specify the the
1181 root device (e.g. root=/dev/nfs).
1182
1183 config CMDLINE_FORCE
1184 bool "Always use the default kernel command string"
1185 help
1186 Always use the default kernel command string, even if the boot
1187 loader passes other arguments to the kernel.
1188 This is useful if you cannot or don't want to change the
1189 command-line options your boot loader passes to the kernel.
1190
1191 config EFI_STUB
1192 bool
1193
1194 config EFI
1195 bool "UEFI runtime support"
1196 depends on OF && !CPU_BIG_ENDIAN
1197 depends on KERNEL_MODE_NEON
1198 select ARCH_SUPPORTS_ACPI
1199 select LIBFDT
1200 select UCS2_STRING
1201 select EFI_PARAMS_FROM_FDT
1202 select EFI_RUNTIME_WRAPPERS
1203 select EFI_STUB
1204 select EFI_ARMSTUB
1205 default y
1206 help
1207 This option provides support for runtime services provided
1208 by UEFI firmware (such as non-volatile variables, realtime
1209 clock, and platform reset). A UEFI stub is also provided to
1210 allow the kernel to be booted as an EFI application. This
1211 is only useful on systems that have UEFI firmware.
1212
1213 config DMI
1214 bool "Enable support for SMBIOS (DMI) tables"
1215 depends on EFI
1216 default y
1217 help
1218 This enables SMBIOS/DMI feature for systems.
1219
1220 This option is only useful on systems that have UEFI firmware.
1221 However, even with this option, the resultant kernel should
1222 continue to boot on existing non-UEFI platforms.
1223
1224 endmenu
1225
1226 menu "Userspace binary formats"
1227
1228 source "fs/Kconfig.binfmt"
1229
1230 config COMPAT
1231 bool "Kernel support for 32-bit EL0"
1232 depends on ARM64_4K_PAGES || EXPERT
1233 select COMPAT_BINFMT_ELF if BINFMT_ELF
1234 select HAVE_UID16
1235 select OLD_SIGSUSPEND3
1236 select COMPAT_OLD_SIGACTION
1237 help
1238 This option enables support for a 32-bit EL0 running under a 64-bit
1239 kernel at EL1. AArch32-specific components such as system calls,
1240 the user helper functions, VFP support and the ptrace interface are
1241 handled appropriately by the kernel.
1242
1243 If you use a page size other than 4KB (i.e, 16KB or 64KB), please be aware
1244 that you will only be able to execute AArch32 binaries that were compiled
1245 with page size aligned segments.
1246
1247 If you want to execute 32-bit userspace applications, say Y.
1248
1249 config SYSVIPC_COMPAT
1250 def_bool y
1251 depends on COMPAT && SYSVIPC
1252
1253 endmenu
1254
1255 menu "Power management options"
1256
1257 source "kernel/power/Kconfig"
1258
1259 config ARCH_HIBERNATION_POSSIBLE
1260 def_bool y
1261 depends on CPU_PM
1262
1263 config ARCH_HIBERNATION_HEADER
1264 def_bool y
1265 depends on HIBERNATION
1266
1267 config ARCH_SUSPEND_POSSIBLE
1268 def_bool y
1269
1270 endmenu
1271
1272 menu "CPU Power Management"
1273
1274 source "drivers/cpuidle/Kconfig"
1275
1276 source "drivers/cpufreq/Kconfig"
1277
1278 endmenu
1279
1280 source "net/Kconfig"
1281
1282 source "drivers/Kconfig"
1283
1284 source "ubuntu/Kconfig"
1285
1286 source "drivers/firmware/Kconfig"
1287
1288 source "drivers/acpi/Kconfig"
1289
1290 source "fs/Kconfig"
1291
1292 source "arch/arm64/kvm/Kconfig"
1293
1294 source "arch/arm64/Kconfig.debug"
1295
1296 source "security/Kconfig"
1297
1298 source "crypto/Kconfig"
1299 if CRYPTO
1300 source "arch/arm64/crypto/Kconfig"
1301 endif
1302
1303 source "lib/Kconfig"