18c2ecf20Sopenharmony_ci# SPDX-License-Identifier: GPL-2.0-only 28c2ecf20Sopenharmony_ciconfig ARM64 38c2ecf20Sopenharmony_ci def_bool y 48c2ecf20Sopenharmony_ci select ACPI_CCA_REQUIRED if ACPI 58c2ecf20Sopenharmony_ci select ACPI_GENERIC_GSI if ACPI 68c2ecf20Sopenharmony_ci select ACPI_GTDT if ACPI 78c2ecf20Sopenharmony_ci select ACPI_IORT if ACPI 88c2ecf20Sopenharmony_ci select ACPI_REDUCED_HARDWARE_ONLY if ACPI 98c2ecf20Sopenharmony_ci select ACPI_MCFG if (ACPI && PCI) 108c2ecf20Sopenharmony_ci select ACPI_SPCR_TABLE if ACPI 118c2ecf20Sopenharmony_ci select ACPI_PPTT if ACPI 128c2ecf20Sopenharmony_ci select ARCH_HAS_DEBUG_WX 138c2ecf20Sopenharmony_ci select ARCH_BINFMT_ELF_STATE 148c2ecf20Sopenharmony_ci select ARCH_HAS_DEBUG_VIRTUAL 158c2ecf20Sopenharmony_ci select ARCH_HAS_DEBUG_VM_PGTABLE 168c2ecf20Sopenharmony_ci select ARCH_HAS_DEVMEM_IS_ALLOWED 178c2ecf20Sopenharmony_ci select ARCH_HAS_DMA_PREP_COHERENT 188c2ecf20Sopenharmony_ci select ARCH_HAS_ACPI_TABLE_UPGRADE if ACPI 198c2ecf20Sopenharmony_ci select ARCH_HAS_FAST_MULTIPLIER 208c2ecf20Sopenharmony_ci select ARCH_HAS_FORTIFY_SOURCE 218c2ecf20Sopenharmony_ci select ARCH_HAS_GCOV_PROFILE_ALL 228c2ecf20Sopenharmony_ci select ARCH_HAS_GIGANTIC_PAGE 238c2ecf20Sopenharmony_ci select ARCH_HAS_KCOV 248c2ecf20Sopenharmony_ci select ARCH_HAS_KEEPINITRD 258c2ecf20Sopenharmony_ci select ARCH_HAS_MEMBARRIER_SYNC_CORE 268c2ecf20Sopenharmony_ci select ARCH_HAS_NON_OVERLAPPING_ADDRESS_SPACE 278c2ecf20Sopenharmony_ci select ARCH_HAS_PTE_DEVMAP 288c2ecf20Sopenharmony_ci select ARCH_HAS_PTE_SPECIAL 298c2ecf20Sopenharmony_ci select ARCH_HAS_SETUP_DMA_OPS 308c2ecf20Sopenharmony_ci select ARCH_HAS_SET_DIRECT_MAP 318c2ecf20Sopenharmony_ci select ARCH_HAS_SET_MEMORY 328c2ecf20Sopenharmony_ci select ARCH_STACKWALK 338c2ecf20Sopenharmony_ci select ARCH_HAS_STRICT_KERNEL_RWX 348c2ecf20Sopenharmony_ci select ARCH_HAS_STRICT_MODULE_RWX 358c2ecf20Sopenharmony_ci select ARCH_HAS_SYNC_DMA_FOR_DEVICE 368c2ecf20Sopenharmony_ci select ARCH_HAS_SYNC_DMA_FOR_CPU 378c2ecf20Sopenharmony_ci select ARCH_HAS_SYSCALL_WRAPPER 388c2ecf20Sopenharmony_ci select ARCH_HAS_TEARDOWN_DMA_OPS if IOMMU_SUPPORT 398c2ecf20Sopenharmony_ci select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST 408c2ecf20Sopenharmony_ci select ARCH_HAVE_ELF_PROT 418c2ecf20Sopenharmony_ci select ARCH_HAVE_NMI_SAFE_CMPXCHG 428c2ecf20Sopenharmony_ci select ARCH_INLINE_READ_LOCK if !PREEMPTION 438c2ecf20Sopenharmony_ci select ARCH_INLINE_READ_LOCK_BH if !PREEMPTION 448c2ecf20Sopenharmony_ci select ARCH_INLINE_READ_LOCK_IRQ if !PREEMPTION 458c2ecf20Sopenharmony_ci select ARCH_INLINE_READ_LOCK_IRQSAVE if !PREEMPTION 468c2ecf20Sopenharmony_ci select ARCH_INLINE_READ_UNLOCK if !PREEMPTION 478c2ecf20Sopenharmony_ci select ARCH_INLINE_READ_UNLOCK_BH if !PREEMPTION 488c2ecf20Sopenharmony_ci select ARCH_INLINE_READ_UNLOCK_IRQ if !PREEMPTION 498c2ecf20Sopenharmony_ci select ARCH_INLINE_READ_UNLOCK_IRQRESTORE if !PREEMPTION 508c2ecf20Sopenharmony_ci select ARCH_INLINE_WRITE_LOCK if !PREEMPTION 518c2ecf20Sopenharmony_ci select ARCH_INLINE_WRITE_LOCK_BH if !PREEMPTION 528c2ecf20Sopenharmony_ci select ARCH_INLINE_WRITE_LOCK_IRQ if !PREEMPTION 538c2ecf20Sopenharmony_ci select ARCH_INLINE_WRITE_LOCK_IRQSAVE if !PREEMPTION 548c2ecf20Sopenharmony_ci select ARCH_INLINE_WRITE_UNLOCK if !PREEMPTION 558c2ecf20Sopenharmony_ci select ARCH_INLINE_WRITE_UNLOCK_BH if !PREEMPTION 568c2ecf20Sopenharmony_ci select ARCH_INLINE_WRITE_UNLOCK_IRQ if !PREEMPTION 578c2ecf20Sopenharmony_ci select ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE if !PREEMPTION 588c2ecf20Sopenharmony_ci select ARCH_INLINE_SPIN_TRYLOCK if !PREEMPTION 598c2ecf20Sopenharmony_ci select ARCH_INLINE_SPIN_TRYLOCK_BH if !PREEMPTION 608c2ecf20Sopenharmony_ci select ARCH_INLINE_SPIN_LOCK if !PREEMPTION 618c2ecf20Sopenharmony_ci select ARCH_INLINE_SPIN_LOCK_BH if !PREEMPTION 628c2ecf20Sopenharmony_ci select ARCH_INLINE_SPIN_LOCK_IRQ if !PREEMPTION 638c2ecf20Sopenharmony_ci select ARCH_INLINE_SPIN_LOCK_IRQSAVE if !PREEMPTION 648c2ecf20Sopenharmony_ci select ARCH_INLINE_SPIN_UNLOCK if !PREEMPTION 658c2ecf20Sopenharmony_ci select ARCH_INLINE_SPIN_UNLOCK_BH if !PREEMPTION 668c2ecf20Sopenharmony_ci select ARCH_INLINE_SPIN_UNLOCK_IRQ if !PREEMPTION 678c2ecf20Sopenharmony_ci select ARCH_INLINE_SPIN_UNLOCK_IRQRESTORE if !PREEMPTION 688c2ecf20Sopenharmony_ci select ARCH_KEEP_MEMBLOCK 698c2ecf20Sopenharmony_ci select ARCH_USE_CMPXCHG_LOCKREF 708c2ecf20Sopenharmony_ci select ARCH_USE_GNU_PROPERTY 718c2ecf20Sopenharmony_ci select ARCH_USE_QUEUED_RWLOCKS 728c2ecf20Sopenharmony_ci select ARCH_USE_QUEUED_SPINLOCKS 738c2ecf20Sopenharmony_ci select ARCH_USE_SYM_ANNOTATIONS 748c2ecf20Sopenharmony_ci select ARCH_SUPPORTS_MEMORY_FAILURE 758c2ecf20Sopenharmony_ci select ARCH_SUPPORTS_SHADOW_CALL_STACK if CC_HAVE_SHADOW_CALL_STACK 768c2ecf20Sopenharmony_ci select ARCH_SUPPORTS_LTO_CLANG if CPU_LITTLE_ENDIAN 778c2ecf20Sopenharmony_ci select ARCH_SUPPORTS_LTO_CLANG_THIN 788c2ecf20Sopenharmony_ci select ARCH_SUPPORTS_CFI_CLANG 798c2ecf20Sopenharmony_ci select ARCH_SUPPORTS_ATOMIC_RMW 808c2ecf20Sopenharmony_ci select ARCH_SUPPORTS_INT128 if CC_HAS_INT128 && (GCC_VERSION >= 50000 || CC_IS_CLANG) 818c2ecf20Sopenharmony_ci select ARCH_SUPPORTS_NUMA_BALANCING 828c2ecf20Sopenharmony_ci select ARCH_WANT_COMPAT_IPC_PARSE_VERSION if COMPAT 838c2ecf20Sopenharmony_ci select ARCH_WANT_DEFAULT_BPF_JIT 848c2ecf20Sopenharmony_ci select ARCH_WANT_DEFAULT_TOPDOWN_MMAP_LAYOUT 858c2ecf20Sopenharmony_ci select ARCH_WANT_FRAME_POINTERS 868c2ecf20Sopenharmony_ci select ARCH_WANT_HUGE_PMD_SHARE if ARM64_4K_PAGES || (ARM64_16K_PAGES && !ARM64_VA_BITS_36) 878c2ecf20Sopenharmony_ci select ARCH_WANT_LD_ORPHAN_WARN 888c2ecf20Sopenharmony_ci select ARCH_HAS_UBSAN_SANITIZE_ALL 898c2ecf20Sopenharmony_ci select ARM_AMBA 908c2ecf20Sopenharmony_ci select ARM_ARCH_TIMER 918c2ecf20Sopenharmony_ci select ARM_GIC 928c2ecf20Sopenharmony_ci select AUDIT_ARCH_COMPAT_GENERIC 938c2ecf20Sopenharmony_ci select ARM_GIC_V2M if PCI 948c2ecf20Sopenharmony_ci select ARM_GIC_V3 958c2ecf20Sopenharmony_ci select ARM_GIC_V3_ITS if PCI 968c2ecf20Sopenharmony_ci select ARM_PSCI_FW 978c2ecf20Sopenharmony_ci select BUILDTIME_TABLE_SORT 988c2ecf20Sopenharmony_ci select CLONE_BACKWARDS 998c2ecf20Sopenharmony_ci select COMMON_CLK 1008c2ecf20Sopenharmony_ci select CPU_PM if (SUSPEND || CPU_IDLE) 1018c2ecf20Sopenharmony_ci select CRC32 1028c2ecf20Sopenharmony_ci select DCACHE_WORD_ACCESS 1038c2ecf20Sopenharmony_ci select DMA_DIRECT_REMAP 1048c2ecf20Sopenharmony_ci select EDAC_SUPPORT 1058c2ecf20Sopenharmony_ci select FRAME_POINTER 1068c2ecf20Sopenharmony_ci select GENERIC_ALLOCATOR 1078c2ecf20Sopenharmony_ci select GENERIC_ARCH_TOPOLOGY 1088c2ecf20Sopenharmony_ci select GENERIC_CLOCKEVENTS 1098c2ecf20Sopenharmony_ci select GENERIC_CLOCKEVENTS_BROADCAST 1108c2ecf20Sopenharmony_ci select GENERIC_CPU_AUTOPROBE 1118c2ecf20Sopenharmony_ci select GENERIC_CPU_VULNERABILITIES 1128c2ecf20Sopenharmony_ci select GENERIC_EARLY_IOREMAP 1138c2ecf20Sopenharmony_ci select GENERIC_IDLE_POLL_SETUP 1148c2ecf20Sopenharmony_ci select GENERIC_IRQ_IPI 1158c2ecf20Sopenharmony_ci select GENERIC_IRQ_MULTI_HANDLER 1168c2ecf20Sopenharmony_ci select GENERIC_IRQ_PROBE 1178c2ecf20Sopenharmony_ci select GENERIC_IRQ_SHOW 1188c2ecf20Sopenharmony_ci select GENERIC_IRQ_SHOW_LEVEL 1198c2ecf20Sopenharmony_ci select GENERIC_PCI_IOMAP 1208c2ecf20Sopenharmony_ci select GENERIC_PTDUMP 1218c2ecf20Sopenharmony_ci select GENERIC_SCHED_CLOCK 1228c2ecf20Sopenharmony_ci select GENERIC_SMP_IDLE_THREAD 1238c2ecf20Sopenharmony_ci select GENERIC_STRNCPY_FROM_USER 1248c2ecf20Sopenharmony_ci select GENERIC_STRNLEN_USER 1258c2ecf20Sopenharmony_ci select GENERIC_TIME_VSYSCALL 1268c2ecf20Sopenharmony_ci select GENERIC_GETTIMEOFDAY 1278c2ecf20Sopenharmony_ci select GENERIC_VDSO_TIME_NS 1288c2ecf20Sopenharmony_ci select HANDLE_DOMAIN_IRQ 1298c2ecf20Sopenharmony_ci select HARDIRQS_SW_RESEND 1308c2ecf20Sopenharmony_ci select HAVE_MOVE_PMD 1318c2ecf20Sopenharmony_ci select HAVE_PCI 1328c2ecf20Sopenharmony_ci select HAVE_ACPI_APEI if (ACPI && EFI) 1338c2ecf20Sopenharmony_ci select HAVE_ALIGNED_STRUCT_PAGE if SLUB 1348c2ecf20Sopenharmony_ci select HAVE_ARCH_AUDITSYSCALL 1358c2ecf20Sopenharmony_ci select HAVE_ARCH_BITREVERSE 1368c2ecf20Sopenharmony_ci select HAVE_ARCH_COMPILER_H 1378c2ecf20Sopenharmony_ci select HAVE_ARCH_HUGE_VMAP 1388c2ecf20Sopenharmony_ci select HAVE_ARCH_JUMP_LABEL 1398c2ecf20Sopenharmony_ci select HAVE_ARCH_JUMP_LABEL_RELATIVE 1408c2ecf20Sopenharmony_ci select HAVE_ARCH_KASAN if !(ARM64_16K_PAGES && ARM64_VA_BITS_48) 1418c2ecf20Sopenharmony_ci select HAVE_ARCH_KASAN_SW_TAGS if HAVE_ARCH_KASAN 1428c2ecf20Sopenharmony_ci select HAVE_ARCH_KGDB 1438c2ecf20Sopenharmony_ci select HAVE_ARCH_MMAP_RND_BITS 1448c2ecf20Sopenharmony_ci select HAVE_ARCH_MMAP_RND_COMPAT_BITS if COMPAT 1458c2ecf20Sopenharmony_ci select HAVE_ARCH_PREL32_RELOCATIONS 1468c2ecf20Sopenharmony_ci select HAVE_ARCH_SECCOMP_FILTER 1478c2ecf20Sopenharmony_ci select HAVE_ARCH_STACKLEAK 1488c2ecf20Sopenharmony_ci select HAVE_ARCH_THREAD_STRUCT_WHITELIST 1498c2ecf20Sopenharmony_ci select HAVE_ARCH_TRACEHOOK 1508c2ecf20Sopenharmony_ci select HAVE_ARCH_TRANSPARENT_HUGEPAGE 1518c2ecf20Sopenharmony_ci select HAVE_ARCH_VMAP_STACK 1528c2ecf20Sopenharmony_ci select HAVE_ARM_SMCCC 1538c2ecf20Sopenharmony_ci select HAVE_ASM_MODVERSIONS 1548c2ecf20Sopenharmony_ci select HAVE_EBPF_JIT 1558c2ecf20Sopenharmony_ci select HAVE_C_RECORDMCOUNT 1568c2ecf20Sopenharmony_ci select HAVE_CMPXCHG_DOUBLE 1578c2ecf20Sopenharmony_ci select HAVE_CMPXCHG_LOCAL 1588c2ecf20Sopenharmony_ci select HAVE_CONTEXT_TRACKING 1598c2ecf20Sopenharmony_ci select HAVE_DEBUG_BUGVERBOSE 1608c2ecf20Sopenharmony_ci select HAVE_DEBUG_KMEMLEAK 1618c2ecf20Sopenharmony_ci select HAVE_DMA_CONTIGUOUS 1628c2ecf20Sopenharmony_ci select HAVE_DYNAMIC_FTRACE 1638c2ecf20Sopenharmony_ci select HAVE_DYNAMIC_FTRACE_WITH_REGS \ 1648c2ecf20Sopenharmony_ci if $(cc-option,-fpatchable-function-entry=2) 1658c2ecf20Sopenharmony_ci select FTRACE_MCOUNT_USE_PATCHABLE_FUNCTION_ENTRY \ 1668c2ecf20Sopenharmony_ci if DYNAMIC_FTRACE_WITH_REGS 1678c2ecf20Sopenharmony_ci select HAVE_EFFICIENT_UNALIGNED_ACCESS 1688c2ecf20Sopenharmony_ci select HAVE_FAST_GUP 1698c2ecf20Sopenharmony_ci select HAVE_FTRACE_MCOUNT_RECORD 1708c2ecf20Sopenharmony_ci select HAVE_FUNCTION_TRACER 1718c2ecf20Sopenharmony_ci select HAVE_FUNCTION_ERROR_INJECTION 1728c2ecf20Sopenharmony_ci select HAVE_FUNCTION_GRAPH_TRACER 1738c2ecf20Sopenharmony_ci select HAVE_GCC_PLUGINS 1748c2ecf20Sopenharmony_ci select HAVE_HW_BREAKPOINT if PERF_EVENTS 1758c2ecf20Sopenharmony_ci select HAVE_IRQ_TIME_ACCOUNTING 1768c2ecf20Sopenharmony_ci select HAVE_NMI 1778c2ecf20Sopenharmony_ci select HAVE_PATA_PLATFORM 1788c2ecf20Sopenharmony_ci select HAVE_PERF_EVENTS 1798c2ecf20Sopenharmony_ci select HAVE_PERF_REGS 1808c2ecf20Sopenharmony_ci select HAVE_PERF_USER_STACK_DUMP 1818c2ecf20Sopenharmony_ci select HAVE_REGS_AND_STACK_ACCESS_API 1828c2ecf20Sopenharmony_ci select HAVE_FUNCTION_ARG_ACCESS_API 1838c2ecf20Sopenharmony_ci select HAVE_FUTEX_CMPXCHG if FUTEX 1848c2ecf20Sopenharmony_ci select MMU_GATHER_RCU_TABLE_FREE 1858c2ecf20Sopenharmony_ci select HAVE_RSEQ 1868c2ecf20Sopenharmony_ci select HAVE_STACKPROTECTOR 1878c2ecf20Sopenharmony_ci select HAVE_SYSCALL_TRACEPOINTS 1888c2ecf20Sopenharmony_ci select HAVE_KPROBES 1898c2ecf20Sopenharmony_ci select HAVE_KRETPROBES 1908c2ecf20Sopenharmony_ci select HAVE_GENERIC_VDSO 1918c2ecf20Sopenharmony_ci select HOLES_IN_ZONE 1928c2ecf20Sopenharmony_ci select IOMMU_DMA if IOMMU_SUPPORT 1938c2ecf20Sopenharmony_ci select IRQ_DOMAIN 1948c2ecf20Sopenharmony_ci select IRQ_FORCED_THREADING 1958c2ecf20Sopenharmony_ci select MODULES_USE_ELF_RELA 1968c2ecf20Sopenharmony_ci select NEED_DMA_MAP_STATE 1978c2ecf20Sopenharmony_ci select NEED_SG_DMA_LENGTH 1988c2ecf20Sopenharmony_ci select OF 1998c2ecf20Sopenharmony_ci select OF_EARLY_FLATTREE 2008c2ecf20Sopenharmony_ci select PCI_DOMAINS_GENERIC if PCI 2018c2ecf20Sopenharmony_ci select PCI_ECAM if (ACPI && PCI) 2028c2ecf20Sopenharmony_ci select PCI_SYSCALL if PCI 2038c2ecf20Sopenharmony_ci select POWER_RESET 2048c2ecf20Sopenharmony_ci select POWER_SUPPLY 2058c2ecf20Sopenharmony_ci select SET_FS 2068c2ecf20Sopenharmony_ci select SPARSE_IRQ 2078c2ecf20Sopenharmony_ci select SWIOTLB 2088c2ecf20Sopenharmony_ci select SYSCTL_EXCEPTION_TRACE 2098c2ecf20Sopenharmony_ci select THREAD_INFO_IN_TASK 2108c2ecf20Sopenharmony_ci help 2118c2ecf20Sopenharmony_ci ARM 64-bit (AArch64) Linux support. 2128c2ecf20Sopenharmony_ci 2138c2ecf20Sopenharmony_ciconfig 64BIT 2148c2ecf20Sopenharmony_ci def_bool y 2158c2ecf20Sopenharmony_ci 2168c2ecf20Sopenharmony_ciconfig MMU 2178c2ecf20Sopenharmony_ci def_bool y 2188c2ecf20Sopenharmony_ci 2198c2ecf20Sopenharmony_ciconfig ARM64_PAGE_SHIFT 2208c2ecf20Sopenharmony_ci int 2218c2ecf20Sopenharmony_ci default 16 if ARM64_64K_PAGES 2228c2ecf20Sopenharmony_ci default 14 if ARM64_16K_PAGES 2238c2ecf20Sopenharmony_ci default 12 2248c2ecf20Sopenharmony_ci 2258c2ecf20Sopenharmony_ciconfig ARM64_CONT_PTE_SHIFT 2268c2ecf20Sopenharmony_ci int 2278c2ecf20Sopenharmony_ci default 5 if ARM64_64K_PAGES 2288c2ecf20Sopenharmony_ci default 7 if ARM64_16K_PAGES 2298c2ecf20Sopenharmony_ci default 4 2308c2ecf20Sopenharmony_ci 2318c2ecf20Sopenharmony_ciconfig ARM64_CONT_PMD_SHIFT 2328c2ecf20Sopenharmony_ci int 2338c2ecf20Sopenharmony_ci default 5 if ARM64_64K_PAGES 2348c2ecf20Sopenharmony_ci default 5 if ARM64_16K_PAGES 2358c2ecf20Sopenharmony_ci default 4 2368c2ecf20Sopenharmony_ci 2378c2ecf20Sopenharmony_ciconfig ARCH_MMAP_RND_BITS_MIN 2388c2ecf20Sopenharmony_ci default 14 if ARM64_64K_PAGES 2398c2ecf20Sopenharmony_ci default 16 if ARM64_16K_PAGES 2408c2ecf20Sopenharmony_ci default 18 2418c2ecf20Sopenharmony_ci 2428c2ecf20Sopenharmony_ci# max bits determined by the following formula: 2438c2ecf20Sopenharmony_ci# VA_BITS - PAGE_SHIFT - 3 2448c2ecf20Sopenharmony_ciconfig ARCH_MMAP_RND_BITS_MAX 2458c2ecf20Sopenharmony_ci default 19 if ARM64_VA_BITS=36 2468c2ecf20Sopenharmony_ci default 24 if ARM64_VA_BITS=39 2478c2ecf20Sopenharmony_ci default 27 if ARM64_VA_BITS=42 2488c2ecf20Sopenharmony_ci default 30 if ARM64_VA_BITS=47 2498c2ecf20Sopenharmony_ci default 29 if ARM64_VA_BITS=48 && ARM64_64K_PAGES 2508c2ecf20Sopenharmony_ci default 31 if ARM64_VA_BITS=48 && ARM64_16K_PAGES 2518c2ecf20Sopenharmony_ci default 33 if ARM64_VA_BITS=48 2528c2ecf20Sopenharmony_ci default 14 if ARM64_64K_PAGES 2538c2ecf20Sopenharmony_ci default 16 if ARM64_16K_PAGES 2548c2ecf20Sopenharmony_ci default 18 2558c2ecf20Sopenharmony_ci 2568c2ecf20Sopenharmony_ciconfig ARCH_MMAP_RND_COMPAT_BITS_MIN 2578c2ecf20Sopenharmony_ci default 7 if ARM64_64K_PAGES 2588c2ecf20Sopenharmony_ci default 9 if ARM64_16K_PAGES 2598c2ecf20Sopenharmony_ci default 11 2608c2ecf20Sopenharmony_ci 2618c2ecf20Sopenharmony_ciconfig ARCH_MMAP_RND_COMPAT_BITS_MAX 2628c2ecf20Sopenharmony_ci default 16 2638c2ecf20Sopenharmony_ci 2648c2ecf20Sopenharmony_ciconfig NO_IOPORT_MAP 2658c2ecf20Sopenharmony_ci def_bool y if !PCI 2668c2ecf20Sopenharmony_ci 2678c2ecf20Sopenharmony_ciconfig STACKTRACE_SUPPORT 2688c2ecf20Sopenharmony_ci def_bool y 2698c2ecf20Sopenharmony_ci 2708c2ecf20Sopenharmony_ciconfig ILLEGAL_POINTER_VALUE 2718c2ecf20Sopenharmony_ci hex 2728c2ecf20Sopenharmony_ci default 0xdead000000000000 2738c2ecf20Sopenharmony_ci 2748c2ecf20Sopenharmony_ciconfig LOCKDEP_SUPPORT 2758c2ecf20Sopenharmony_ci def_bool y 2768c2ecf20Sopenharmony_ci 2778c2ecf20Sopenharmony_ciconfig TRACE_IRQFLAGS_SUPPORT 2788c2ecf20Sopenharmony_ci def_bool y 2798c2ecf20Sopenharmony_ci 2808c2ecf20Sopenharmony_ciconfig GENERIC_BUG 2818c2ecf20Sopenharmony_ci def_bool y 2828c2ecf20Sopenharmony_ci depends on BUG 2838c2ecf20Sopenharmony_ci 2848c2ecf20Sopenharmony_ciconfig GENERIC_BUG_RELATIVE_POINTERS 2858c2ecf20Sopenharmony_ci def_bool y 2868c2ecf20Sopenharmony_ci depends on GENERIC_BUG 2878c2ecf20Sopenharmony_ci 2888c2ecf20Sopenharmony_ciconfig GENERIC_HWEIGHT 2898c2ecf20Sopenharmony_ci def_bool y 2908c2ecf20Sopenharmony_ci 2918c2ecf20Sopenharmony_ciconfig GENERIC_CSUM 2928c2ecf20Sopenharmony_ci def_bool y 2938c2ecf20Sopenharmony_ci 2948c2ecf20Sopenharmony_ciconfig GENERIC_CALIBRATE_DELAY 2958c2ecf20Sopenharmony_ci def_bool y 2968c2ecf20Sopenharmony_ci 2978c2ecf20Sopenharmony_ciconfig ZONE_DMA 2988c2ecf20Sopenharmony_ci bool "Support DMA zone" if EXPERT 2998c2ecf20Sopenharmony_ci default y 3008c2ecf20Sopenharmony_ci 3018c2ecf20Sopenharmony_ciconfig ZONE_DMA32 3028c2ecf20Sopenharmony_ci bool "Support DMA32 zone" if EXPERT 3038c2ecf20Sopenharmony_ci default y 3048c2ecf20Sopenharmony_ci 3058c2ecf20Sopenharmony_ciconfig ARCH_ENABLE_MEMORY_HOTPLUG 3068c2ecf20Sopenharmony_ci def_bool y 3078c2ecf20Sopenharmony_ci 3088c2ecf20Sopenharmony_ciconfig ARCH_ENABLE_MEMORY_HOTREMOVE 3098c2ecf20Sopenharmony_ci def_bool y 3108c2ecf20Sopenharmony_ci 3118c2ecf20Sopenharmony_ciconfig SMP 3128c2ecf20Sopenharmony_ci def_bool y 3138c2ecf20Sopenharmony_ci 3148c2ecf20Sopenharmony_ciconfig KERNEL_MODE_NEON 3158c2ecf20Sopenharmony_ci def_bool y 3168c2ecf20Sopenharmony_ci 3178c2ecf20Sopenharmony_ciconfig FIX_EARLYCON_MEM 3188c2ecf20Sopenharmony_ci def_bool y 3198c2ecf20Sopenharmony_ci 3208c2ecf20Sopenharmony_ciconfig PGTABLE_LEVELS 3218c2ecf20Sopenharmony_ci int 3228c2ecf20Sopenharmony_ci default 2 if ARM64_16K_PAGES && ARM64_VA_BITS_36 3238c2ecf20Sopenharmony_ci default 2 if ARM64_64K_PAGES && ARM64_VA_BITS_42 3248c2ecf20Sopenharmony_ci default 3 if ARM64_64K_PAGES && (ARM64_VA_BITS_48 || ARM64_VA_BITS_52) 3258c2ecf20Sopenharmony_ci default 3 if ARM64_4K_PAGES && ARM64_VA_BITS_39 3268c2ecf20Sopenharmony_ci default 3 if ARM64_16K_PAGES && ARM64_VA_BITS_47 3278c2ecf20Sopenharmony_ci default 4 if !ARM64_64K_PAGES && ARM64_VA_BITS_48 3288c2ecf20Sopenharmony_ci 3298c2ecf20Sopenharmony_ciconfig ARCH_SUPPORTS_UPROBES 3308c2ecf20Sopenharmony_ci def_bool y 3318c2ecf20Sopenharmony_ci 3328c2ecf20Sopenharmony_ciconfig ARCH_PROC_KCORE_TEXT 3338c2ecf20Sopenharmony_ci def_bool y 3348c2ecf20Sopenharmony_ci 3358c2ecf20Sopenharmony_ciconfig BROKEN_GAS_INST 3368c2ecf20Sopenharmony_ci def_bool !$(as-instr,1:\n.inst 0\n.rept . - 1b\n\nnop\n.endr\n) 3378c2ecf20Sopenharmony_ci 3388c2ecf20Sopenharmony_ciconfig KASAN_SHADOW_OFFSET 3398c2ecf20Sopenharmony_ci hex 3408c2ecf20Sopenharmony_ci depends on KASAN 3418c2ecf20Sopenharmony_ci default 0xdfffa00000000000 if (ARM64_VA_BITS_48 || ARM64_VA_BITS_52) && !KASAN_SW_TAGS 3428c2ecf20Sopenharmony_ci default 0xdfffd00000000000 if ARM64_VA_BITS_47 && !KASAN_SW_TAGS 3438c2ecf20Sopenharmony_ci default 0xdffffe8000000000 if ARM64_VA_BITS_42 && !KASAN_SW_TAGS 3448c2ecf20Sopenharmony_ci default 0xdfffffd000000000 if ARM64_VA_BITS_39 && !KASAN_SW_TAGS 3458c2ecf20Sopenharmony_ci default 0xdffffffa00000000 if ARM64_VA_BITS_36 && !KASAN_SW_TAGS 3468c2ecf20Sopenharmony_ci default 0xefff900000000000 if (ARM64_VA_BITS_48 || ARM64_VA_BITS_52) && KASAN_SW_TAGS 3478c2ecf20Sopenharmony_ci default 0xefffc80000000000 if ARM64_VA_BITS_47 && KASAN_SW_TAGS 3488c2ecf20Sopenharmony_ci default 0xeffffe4000000000 if ARM64_VA_BITS_42 && KASAN_SW_TAGS 3498c2ecf20Sopenharmony_ci default 0xefffffc800000000 if ARM64_VA_BITS_39 && KASAN_SW_TAGS 3508c2ecf20Sopenharmony_ci default 0xeffffff900000000 if ARM64_VA_BITS_36 && KASAN_SW_TAGS 3518c2ecf20Sopenharmony_ci default 0xffffffffffffffff 3528c2ecf20Sopenharmony_ci 3538c2ecf20Sopenharmony_cisource "arch/arm64/Kconfig.platforms" 3548c2ecf20Sopenharmony_ci 3558c2ecf20Sopenharmony_cimenu "Kernel Features" 3568c2ecf20Sopenharmony_ci 3578c2ecf20Sopenharmony_cimenu "ARM errata workarounds via the alternatives framework" 3588c2ecf20Sopenharmony_ci 3598c2ecf20Sopenharmony_ciconfig ARM64_WORKAROUND_CLEAN_CACHE 3608c2ecf20Sopenharmony_ci bool 3618c2ecf20Sopenharmony_ci 3628c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_826319 3638c2ecf20Sopenharmony_ci bool "Cortex-A53: 826319: System might deadlock if a write cannot complete until read data is accepted" 3648c2ecf20Sopenharmony_ci default y 3658c2ecf20Sopenharmony_ci select ARM64_WORKAROUND_CLEAN_CACHE 3668c2ecf20Sopenharmony_ci help 3678c2ecf20Sopenharmony_ci This option adds an alternative code sequence to work around ARM 3688c2ecf20Sopenharmony_ci erratum 826319 on Cortex-A53 parts up to r0p2 with an AMBA 4 ACE or 3698c2ecf20Sopenharmony_ci AXI master interface and an L2 cache. 3708c2ecf20Sopenharmony_ci 3718c2ecf20Sopenharmony_ci If a Cortex-A53 uses an AMBA AXI4 ACE interface to other processors 3728c2ecf20Sopenharmony_ci and is unable to accept a certain write via this interface, it will 3738c2ecf20Sopenharmony_ci not progress on read data presented on the read data channel and the 3748c2ecf20Sopenharmony_ci system can deadlock. 3758c2ecf20Sopenharmony_ci 3768c2ecf20Sopenharmony_ci The workaround promotes data cache clean instructions to 3778c2ecf20Sopenharmony_ci data cache clean-and-invalidate. 3788c2ecf20Sopenharmony_ci Please note that this does not necessarily enable the workaround, 3798c2ecf20Sopenharmony_ci as it depends on the alternative framework, which will only patch 3808c2ecf20Sopenharmony_ci the kernel if an affected CPU is detected. 3818c2ecf20Sopenharmony_ci 3828c2ecf20Sopenharmony_ci If unsure, say Y. 3838c2ecf20Sopenharmony_ci 3848c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_827319 3858c2ecf20Sopenharmony_ci bool "Cortex-A53: 827319: Data cache clean instructions might cause overlapping transactions to the interconnect" 3868c2ecf20Sopenharmony_ci default y 3878c2ecf20Sopenharmony_ci select ARM64_WORKAROUND_CLEAN_CACHE 3888c2ecf20Sopenharmony_ci help 3898c2ecf20Sopenharmony_ci This option adds an alternative code sequence to work around ARM 3908c2ecf20Sopenharmony_ci erratum 827319 on Cortex-A53 parts up to r0p2 with an AMBA 5 CHI 3918c2ecf20Sopenharmony_ci master interface and an L2 cache. 3928c2ecf20Sopenharmony_ci 3938c2ecf20Sopenharmony_ci Under certain conditions this erratum can cause a clean line eviction 3948c2ecf20Sopenharmony_ci to occur at the same time as another transaction to the same address 3958c2ecf20Sopenharmony_ci on the AMBA 5 CHI interface, which can cause data corruption if the 3968c2ecf20Sopenharmony_ci interconnect reorders the two transactions. 3978c2ecf20Sopenharmony_ci 3988c2ecf20Sopenharmony_ci The workaround promotes data cache clean instructions to 3998c2ecf20Sopenharmony_ci data cache clean-and-invalidate. 4008c2ecf20Sopenharmony_ci Please note that this does not necessarily enable the workaround, 4018c2ecf20Sopenharmony_ci as it depends on the alternative framework, which will only patch 4028c2ecf20Sopenharmony_ci the kernel if an affected CPU is detected. 4038c2ecf20Sopenharmony_ci 4048c2ecf20Sopenharmony_ci If unsure, say Y. 4058c2ecf20Sopenharmony_ci 4068c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_824069 4078c2ecf20Sopenharmony_ci bool "Cortex-A53: 824069: Cache line might not be marked as clean after a CleanShared snoop" 4088c2ecf20Sopenharmony_ci default y 4098c2ecf20Sopenharmony_ci select ARM64_WORKAROUND_CLEAN_CACHE 4108c2ecf20Sopenharmony_ci help 4118c2ecf20Sopenharmony_ci This option adds an alternative code sequence to work around ARM 4128c2ecf20Sopenharmony_ci erratum 824069 on Cortex-A53 parts up to r0p2 when it is connected 4138c2ecf20Sopenharmony_ci to a coherent interconnect. 4148c2ecf20Sopenharmony_ci 4158c2ecf20Sopenharmony_ci If a Cortex-A53 processor is executing a store or prefetch for 4168c2ecf20Sopenharmony_ci write instruction at the same time as a processor in another 4178c2ecf20Sopenharmony_ci cluster is executing a cache maintenance operation to the same 4188c2ecf20Sopenharmony_ci address, then this erratum might cause a clean cache line to be 4198c2ecf20Sopenharmony_ci incorrectly marked as dirty. 4208c2ecf20Sopenharmony_ci 4218c2ecf20Sopenharmony_ci The workaround promotes data cache clean instructions to 4228c2ecf20Sopenharmony_ci data cache clean-and-invalidate. 4238c2ecf20Sopenharmony_ci Please note that this option does not necessarily enable the 4248c2ecf20Sopenharmony_ci workaround, as it depends on the alternative framework, which will 4258c2ecf20Sopenharmony_ci only patch the kernel if an affected CPU is detected. 4268c2ecf20Sopenharmony_ci 4278c2ecf20Sopenharmony_ci If unsure, say Y. 4288c2ecf20Sopenharmony_ci 4298c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_819472 4308c2ecf20Sopenharmony_ci bool "Cortex-A53: 819472: Store exclusive instructions might cause data corruption" 4318c2ecf20Sopenharmony_ci default y 4328c2ecf20Sopenharmony_ci select ARM64_WORKAROUND_CLEAN_CACHE 4338c2ecf20Sopenharmony_ci help 4348c2ecf20Sopenharmony_ci This option adds an alternative code sequence to work around ARM 4358c2ecf20Sopenharmony_ci erratum 819472 on Cortex-A53 parts up to r0p1 with an L2 cache 4368c2ecf20Sopenharmony_ci present when it is connected to a coherent interconnect. 4378c2ecf20Sopenharmony_ci 4388c2ecf20Sopenharmony_ci If the processor is executing a load and store exclusive sequence at 4398c2ecf20Sopenharmony_ci the same time as a processor in another cluster is executing a cache 4408c2ecf20Sopenharmony_ci maintenance operation to the same address, then this erratum might 4418c2ecf20Sopenharmony_ci cause data corruption. 4428c2ecf20Sopenharmony_ci 4438c2ecf20Sopenharmony_ci The workaround promotes data cache clean instructions to 4448c2ecf20Sopenharmony_ci data cache clean-and-invalidate. 4458c2ecf20Sopenharmony_ci Please note that this does not necessarily enable the workaround, 4468c2ecf20Sopenharmony_ci as it depends on the alternative framework, which will only patch 4478c2ecf20Sopenharmony_ci the kernel if an affected CPU is detected. 4488c2ecf20Sopenharmony_ci 4498c2ecf20Sopenharmony_ci If unsure, say Y. 4508c2ecf20Sopenharmony_ci 4518c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_832075 4528c2ecf20Sopenharmony_ci bool "Cortex-A57: 832075: possible deadlock on mixing exclusive memory accesses with device loads" 4538c2ecf20Sopenharmony_ci default y 4548c2ecf20Sopenharmony_ci help 4558c2ecf20Sopenharmony_ci This option adds an alternative code sequence to work around ARM 4568c2ecf20Sopenharmony_ci erratum 832075 on Cortex-A57 parts up to r1p2. 4578c2ecf20Sopenharmony_ci 4588c2ecf20Sopenharmony_ci Affected Cortex-A57 parts might deadlock when exclusive load/store 4598c2ecf20Sopenharmony_ci instructions to Write-Back memory are mixed with Device loads. 4608c2ecf20Sopenharmony_ci 4618c2ecf20Sopenharmony_ci The workaround is to promote device loads to use Load-Acquire 4628c2ecf20Sopenharmony_ci semantics. 4638c2ecf20Sopenharmony_ci Please note that this does not necessarily enable the workaround, 4648c2ecf20Sopenharmony_ci as it depends on the alternative framework, which will only patch 4658c2ecf20Sopenharmony_ci the kernel if an affected CPU is detected. 4668c2ecf20Sopenharmony_ci 4678c2ecf20Sopenharmony_ci If unsure, say Y. 4688c2ecf20Sopenharmony_ci 4698c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_834220 4708c2ecf20Sopenharmony_ci bool "Cortex-A57: 834220: Stage 2 translation fault might be incorrectly reported in presence of a Stage 1 fault" 4718c2ecf20Sopenharmony_ci depends on KVM 4728c2ecf20Sopenharmony_ci default y 4738c2ecf20Sopenharmony_ci help 4748c2ecf20Sopenharmony_ci This option adds an alternative code sequence to work around ARM 4758c2ecf20Sopenharmony_ci erratum 834220 on Cortex-A57 parts up to r1p2. 4768c2ecf20Sopenharmony_ci 4778c2ecf20Sopenharmony_ci Affected Cortex-A57 parts might report a Stage 2 translation 4788c2ecf20Sopenharmony_ci fault as the result of a Stage 1 fault for load crossing a 4798c2ecf20Sopenharmony_ci page boundary when there is a permission or device memory 4808c2ecf20Sopenharmony_ci alignment fault at Stage 1 and a translation fault at Stage 2. 4818c2ecf20Sopenharmony_ci 4828c2ecf20Sopenharmony_ci The workaround is to verify that the Stage 1 translation 4838c2ecf20Sopenharmony_ci doesn't generate a fault before handling the Stage 2 fault. 4848c2ecf20Sopenharmony_ci Please note that this does not necessarily enable the workaround, 4858c2ecf20Sopenharmony_ci as it depends on the alternative framework, which will only patch 4868c2ecf20Sopenharmony_ci the kernel if an affected CPU is detected. 4878c2ecf20Sopenharmony_ci 4888c2ecf20Sopenharmony_ci If unsure, say Y. 4898c2ecf20Sopenharmony_ci 4908c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_1742098 4918c2ecf20Sopenharmony_ci bool "Cortex-A57/A72: 1742098: ELR recorded incorrectly on interrupt taken between cryptographic instructions in a sequence" 4928c2ecf20Sopenharmony_ci depends on COMPAT 4938c2ecf20Sopenharmony_ci default y 4948c2ecf20Sopenharmony_ci help 4958c2ecf20Sopenharmony_ci This option removes the AES hwcap for aarch32 user-space to 4968c2ecf20Sopenharmony_ci workaround erratum 1742098 on Cortex-A57 and Cortex-A72. 4978c2ecf20Sopenharmony_ci 4988c2ecf20Sopenharmony_ci Affected parts may corrupt the AES state if an interrupt is 4998c2ecf20Sopenharmony_ci taken between a pair of AES instructions. These instructions 5008c2ecf20Sopenharmony_ci are only present if the cryptography extensions are present. 5018c2ecf20Sopenharmony_ci All software should have a fallback implementation for CPUs 5028c2ecf20Sopenharmony_ci that don't implement the cryptography extensions. 5038c2ecf20Sopenharmony_ci 5048c2ecf20Sopenharmony_ci If unsure, say Y. 5058c2ecf20Sopenharmony_ci 5068c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_845719 5078c2ecf20Sopenharmony_ci bool "Cortex-A53: 845719: a load might read incorrect data" 5088c2ecf20Sopenharmony_ci depends on COMPAT 5098c2ecf20Sopenharmony_ci default y 5108c2ecf20Sopenharmony_ci help 5118c2ecf20Sopenharmony_ci This option adds an alternative code sequence to work around ARM 5128c2ecf20Sopenharmony_ci erratum 845719 on Cortex-A53 parts up to r0p4. 5138c2ecf20Sopenharmony_ci 5148c2ecf20Sopenharmony_ci When running a compat (AArch32) userspace on an affected Cortex-A53 5158c2ecf20Sopenharmony_ci part, a load at EL0 from a virtual address that matches the bottom 32 5168c2ecf20Sopenharmony_ci bits of the virtual address used by a recent load at (AArch64) EL1 5178c2ecf20Sopenharmony_ci might return incorrect data. 5188c2ecf20Sopenharmony_ci 5198c2ecf20Sopenharmony_ci The workaround is to write the contextidr_el1 register on exception 5208c2ecf20Sopenharmony_ci return to a 32-bit task. 5218c2ecf20Sopenharmony_ci Please note that this does not necessarily enable the workaround, 5228c2ecf20Sopenharmony_ci as it depends on the alternative framework, which will only patch 5238c2ecf20Sopenharmony_ci the kernel if an affected CPU is detected. 5248c2ecf20Sopenharmony_ci 5258c2ecf20Sopenharmony_ci If unsure, say Y. 5268c2ecf20Sopenharmony_ci 5278c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_843419 5288c2ecf20Sopenharmony_ci bool "Cortex-A53: 843419: A load or store might access an incorrect address" 5298c2ecf20Sopenharmony_ci default y 5308c2ecf20Sopenharmony_ci select ARM64_MODULE_PLTS if MODULES 5318c2ecf20Sopenharmony_ci help 5328c2ecf20Sopenharmony_ci This option links the kernel with '--fix-cortex-a53-843419' and 5338c2ecf20Sopenharmony_ci enables PLT support to replace certain ADRP instructions, which can 5348c2ecf20Sopenharmony_ci cause subsequent memory accesses to use an incorrect address on 5358c2ecf20Sopenharmony_ci Cortex-A53 parts up to r0p4. 5368c2ecf20Sopenharmony_ci 5378c2ecf20Sopenharmony_ci If unsure, say Y. 5388c2ecf20Sopenharmony_ci 5398c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_1024718 5408c2ecf20Sopenharmony_ci bool "Cortex-A55: 1024718: Update of DBM/AP bits without break before make might result in incorrect update" 5418c2ecf20Sopenharmony_ci default y 5428c2ecf20Sopenharmony_ci help 5438c2ecf20Sopenharmony_ci This option adds a workaround for ARM Cortex-A55 Erratum 1024718. 5448c2ecf20Sopenharmony_ci 5458c2ecf20Sopenharmony_ci Affected Cortex-A55 cores (all revisions) could cause incorrect 5468c2ecf20Sopenharmony_ci update of the hardware dirty bit when the DBM/AP bits are updated 5478c2ecf20Sopenharmony_ci without a break-before-make. The workaround is to disable the usage 5488c2ecf20Sopenharmony_ci of hardware DBM locally on the affected cores. CPUs not affected by 5498c2ecf20Sopenharmony_ci this erratum will continue to use the feature. 5508c2ecf20Sopenharmony_ci 5518c2ecf20Sopenharmony_ci If unsure, say Y. 5528c2ecf20Sopenharmony_ci 5538c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_1418040 5548c2ecf20Sopenharmony_ci bool "Cortex-A76/Neoverse-N1: MRC read following MRRC read of specific Generic Timer in AArch32 might give incorrect result" 5558c2ecf20Sopenharmony_ci default y 5568c2ecf20Sopenharmony_ci depends on COMPAT 5578c2ecf20Sopenharmony_ci help 5588c2ecf20Sopenharmony_ci This option adds a workaround for ARM Cortex-A76/Neoverse-N1 5598c2ecf20Sopenharmony_ci errata 1188873 and 1418040. 5608c2ecf20Sopenharmony_ci 5618c2ecf20Sopenharmony_ci Affected Cortex-A76/Neoverse-N1 cores (r0p0 to r3p1) could 5628c2ecf20Sopenharmony_ci cause register corruption when accessing the timer registers 5638c2ecf20Sopenharmony_ci from AArch32 userspace. 5648c2ecf20Sopenharmony_ci 5658c2ecf20Sopenharmony_ci If unsure, say Y. 5668c2ecf20Sopenharmony_ci 5678c2ecf20Sopenharmony_ciconfig ARM64_WORKAROUND_SPECULATIVE_AT 5688c2ecf20Sopenharmony_ci bool 5698c2ecf20Sopenharmony_ci 5708c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_1165522 5718c2ecf20Sopenharmony_ci bool "Cortex-A76: 1165522: Speculative AT instruction using out-of-context translation regime could cause subsequent request to generate an incorrect translation" 5728c2ecf20Sopenharmony_ci default y 5738c2ecf20Sopenharmony_ci select ARM64_WORKAROUND_SPECULATIVE_AT 5748c2ecf20Sopenharmony_ci help 5758c2ecf20Sopenharmony_ci This option adds a workaround for ARM Cortex-A76 erratum 1165522. 5768c2ecf20Sopenharmony_ci 5778c2ecf20Sopenharmony_ci Affected Cortex-A76 cores (r0p0, r1p0, r2p0) could end-up with 5788c2ecf20Sopenharmony_ci corrupted TLBs by speculating an AT instruction during a guest 5798c2ecf20Sopenharmony_ci context switch. 5808c2ecf20Sopenharmony_ci 5818c2ecf20Sopenharmony_ci If unsure, say Y. 5828c2ecf20Sopenharmony_ci 5838c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_1319367 5848c2ecf20Sopenharmony_ci bool "Cortex-A57/A72: 1319537: Speculative AT instruction using out-of-context translation regime could cause subsequent request to generate an incorrect translation" 5858c2ecf20Sopenharmony_ci default y 5868c2ecf20Sopenharmony_ci select ARM64_WORKAROUND_SPECULATIVE_AT 5878c2ecf20Sopenharmony_ci help 5888c2ecf20Sopenharmony_ci This option adds work arounds for ARM Cortex-A57 erratum 1319537 5898c2ecf20Sopenharmony_ci and A72 erratum 1319367 5908c2ecf20Sopenharmony_ci 5918c2ecf20Sopenharmony_ci Cortex-A57 and A72 cores could end-up with corrupted TLBs by 5928c2ecf20Sopenharmony_ci speculating an AT instruction during a guest context switch. 5938c2ecf20Sopenharmony_ci 5948c2ecf20Sopenharmony_ci If unsure, say Y. 5958c2ecf20Sopenharmony_ci 5968c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_1530923 5978c2ecf20Sopenharmony_ci bool "Cortex-A55: 1530923: Speculative AT instruction using out-of-context translation regime could cause subsequent request to generate an incorrect translation" 5988c2ecf20Sopenharmony_ci default y 5998c2ecf20Sopenharmony_ci select ARM64_WORKAROUND_SPECULATIVE_AT 6008c2ecf20Sopenharmony_ci help 6018c2ecf20Sopenharmony_ci This option adds a workaround for ARM Cortex-A55 erratum 1530923. 6028c2ecf20Sopenharmony_ci 6038c2ecf20Sopenharmony_ci Affected Cortex-A55 cores (r0p0, r0p1, r1p0, r2p0) could end-up with 6048c2ecf20Sopenharmony_ci corrupted TLBs by speculating an AT instruction during a guest 6058c2ecf20Sopenharmony_ci context switch. 6068c2ecf20Sopenharmony_ci 6078c2ecf20Sopenharmony_ci If unsure, say Y. 6088c2ecf20Sopenharmony_ci 6098c2ecf20Sopenharmony_ciconfig ARM64_WORKAROUND_REPEAT_TLBI 6108c2ecf20Sopenharmony_ci bool 6118c2ecf20Sopenharmony_ci 6128c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_1286807 6138c2ecf20Sopenharmony_ci bool "Cortex-A76: Modification of the translation table for a virtual address might lead to read-after-read ordering violation" 6148c2ecf20Sopenharmony_ci default y 6158c2ecf20Sopenharmony_ci select ARM64_WORKAROUND_REPEAT_TLBI 6168c2ecf20Sopenharmony_ci help 6178c2ecf20Sopenharmony_ci This option adds a workaround for ARM Cortex-A76 erratum 1286807. 6188c2ecf20Sopenharmony_ci 6198c2ecf20Sopenharmony_ci On the affected Cortex-A76 cores (r0p0 to r3p0), if a virtual 6208c2ecf20Sopenharmony_ci address for a cacheable mapping of a location is being 6218c2ecf20Sopenharmony_ci accessed by a core while another core is remapping the virtual 6228c2ecf20Sopenharmony_ci address to a new physical page using the recommended 6238c2ecf20Sopenharmony_ci break-before-make sequence, then under very rare circumstances 6248c2ecf20Sopenharmony_ci TLBI+DSB completes before a read using the translation being 6258c2ecf20Sopenharmony_ci invalidated has been observed by other observers. The 6268c2ecf20Sopenharmony_ci workaround repeats the TLBI+DSB operation. 6278c2ecf20Sopenharmony_ci 6288c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_1463225 6298c2ecf20Sopenharmony_ci bool "Cortex-A76: Software Step might prevent interrupt recognition" 6308c2ecf20Sopenharmony_ci default y 6318c2ecf20Sopenharmony_ci help 6328c2ecf20Sopenharmony_ci This option adds a workaround for Arm Cortex-A76 erratum 1463225. 6338c2ecf20Sopenharmony_ci 6348c2ecf20Sopenharmony_ci On the affected Cortex-A76 cores (r0p0 to r3p1), software stepping 6358c2ecf20Sopenharmony_ci of a system call instruction (SVC) can prevent recognition of 6368c2ecf20Sopenharmony_ci subsequent interrupts when software stepping is disabled in the 6378c2ecf20Sopenharmony_ci exception handler of the system call and either kernel debugging 6388c2ecf20Sopenharmony_ci is enabled or VHE is in use. 6398c2ecf20Sopenharmony_ci 6408c2ecf20Sopenharmony_ci Work around the erratum by triggering a dummy step exception 6418c2ecf20Sopenharmony_ci when handling a system call from a task that is being stepped 6428c2ecf20Sopenharmony_ci in a VHE configuration of the kernel. 6438c2ecf20Sopenharmony_ci 6448c2ecf20Sopenharmony_ci If unsure, say Y. 6458c2ecf20Sopenharmony_ci 6468c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_1542419 6478c2ecf20Sopenharmony_ci bool "Neoverse-N1: workaround mis-ordering of instruction fetches" 6488c2ecf20Sopenharmony_ci default y 6498c2ecf20Sopenharmony_ci help 6508c2ecf20Sopenharmony_ci This option adds a workaround for ARM Neoverse-N1 erratum 6518c2ecf20Sopenharmony_ci 1542419. 6528c2ecf20Sopenharmony_ci 6538c2ecf20Sopenharmony_ci Affected Neoverse-N1 cores could execute a stale instruction when 6548c2ecf20Sopenharmony_ci modified by another CPU. The workaround depends on a firmware 6558c2ecf20Sopenharmony_ci counterpart. 6568c2ecf20Sopenharmony_ci 6578c2ecf20Sopenharmony_ci Workaround the issue by hiding the DIC feature from EL0. This 6588c2ecf20Sopenharmony_ci forces user-space to perform cache maintenance. 6598c2ecf20Sopenharmony_ci 6608c2ecf20Sopenharmony_ci If unsure, say Y. 6618c2ecf20Sopenharmony_ci 6628c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_1508412 6638c2ecf20Sopenharmony_ci bool "Cortex-A77: 1508412: workaround deadlock on sequence of NC/Device load and store exclusive or PAR read" 6648c2ecf20Sopenharmony_ci default y 6658c2ecf20Sopenharmony_ci help 6668c2ecf20Sopenharmony_ci This option adds a workaround for Arm Cortex-A77 erratum 1508412. 6678c2ecf20Sopenharmony_ci 6688c2ecf20Sopenharmony_ci Affected Cortex-A77 cores (r0p0, r1p0) could deadlock on a sequence 6698c2ecf20Sopenharmony_ci of a store-exclusive or read of PAR_EL1 and a load with device or 6708c2ecf20Sopenharmony_ci non-cacheable memory attributes. The workaround depends on a firmware 6718c2ecf20Sopenharmony_ci counterpart. 6728c2ecf20Sopenharmony_ci 6738c2ecf20Sopenharmony_ci KVM guests must also have the workaround implemented or they can 6748c2ecf20Sopenharmony_ci deadlock the system. 6758c2ecf20Sopenharmony_ci 6768c2ecf20Sopenharmony_ci Work around the issue by inserting DMB SY barriers around PAR_EL1 6778c2ecf20Sopenharmony_ci register reads and warning KVM users. The DMB barrier is sufficient 6788c2ecf20Sopenharmony_ci to prevent a speculative PAR_EL1 read. 6798c2ecf20Sopenharmony_ci 6808c2ecf20Sopenharmony_ci If unsure, say Y. 6818c2ecf20Sopenharmony_ci 6828c2ecf20Sopenharmony_ciconfig ARM64_ERRATUM_2457168 6838c2ecf20Sopenharmony_ci bool "Cortex-A510: 2457168: workaround for AMEVCNTR01 incrementing incorrectly" 6848c2ecf20Sopenharmony_ci depends on ARM64_AMU_EXTN 6858c2ecf20Sopenharmony_ci default y 6868c2ecf20Sopenharmony_ci help 6878c2ecf20Sopenharmony_ci This option adds the workaround for ARM Cortex-A510 erratum 2457168. 6888c2ecf20Sopenharmony_ci 6898c2ecf20Sopenharmony_ci The AMU counter AMEVCNTR01 (constant counter) should increment at the same rate 6908c2ecf20Sopenharmony_ci as the system counter. On affected Cortex-A510 cores AMEVCNTR01 increments 6918c2ecf20Sopenharmony_ci incorrectly giving a significantly higher output value. 6928c2ecf20Sopenharmony_ci 6938c2ecf20Sopenharmony_ci Work around this problem by keeping the reference values of affected counters 6948c2ecf20Sopenharmony_ci to 0 thus signaling an error case. This effect is the same to firmware disabling 6958c2ecf20Sopenharmony_ci affected counters, in which case 0 will be returned when reading the disabled 6968c2ecf20Sopenharmony_ci counters. 6978c2ecf20Sopenharmony_ci 6988c2ecf20Sopenharmony_ci If unsure, say Y. 6998c2ecf20Sopenharmony_ci 7008c2ecf20Sopenharmony_ciconfig CAVIUM_ERRATUM_22375 7018c2ecf20Sopenharmony_ci bool "Cavium erratum 22375, 24313" 7028c2ecf20Sopenharmony_ci default y 7038c2ecf20Sopenharmony_ci help 7048c2ecf20Sopenharmony_ci Enable workaround for errata 22375 and 24313. 7058c2ecf20Sopenharmony_ci 7068c2ecf20Sopenharmony_ci This implements two gicv3-its errata workarounds for ThunderX. Both 7078c2ecf20Sopenharmony_ci with a small impact affecting only ITS table allocation. 7088c2ecf20Sopenharmony_ci 7098c2ecf20Sopenharmony_ci erratum 22375: only alloc 8MB table size 7108c2ecf20Sopenharmony_ci erratum 24313: ignore memory access type 7118c2ecf20Sopenharmony_ci 7128c2ecf20Sopenharmony_ci The fixes are in ITS initialization and basically ignore memory access 7138c2ecf20Sopenharmony_ci type and table size provided by the TYPER and BASER registers. 7148c2ecf20Sopenharmony_ci 7158c2ecf20Sopenharmony_ci If unsure, say Y. 7168c2ecf20Sopenharmony_ci 7178c2ecf20Sopenharmony_ciconfig CAVIUM_ERRATUM_23144 7188c2ecf20Sopenharmony_ci bool "Cavium erratum 23144: ITS SYNC hang on dual socket system" 7198c2ecf20Sopenharmony_ci depends on NUMA 7208c2ecf20Sopenharmony_ci default y 7218c2ecf20Sopenharmony_ci help 7228c2ecf20Sopenharmony_ci ITS SYNC command hang for cross node io and collections/cpu mapping. 7238c2ecf20Sopenharmony_ci 7248c2ecf20Sopenharmony_ci If unsure, say Y. 7258c2ecf20Sopenharmony_ci 7268c2ecf20Sopenharmony_ciconfig CAVIUM_ERRATUM_23154 7278c2ecf20Sopenharmony_ci bool "Cavium erratum 23154: Access to ICC_IAR1_EL1 is not sync'ed" 7288c2ecf20Sopenharmony_ci default y 7298c2ecf20Sopenharmony_ci help 7308c2ecf20Sopenharmony_ci The gicv3 of ThunderX requires a modified version for 7318c2ecf20Sopenharmony_ci reading the IAR status to ensure data synchronization 7328c2ecf20Sopenharmony_ci (access to icc_iar1_el1 is not sync'ed before and after). 7338c2ecf20Sopenharmony_ci 7348c2ecf20Sopenharmony_ci If unsure, say Y. 7358c2ecf20Sopenharmony_ci 7368c2ecf20Sopenharmony_ciconfig CAVIUM_ERRATUM_27456 7378c2ecf20Sopenharmony_ci bool "Cavium erratum 27456: Broadcast TLBI instructions may cause icache corruption" 7388c2ecf20Sopenharmony_ci default y 7398c2ecf20Sopenharmony_ci help 7408c2ecf20Sopenharmony_ci On ThunderX T88 pass 1.x through 2.1 parts, broadcast TLBI 7418c2ecf20Sopenharmony_ci instructions may cause the icache to become corrupted if it 7428c2ecf20Sopenharmony_ci contains data for a non-current ASID. The fix is to 7438c2ecf20Sopenharmony_ci invalidate the icache when changing the mm context. 7448c2ecf20Sopenharmony_ci 7458c2ecf20Sopenharmony_ci If unsure, say Y. 7468c2ecf20Sopenharmony_ci 7478c2ecf20Sopenharmony_ciconfig CAVIUM_ERRATUM_30115 7488c2ecf20Sopenharmony_ci bool "Cavium erratum 30115: Guest may disable interrupts in host" 7498c2ecf20Sopenharmony_ci default y 7508c2ecf20Sopenharmony_ci help 7518c2ecf20Sopenharmony_ci On ThunderX T88 pass 1.x through 2.2, T81 pass 1.0 through 7528c2ecf20Sopenharmony_ci 1.2, and T83 Pass 1.0, KVM guest execution may disable 7538c2ecf20Sopenharmony_ci interrupts in host. Trapping both GICv3 group-0 and group-1 7548c2ecf20Sopenharmony_ci accesses sidesteps the issue. 7558c2ecf20Sopenharmony_ci 7568c2ecf20Sopenharmony_ci If unsure, say Y. 7578c2ecf20Sopenharmony_ci 7588c2ecf20Sopenharmony_ciconfig CAVIUM_TX2_ERRATUM_219 7598c2ecf20Sopenharmony_ci bool "Cavium ThunderX2 erratum 219: PRFM between TTBR change and ISB fails" 7608c2ecf20Sopenharmony_ci default y 7618c2ecf20Sopenharmony_ci help 7628c2ecf20Sopenharmony_ci On Cavium ThunderX2, a load, store or prefetch instruction between a 7638c2ecf20Sopenharmony_ci TTBR update and the corresponding context synchronizing operation can 7648c2ecf20Sopenharmony_ci cause a spurious Data Abort to be delivered to any hardware thread in 7658c2ecf20Sopenharmony_ci the CPU core. 7668c2ecf20Sopenharmony_ci 7678c2ecf20Sopenharmony_ci Work around the issue by avoiding the problematic code sequence and 7688c2ecf20Sopenharmony_ci trapping KVM guest TTBRx_EL1 writes to EL2 when SMT is enabled. The 7698c2ecf20Sopenharmony_ci trap handler performs the corresponding register access, skips the 7708c2ecf20Sopenharmony_ci instruction and ensures context synchronization by virtue of the 7718c2ecf20Sopenharmony_ci exception return. 7728c2ecf20Sopenharmony_ci 7738c2ecf20Sopenharmony_ci If unsure, say Y. 7748c2ecf20Sopenharmony_ci 7758c2ecf20Sopenharmony_ciconfig FUJITSU_ERRATUM_010001 7768c2ecf20Sopenharmony_ci bool "Fujitsu-A64FX erratum E#010001: Undefined fault may occur wrongly" 7778c2ecf20Sopenharmony_ci default y 7788c2ecf20Sopenharmony_ci help 7798c2ecf20Sopenharmony_ci This option adds a workaround for Fujitsu-A64FX erratum E#010001. 7808c2ecf20Sopenharmony_ci On some variants of the Fujitsu-A64FX cores ver(1.0, 1.1), memory 7818c2ecf20Sopenharmony_ci accesses may cause undefined fault (Data abort, DFSC=0b111111). 7828c2ecf20Sopenharmony_ci This fault occurs under a specific hardware condition when a 7838c2ecf20Sopenharmony_ci load/store instruction performs an address translation using: 7848c2ecf20Sopenharmony_ci case-1 TTBR0_EL1 with TCR_EL1.NFD0 == 1. 7858c2ecf20Sopenharmony_ci case-2 TTBR0_EL2 with TCR_EL2.NFD0 == 1. 7868c2ecf20Sopenharmony_ci case-3 TTBR1_EL1 with TCR_EL1.NFD1 == 1. 7878c2ecf20Sopenharmony_ci case-4 TTBR1_EL2 with TCR_EL2.NFD1 == 1. 7888c2ecf20Sopenharmony_ci 7898c2ecf20Sopenharmony_ci The workaround is to ensure these bits are clear in TCR_ELx. 7908c2ecf20Sopenharmony_ci The workaround only affects the Fujitsu-A64FX. 7918c2ecf20Sopenharmony_ci 7928c2ecf20Sopenharmony_ci If unsure, say Y. 7938c2ecf20Sopenharmony_ci 7948c2ecf20Sopenharmony_ciconfig HISILICON_ERRATUM_161600802 7958c2ecf20Sopenharmony_ci bool "Hip07 161600802: Erroneous redistributor VLPI base" 7968c2ecf20Sopenharmony_ci default y 7978c2ecf20Sopenharmony_ci help 7988c2ecf20Sopenharmony_ci The HiSilicon Hip07 SoC uses the wrong redistributor base 7998c2ecf20Sopenharmony_ci when issued ITS commands such as VMOVP and VMAPP, and requires 8008c2ecf20Sopenharmony_ci a 128kB offset to be applied to the target address in this commands. 8018c2ecf20Sopenharmony_ci 8028c2ecf20Sopenharmony_ci If unsure, say Y. 8038c2ecf20Sopenharmony_ci 8048c2ecf20Sopenharmony_ciconfig QCOM_FALKOR_ERRATUM_1003 8058c2ecf20Sopenharmony_ci bool "Falkor E1003: Incorrect translation due to ASID change" 8068c2ecf20Sopenharmony_ci default y 8078c2ecf20Sopenharmony_ci help 8088c2ecf20Sopenharmony_ci On Falkor v1, an incorrect ASID may be cached in the TLB when ASID 8098c2ecf20Sopenharmony_ci and BADDR are changed together in TTBRx_EL1. Since we keep the ASID 8108c2ecf20Sopenharmony_ci in TTBR1_EL1, this situation only occurs in the entry trampoline and 8118c2ecf20Sopenharmony_ci then only for entries in the walk cache, since the leaf translation 8128c2ecf20Sopenharmony_ci is unchanged. Work around the erratum by invalidating the walk cache 8138c2ecf20Sopenharmony_ci entries for the trampoline before entering the kernel proper. 8148c2ecf20Sopenharmony_ci 8158c2ecf20Sopenharmony_ciconfig QCOM_FALKOR_ERRATUM_1009 8168c2ecf20Sopenharmony_ci bool "Falkor E1009: Prematurely complete a DSB after a TLBI" 8178c2ecf20Sopenharmony_ci default y 8188c2ecf20Sopenharmony_ci select ARM64_WORKAROUND_REPEAT_TLBI 8198c2ecf20Sopenharmony_ci help 8208c2ecf20Sopenharmony_ci On Falkor v1, the CPU may prematurely complete a DSB following a 8218c2ecf20Sopenharmony_ci TLBI xxIS invalidate maintenance operation. Repeat the TLBI operation 8228c2ecf20Sopenharmony_ci one more time to fix the issue. 8238c2ecf20Sopenharmony_ci 8248c2ecf20Sopenharmony_ci If unsure, say Y. 8258c2ecf20Sopenharmony_ci 8268c2ecf20Sopenharmony_ciconfig QCOM_QDF2400_ERRATUM_0065 8278c2ecf20Sopenharmony_ci bool "QDF2400 E0065: Incorrect GITS_TYPER.ITT_Entry_size" 8288c2ecf20Sopenharmony_ci default y 8298c2ecf20Sopenharmony_ci help 8308c2ecf20Sopenharmony_ci On Qualcomm Datacenter Technologies QDF2400 SoC, ITS hardware reports 8318c2ecf20Sopenharmony_ci ITE size incorrectly. The GITS_TYPER.ITT_Entry_size field should have 8328c2ecf20Sopenharmony_ci been indicated as 16Bytes (0xf), not 8Bytes (0x7). 8338c2ecf20Sopenharmony_ci 8348c2ecf20Sopenharmony_ci If unsure, say Y. 8358c2ecf20Sopenharmony_ci 8368c2ecf20Sopenharmony_ciconfig QCOM_FALKOR_ERRATUM_E1041 8378c2ecf20Sopenharmony_ci bool "Falkor E1041: Speculative instruction fetches might cause errant memory access" 8388c2ecf20Sopenharmony_ci default y 8398c2ecf20Sopenharmony_ci help 8408c2ecf20Sopenharmony_ci Falkor CPU may speculatively fetch instructions from an improper 8418c2ecf20Sopenharmony_ci memory location when MMU translation is changed from SCTLR_ELn[M]=1 8428c2ecf20Sopenharmony_ci to SCTLR_ELn[M]=0. Prefix an ISB instruction to fix the problem. 8438c2ecf20Sopenharmony_ci 8448c2ecf20Sopenharmony_ci If unsure, say Y. 8458c2ecf20Sopenharmony_ci 8468c2ecf20Sopenharmony_ciconfig SOCIONEXT_SYNQUACER_PREITS 8478c2ecf20Sopenharmony_ci bool "Socionext Synquacer: Workaround for GICv3 pre-ITS" 8488c2ecf20Sopenharmony_ci default y 8498c2ecf20Sopenharmony_ci help 8508c2ecf20Sopenharmony_ci Socionext Synquacer SoCs implement a separate h/w block to generate 8518c2ecf20Sopenharmony_ci MSI doorbell writes with non-zero values for the device ID. 8528c2ecf20Sopenharmony_ci 8538c2ecf20Sopenharmony_ci If unsure, say Y. 8548c2ecf20Sopenharmony_ci 8558c2ecf20Sopenharmony_ciendmenu 8568c2ecf20Sopenharmony_ci 8578c2ecf20Sopenharmony_ci 8588c2ecf20Sopenharmony_cichoice 8598c2ecf20Sopenharmony_ci prompt "Page size" 8608c2ecf20Sopenharmony_ci default ARM64_4K_PAGES 8618c2ecf20Sopenharmony_ci help 8628c2ecf20Sopenharmony_ci Page size (translation granule) configuration. 8638c2ecf20Sopenharmony_ci 8648c2ecf20Sopenharmony_ciconfig ARM64_4K_PAGES 8658c2ecf20Sopenharmony_ci bool "4KB" 8668c2ecf20Sopenharmony_ci help 8678c2ecf20Sopenharmony_ci This feature enables 4KB pages support. 8688c2ecf20Sopenharmony_ci 8698c2ecf20Sopenharmony_ciconfig ARM64_16K_PAGES 8708c2ecf20Sopenharmony_ci bool "16KB" 8718c2ecf20Sopenharmony_ci help 8728c2ecf20Sopenharmony_ci The system will use 16KB pages support. AArch32 emulation 8738c2ecf20Sopenharmony_ci requires applications compiled with 16K (or a multiple of 16K) 8748c2ecf20Sopenharmony_ci aligned segments. 8758c2ecf20Sopenharmony_ci 8768c2ecf20Sopenharmony_ciconfig ARM64_64K_PAGES 8778c2ecf20Sopenharmony_ci bool "64KB" 8788c2ecf20Sopenharmony_ci help 8798c2ecf20Sopenharmony_ci This feature enables 64KB pages support (4KB by default) 8808c2ecf20Sopenharmony_ci allowing only two levels of page tables and faster TLB 8818c2ecf20Sopenharmony_ci look-up. AArch32 emulation requires applications compiled 8828c2ecf20Sopenharmony_ci with 64K aligned segments. 8838c2ecf20Sopenharmony_ci 8848c2ecf20Sopenharmony_ciendchoice 8858c2ecf20Sopenharmony_ci 8868c2ecf20Sopenharmony_cichoice 8878c2ecf20Sopenharmony_ci prompt "Virtual address space size" 8888c2ecf20Sopenharmony_ci default ARM64_VA_BITS_39 if ARM64_4K_PAGES 8898c2ecf20Sopenharmony_ci default ARM64_VA_BITS_47 if ARM64_16K_PAGES 8908c2ecf20Sopenharmony_ci default ARM64_VA_BITS_42 if ARM64_64K_PAGES 8918c2ecf20Sopenharmony_ci help 8928c2ecf20Sopenharmony_ci Allows choosing one of multiple possible virtual address 8938c2ecf20Sopenharmony_ci space sizes. The level of translation table is determined by 8948c2ecf20Sopenharmony_ci a combination of page size and virtual address space size. 8958c2ecf20Sopenharmony_ci 8968c2ecf20Sopenharmony_ciconfig ARM64_VA_BITS_36 8978c2ecf20Sopenharmony_ci bool "36-bit" if EXPERT 8988c2ecf20Sopenharmony_ci depends on ARM64_16K_PAGES 8998c2ecf20Sopenharmony_ci 9008c2ecf20Sopenharmony_ciconfig ARM64_VA_BITS_39 9018c2ecf20Sopenharmony_ci bool "39-bit" 9028c2ecf20Sopenharmony_ci depends on ARM64_4K_PAGES 9038c2ecf20Sopenharmony_ci 9048c2ecf20Sopenharmony_ciconfig ARM64_VA_BITS_42 9058c2ecf20Sopenharmony_ci bool "42-bit" 9068c2ecf20Sopenharmony_ci depends on ARM64_64K_PAGES 9078c2ecf20Sopenharmony_ci 9088c2ecf20Sopenharmony_ciconfig ARM64_VA_BITS_47 9098c2ecf20Sopenharmony_ci bool "47-bit" 9108c2ecf20Sopenharmony_ci depends on ARM64_16K_PAGES 9118c2ecf20Sopenharmony_ci 9128c2ecf20Sopenharmony_ciconfig ARM64_VA_BITS_48 9138c2ecf20Sopenharmony_ci bool "48-bit" 9148c2ecf20Sopenharmony_ci 9158c2ecf20Sopenharmony_ciconfig ARM64_VA_BITS_52 9168c2ecf20Sopenharmony_ci bool "52-bit" 9178c2ecf20Sopenharmony_ci depends on ARM64_64K_PAGES && (ARM64_PAN || !ARM64_SW_TTBR0_PAN) 9188c2ecf20Sopenharmony_ci help 9198c2ecf20Sopenharmony_ci Enable 52-bit virtual addressing for userspace when explicitly 9208c2ecf20Sopenharmony_ci requested via a hint to mmap(). The kernel will also use 52-bit 9218c2ecf20Sopenharmony_ci virtual addresses for its own mappings (provided HW support for 9228c2ecf20Sopenharmony_ci this feature is available, otherwise it reverts to 48-bit). 9238c2ecf20Sopenharmony_ci 9248c2ecf20Sopenharmony_ci NOTE: Enabling 52-bit virtual addressing in conjunction with 9258c2ecf20Sopenharmony_ci ARMv8.3 Pointer Authentication will result in the PAC being 9268c2ecf20Sopenharmony_ci reduced from 7 bits to 3 bits, which may have a significant 9278c2ecf20Sopenharmony_ci impact on its susceptibility to brute-force attacks. 9288c2ecf20Sopenharmony_ci 9298c2ecf20Sopenharmony_ci If unsure, select 48-bit virtual addressing instead. 9308c2ecf20Sopenharmony_ci 9318c2ecf20Sopenharmony_ciendchoice 9328c2ecf20Sopenharmony_ci 9338c2ecf20Sopenharmony_ciconfig ARM64_FORCE_52BIT 9348c2ecf20Sopenharmony_ci bool "Force 52-bit virtual addresses for userspace" 9358c2ecf20Sopenharmony_ci depends on ARM64_VA_BITS_52 && EXPERT 9368c2ecf20Sopenharmony_ci help 9378c2ecf20Sopenharmony_ci For systems with 52-bit userspace VAs enabled, the kernel will attempt 9388c2ecf20Sopenharmony_ci to maintain compatibility with older software by providing 48-bit VAs 9398c2ecf20Sopenharmony_ci unless a hint is supplied to mmap. 9408c2ecf20Sopenharmony_ci 9418c2ecf20Sopenharmony_ci This configuration option disables the 48-bit compatibility logic, and 9428c2ecf20Sopenharmony_ci forces all userspace addresses to be 52-bit on HW that supports it. One 9438c2ecf20Sopenharmony_ci should only enable this configuration option for stress testing userspace 9448c2ecf20Sopenharmony_ci memory management code. If unsure say N here. 9458c2ecf20Sopenharmony_ci 9468c2ecf20Sopenharmony_ciconfig ARM64_VA_BITS 9478c2ecf20Sopenharmony_ci int 9488c2ecf20Sopenharmony_ci default 36 if ARM64_VA_BITS_36 9498c2ecf20Sopenharmony_ci default 39 if ARM64_VA_BITS_39 9508c2ecf20Sopenharmony_ci default 42 if ARM64_VA_BITS_42 9518c2ecf20Sopenharmony_ci default 47 if ARM64_VA_BITS_47 9528c2ecf20Sopenharmony_ci default 48 if ARM64_VA_BITS_48 9538c2ecf20Sopenharmony_ci default 52 if ARM64_VA_BITS_52 9548c2ecf20Sopenharmony_ci 9558c2ecf20Sopenharmony_cichoice 9568c2ecf20Sopenharmony_ci prompt "Physical address space size" 9578c2ecf20Sopenharmony_ci default ARM64_PA_BITS_48 9588c2ecf20Sopenharmony_ci help 9598c2ecf20Sopenharmony_ci Choose the maximum physical address range that the kernel will 9608c2ecf20Sopenharmony_ci support. 9618c2ecf20Sopenharmony_ci 9628c2ecf20Sopenharmony_ciconfig ARM64_PA_BITS_48 9638c2ecf20Sopenharmony_ci bool "48-bit" 9648c2ecf20Sopenharmony_ci 9658c2ecf20Sopenharmony_ciconfig ARM64_PA_BITS_52 9668c2ecf20Sopenharmony_ci bool "52-bit (ARMv8.2)" 9678c2ecf20Sopenharmony_ci depends on ARM64_64K_PAGES 9688c2ecf20Sopenharmony_ci depends on ARM64_PAN || !ARM64_SW_TTBR0_PAN 9698c2ecf20Sopenharmony_ci help 9708c2ecf20Sopenharmony_ci Enable support for a 52-bit physical address space, introduced as 9718c2ecf20Sopenharmony_ci part of the ARMv8.2-LPA extension. 9728c2ecf20Sopenharmony_ci 9738c2ecf20Sopenharmony_ci With this enabled, the kernel will also continue to work on CPUs that 9748c2ecf20Sopenharmony_ci do not support ARMv8.2-LPA, but with some added memory overhead (and 9758c2ecf20Sopenharmony_ci minor performance overhead). 9768c2ecf20Sopenharmony_ci 9778c2ecf20Sopenharmony_ciendchoice 9788c2ecf20Sopenharmony_ci 9798c2ecf20Sopenharmony_ciconfig ARM64_PA_BITS 9808c2ecf20Sopenharmony_ci int 9818c2ecf20Sopenharmony_ci default 48 if ARM64_PA_BITS_48 9828c2ecf20Sopenharmony_ci default 52 if ARM64_PA_BITS_52 9838c2ecf20Sopenharmony_ci 9848c2ecf20Sopenharmony_cichoice 9858c2ecf20Sopenharmony_ci prompt "Endianness" 9868c2ecf20Sopenharmony_ci default CPU_LITTLE_ENDIAN 9878c2ecf20Sopenharmony_ci help 9888c2ecf20Sopenharmony_ci Select the endianness of data accesses performed by the CPU. Userspace 9898c2ecf20Sopenharmony_ci applications will need to be compiled and linked for the endianness 9908c2ecf20Sopenharmony_ci that is selected here. 9918c2ecf20Sopenharmony_ci 9928c2ecf20Sopenharmony_ciconfig CPU_BIG_ENDIAN 9938c2ecf20Sopenharmony_ci bool "Build big-endian kernel" 9948c2ecf20Sopenharmony_ci depends on !LD_IS_LLD || LLD_VERSION >= 130000 9958c2ecf20Sopenharmony_ci # https://github.com/llvm/llvm-project/commit/1379b150991f70a5782e9a143c2ba5308da1161c 9968c2ecf20Sopenharmony_ci depends on AS_IS_GNU || AS_VERSION >= 150000 9978c2ecf20Sopenharmony_ci help 9988c2ecf20Sopenharmony_ci Say Y if you plan on running a kernel with a big-endian userspace. 9998c2ecf20Sopenharmony_ci 10008c2ecf20Sopenharmony_ciconfig CPU_LITTLE_ENDIAN 10018c2ecf20Sopenharmony_ci bool "Build little-endian kernel" 10028c2ecf20Sopenharmony_ci help 10038c2ecf20Sopenharmony_ci Say Y if you plan on running a kernel with a little-endian userspace. 10048c2ecf20Sopenharmony_ci This is usually the case for distributions targeting arm64. 10058c2ecf20Sopenharmony_ci 10068c2ecf20Sopenharmony_ciendchoice 10078c2ecf20Sopenharmony_ci 10088c2ecf20Sopenharmony_ciconfig SCHED_MC 10098c2ecf20Sopenharmony_ci bool "Multi-core scheduler support" 10108c2ecf20Sopenharmony_ci help 10118c2ecf20Sopenharmony_ci Multi-core scheduler support improves the CPU scheduler's decision 10128c2ecf20Sopenharmony_ci making when dealing with multi-core CPU chips at a cost of slightly 10138c2ecf20Sopenharmony_ci increased overhead in some places. If unsure say N here. 10148c2ecf20Sopenharmony_ci 10158c2ecf20Sopenharmony_ciconfig SCHED_SMT 10168c2ecf20Sopenharmony_ci bool "SMT scheduler support" 10178c2ecf20Sopenharmony_ci help 10188c2ecf20Sopenharmony_ci Improves the CPU scheduler's decision making when dealing with 10198c2ecf20Sopenharmony_ci MultiThreading at a cost of slightly increased overhead in some 10208c2ecf20Sopenharmony_ci places. If unsure say N here. 10218c2ecf20Sopenharmony_ci 10228c2ecf20Sopenharmony_ciconfig NR_CPUS 10238c2ecf20Sopenharmony_ci int "Maximum number of CPUs (2-4096)" 10248c2ecf20Sopenharmony_ci range 2 4096 10258c2ecf20Sopenharmony_ci default "256" 10268c2ecf20Sopenharmony_ci 10278c2ecf20Sopenharmony_ciconfig HOTPLUG_CPU 10288c2ecf20Sopenharmony_ci bool "Support for hot-pluggable CPUs" 10298c2ecf20Sopenharmony_ci select GENERIC_IRQ_MIGRATION 10308c2ecf20Sopenharmony_ci help 10318c2ecf20Sopenharmony_ci Say Y here to experiment with turning CPUs off and on. CPUs 10328c2ecf20Sopenharmony_ci can be controlled through /sys/devices/system/cpu. 10338c2ecf20Sopenharmony_ci 10348c2ecf20Sopenharmony_ci# Common NUMA Features 10358c2ecf20Sopenharmony_ciconfig NUMA 10368c2ecf20Sopenharmony_ci bool "NUMA Memory Allocation and Scheduler Support" 10378c2ecf20Sopenharmony_ci select ACPI_NUMA if ACPI 10388c2ecf20Sopenharmony_ci select OF_NUMA 10398c2ecf20Sopenharmony_ci help 10408c2ecf20Sopenharmony_ci Enable NUMA (Non-Uniform Memory Access) support. 10418c2ecf20Sopenharmony_ci 10428c2ecf20Sopenharmony_ci The kernel will try to allocate memory used by a CPU on the 10438c2ecf20Sopenharmony_ci local memory of the CPU and add some more 10448c2ecf20Sopenharmony_ci NUMA awareness to the kernel. 10458c2ecf20Sopenharmony_ci 10468c2ecf20Sopenharmony_ciconfig NODES_SHIFT 10478c2ecf20Sopenharmony_ci int "Maximum NUMA Nodes (as a power of 2)" 10488c2ecf20Sopenharmony_ci range 1 10 10498c2ecf20Sopenharmony_ci default "4" 10508c2ecf20Sopenharmony_ci depends on NEED_MULTIPLE_NODES 10518c2ecf20Sopenharmony_ci help 10528c2ecf20Sopenharmony_ci Specify the maximum number of NUMA Nodes available on the target 10538c2ecf20Sopenharmony_ci system. Increases memory reserved to accommodate various tables. 10548c2ecf20Sopenharmony_ci 10558c2ecf20Sopenharmony_ciconfig USE_PERCPU_NUMA_NODE_ID 10568c2ecf20Sopenharmony_ci def_bool y 10578c2ecf20Sopenharmony_ci depends on NUMA 10588c2ecf20Sopenharmony_ci 10598c2ecf20Sopenharmony_ciconfig HAVE_SETUP_PER_CPU_AREA 10608c2ecf20Sopenharmony_ci def_bool y 10618c2ecf20Sopenharmony_ci depends on NUMA 10628c2ecf20Sopenharmony_ci 10638c2ecf20Sopenharmony_ciconfig NEED_PER_CPU_EMBED_FIRST_CHUNK 10648c2ecf20Sopenharmony_ci def_bool y 10658c2ecf20Sopenharmony_ci depends on NUMA 10668c2ecf20Sopenharmony_ci 10678c2ecf20Sopenharmony_cisource "kernel/Kconfig.hz" 10688c2ecf20Sopenharmony_ci 10698c2ecf20Sopenharmony_ciconfig ARCH_SUPPORTS_DEBUG_PAGEALLOC 10708c2ecf20Sopenharmony_ci def_bool y 10718c2ecf20Sopenharmony_ci 10728c2ecf20Sopenharmony_ciconfig ARCH_SPARSEMEM_ENABLE 10738c2ecf20Sopenharmony_ci def_bool y 10748c2ecf20Sopenharmony_ci select SPARSEMEM_VMEMMAP_ENABLE 10758c2ecf20Sopenharmony_ci 10768c2ecf20Sopenharmony_ciconfig ARCH_SPARSEMEM_DEFAULT 10778c2ecf20Sopenharmony_ci def_bool ARCH_SPARSEMEM_ENABLE 10788c2ecf20Sopenharmony_ci 10798c2ecf20Sopenharmony_ciconfig ARCH_SELECT_MEMORY_MODEL 10808c2ecf20Sopenharmony_ci def_bool ARCH_SPARSEMEM_ENABLE 10818c2ecf20Sopenharmony_ci 10828c2ecf20Sopenharmony_ciconfig ARCH_FLATMEM_ENABLE 10838c2ecf20Sopenharmony_ci def_bool !NUMA 10848c2ecf20Sopenharmony_ci 10858c2ecf20Sopenharmony_ciconfig HAVE_ARCH_PFN_VALID 10868c2ecf20Sopenharmony_ci def_bool y 10878c2ecf20Sopenharmony_ci 10888c2ecf20Sopenharmony_ciconfig HW_PERF_EVENTS 10898c2ecf20Sopenharmony_ci def_bool y 10908c2ecf20Sopenharmony_ci depends on ARM_PMU 10918c2ecf20Sopenharmony_ci 10928c2ecf20Sopenharmony_ciconfig SYS_SUPPORTS_HUGETLBFS 10938c2ecf20Sopenharmony_ci def_bool y 10948c2ecf20Sopenharmony_ci 10958c2ecf20Sopenharmony_ciconfig ARCH_WANT_HUGE_PMD_SHARE 10968c2ecf20Sopenharmony_ci 10978c2ecf20Sopenharmony_ciconfig ARCH_HAS_CACHE_LINE_SIZE 10988c2ecf20Sopenharmony_ci def_bool y 10998c2ecf20Sopenharmony_ci 11008c2ecf20Sopenharmony_ciconfig ARCH_ENABLE_SPLIT_PMD_PTLOCK 11018c2ecf20Sopenharmony_ci def_bool y if PGTABLE_LEVELS > 2 11028c2ecf20Sopenharmony_ci 11038c2ecf20Sopenharmony_ci# Supported by clang >= 7.0 11048c2ecf20Sopenharmony_ciconfig CC_HAVE_SHADOW_CALL_STACK 11058c2ecf20Sopenharmony_ci def_bool $(cc-option, -fsanitize=shadow-call-stack -ffixed-x18) 11068c2ecf20Sopenharmony_ci 11078c2ecf20Sopenharmony_ciconfig PARAVIRT 11088c2ecf20Sopenharmony_ci bool "Enable paravirtualization code" 11098c2ecf20Sopenharmony_ci help 11108c2ecf20Sopenharmony_ci This changes the kernel so it can modify itself when it is run 11118c2ecf20Sopenharmony_ci under a hypervisor, potentially improving performance significantly 11128c2ecf20Sopenharmony_ci over full virtualization. 11138c2ecf20Sopenharmony_ci 11148c2ecf20Sopenharmony_ciconfig PARAVIRT_TIME_ACCOUNTING 11158c2ecf20Sopenharmony_ci bool "Paravirtual steal time accounting" 11168c2ecf20Sopenharmony_ci select PARAVIRT 11178c2ecf20Sopenharmony_ci help 11188c2ecf20Sopenharmony_ci Select this option to enable fine granularity task steal time 11198c2ecf20Sopenharmony_ci accounting. Time spent executing other tasks in parallel with 11208c2ecf20Sopenharmony_ci the current vCPU is discounted from the vCPU power. To account for 11218c2ecf20Sopenharmony_ci that, there can be a small performance impact. 11228c2ecf20Sopenharmony_ci 11238c2ecf20Sopenharmony_ci If in doubt, say N here. 11248c2ecf20Sopenharmony_ci 11258c2ecf20Sopenharmony_ciconfig KEXEC 11268c2ecf20Sopenharmony_ci depends on PM_SLEEP_SMP 11278c2ecf20Sopenharmony_ci select KEXEC_CORE 11288c2ecf20Sopenharmony_ci bool "kexec system call" 11298c2ecf20Sopenharmony_ci help 11308c2ecf20Sopenharmony_ci kexec is a system call that implements the ability to shutdown your 11318c2ecf20Sopenharmony_ci current kernel, and to start another kernel. It is like a reboot 11328c2ecf20Sopenharmony_ci but it is independent of the system firmware. And like a reboot 11338c2ecf20Sopenharmony_ci you can start any kernel with it, not just Linux. 11348c2ecf20Sopenharmony_ci 11358c2ecf20Sopenharmony_ciconfig KEXEC_FILE 11368c2ecf20Sopenharmony_ci bool "kexec file based system call" 11378c2ecf20Sopenharmony_ci select KEXEC_CORE 11388c2ecf20Sopenharmony_ci help 11398c2ecf20Sopenharmony_ci This is new version of kexec system call. This system call is 11408c2ecf20Sopenharmony_ci file based and takes file descriptors as system call argument 11418c2ecf20Sopenharmony_ci for kernel and initramfs as opposed to list of segments as 11428c2ecf20Sopenharmony_ci accepted by previous system call. 11438c2ecf20Sopenharmony_ci 11448c2ecf20Sopenharmony_ciconfig KEXEC_SIG 11458c2ecf20Sopenharmony_ci bool "Verify kernel signature during kexec_file_load() syscall" 11468c2ecf20Sopenharmony_ci depends on KEXEC_FILE 11478c2ecf20Sopenharmony_ci help 11488c2ecf20Sopenharmony_ci Select this option to verify a signature with loaded kernel 11498c2ecf20Sopenharmony_ci image. If configured, any attempt of loading a image without 11508c2ecf20Sopenharmony_ci valid signature will fail. 11518c2ecf20Sopenharmony_ci 11528c2ecf20Sopenharmony_ci In addition to that option, you need to enable signature 11538c2ecf20Sopenharmony_ci verification for the corresponding kernel image type being 11548c2ecf20Sopenharmony_ci loaded in order for this to work. 11558c2ecf20Sopenharmony_ci 11568c2ecf20Sopenharmony_ciconfig KEXEC_IMAGE_VERIFY_SIG 11578c2ecf20Sopenharmony_ci bool "Enable Image signature verification support" 11588c2ecf20Sopenharmony_ci default y 11598c2ecf20Sopenharmony_ci depends on KEXEC_SIG 11608c2ecf20Sopenharmony_ci depends on EFI && SIGNED_PE_FILE_VERIFICATION 11618c2ecf20Sopenharmony_ci help 11628c2ecf20Sopenharmony_ci Enable Image signature verification support. 11638c2ecf20Sopenharmony_ci 11648c2ecf20Sopenharmony_cicomment "Support for PE file signature verification disabled" 11658c2ecf20Sopenharmony_ci depends on KEXEC_SIG 11668c2ecf20Sopenharmony_ci depends on !EFI || !SIGNED_PE_FILE_VERIFICATION 11678c2ecf20Sopenharmony_ci 11688c2ecf20Sopenharmony_ciconfig CRASH_DUMP 11698c2ecf20Sopenharmony_ci bool "Build kdump crash kernel" 11708c2ecf20Sopenharmony_ci help 11718c2ecf20Sopenharmony_ci Generate crash dump after being started by kexec. This should 11728c2ecf20Sopenharmony_ci be normally only set in special crash dump kernels which are 11738c2ecf20Sopenharmony_ci loaded in the main kernel with kexec-tools into a specially 11748c2ecf20Sopenharmony_ci reserved region and then later executed after a crash by 11758c2ecf20Sopenharmony_ci kdump/kexec. 11768c2ecf20Sopenharmony_ci 11778c2ecf20Sopenharmony_ci For more details see Documentation/admin-guide/kdump/kdump.rst 11788c2ecf20Sopenharmony_ci 11798c2ecf20Sopenharmony_ciconfig XEN_DOM0 11808c2ecf20Sopenharmony_ci def_bool y 11818c2ecf20Sopenharmony_ci depends on XEN 11828c2ecf20Sopenharmony_ci 11838c2ecf20Sopenharmony_ciconfig XEN 11848c2ecf20Sopenharmony_ci bool "Xen guest support on ARM64" 11858c2ecf20Sopenharmony_ci depends on ARM64 && OF 11868c2ecf20Sopenharmony_ci select SWIOTLB_XEN 11878c2ecf20Sopenharmony_ci select PARAVIRT 11888c2ecf20Sopenharmony_ci help 11898c2ecf20Sopenharmony_ci Say Y if you want to run Linux in a Virtual Machine on Xen on ARM64. 11908c2ecf20Sopenharmony_ci 11918c2ecf20Sopenharmony_ciconfig FORCE_MAX_ZONEORDER 11928c2ecf20Sopenharmony_ci int 11938c2ecf20Sopenharmony_ci default "14" if (ARM64_64K_PAGES && TRANSPARENT_HUGEPAGE) 11948c2ecf20Sopenharmony_ci default "12" if (ARM64_16K_PAGES && TRANSPARENT_HUGEPAGE) 11958c2ecf20Sopenharmony_ci default "11" 11968c2ecf20Sopenharmony_ci help 11978c2ecf20Sopenharmony_ci The kernel memory allocator divides physically contiguous memory 11988c2ecf20Sopenharmony_ci blocks into "zones", where each zone is a power of two number of 11998c2ecf20Sopenharmony_ci pages. This option selects the largest power of two that the kernel 12008c2ecf20Sopenharmony_ci keeps in the memory allocator. If you need to allocate very large 12018c2ecf20Sopenharmony_ci blocks of physically contiguous memory, then you may need to 12028c2ecf20Sopenharmony_ci increase this value. 12038c2ecf20Sopenharmony_ci 12048c2ecf20Sopenharmony_ci This config option is actually maximum order plus one. For example, 12058c2ecf20Sopenharmony_ci a value of 11 means that the largest free memory block is 2^10 pages. 12068c2ecf20Sopenharmony_ci 12078c2ecf20Sopenharmony_ci We make sure that we can allocate upto a HugePage size for each configuration. 12088c2ecf20Sopenharmony_ci Hence we have : 12098c2ecf20Sopenharmony_ci MAX_ORDER = (PMD_SHIFT - PAGE_SHIFT) + 1 => PAGE_SHIFT - 2 12108c2ecf20Sopenharmony_ci 12118c2ecf20Sopenharmony_ci However for 4K, we choose a higher default value, 11 as opposed to 10, giving us 12128c2ecf20Sopenharmony_ci 4M allocations matching the default size used by generic code. 12138c2ecf20Sopenharmony_ci 12148c2ecf20Sopenharmony_ciconfig UNMAP_KERNEL_AT_EL0 12158c2ecf20Sopenharmony_ci bool "Unmap kernel when running in userspace (aka \"KAISER\")" if EXPERT 12168c2ecf20Sopenharmony_ci default y 12178c2ecf20Sopenharmony_ci help 12188c2ecf20Sopenharmony_ci Speculation attacks against some high-performance processors can 12198c2ecf20Sopenharmony_ci be used to bypass MMU permission checks and leak kernel data to 12208c2ecf20Sopenharmony_ci userspace. This can be defended against by unmapping the kernel 12218c2ecf20Sopenharmony_ci when running in userspace, mapping it back in on exception entry 12228c2ecf20Sopenharmony_ci via a trampoline page in the vector table. 12238c2ecf20Sopenharmony_ci 12248c2ecf20Sopenharmony_ci If unsure, say Y. 12258c2ecf20Sopenharmony_ci 12268c2ecf20Sopenharmony_ciconfig MITIGATE_SPECTRE_BRANCH_HISTORY 12278c2ecf20Sopenharmony_ci bool "Mitigate Spectre style attacks against branch history" if EXPERT 12288c2ecf20Sopenharmony_ci default y 12298c2ecf20Sopenharmony_ci help 12308c2ecf20Sopenharmony_ci Speculation attacks against some high-performance processors can 12318c2ecf20Sopenharmony_ci make use of branch history to influence future speculation. 12328c2ecf20Sopenharmony_ci When taking an exception from user-space, a sequence of branches 12338c2ecf20Sopenharmony_ci or a firmware call overwrites the branch history. 12348c2ecf20Sopenharmony_ci 12358c2ecf20Sopenharmony_ciconfig RODATA_FULL_DEFAULT_ENABLED 12368c2ecf20Sopenharmony_ci bool "Apply r/o permissions of VM areas also to their linear aliases" 12378c2ecf20Sopenharmony_ci default y 12388c2ecf20Sopenharmony_ci help 12398c2ecf20Sopenharmony_ci Apply read-only attributes of VM areas to the linear alias of 12408c2ecf20Sopenharmony_ci the backing pages as well. This prevents code or read-only data 12418c2ecf20Sopenharmony_ci from being modified (inadvertently or intentionally) via another 12428c2ecf20Sopenharmony_ci mapping of the same memory page. This additional enhancement can 12438c2ecf20Sopenharmony_ci be turned off at runtime by passing rodata=[off|on] (and turned on 12448c2ecf20Sopenharmony_ci with rodata=full if this option is set to 'n') 12458c2ecf20Sopenharmony_ci 12468c2ecf20Sopenharmony_ci This requires the linear region to be mapped down to pages, 12478c2ecf20Sopenharmony_ci which may adversely affect performance in some cases. 12488c2ecf20Sopenharmony_ci 12498c2ecf20Sopenharmony_ciconfig ARM64_SW_TTBR0_PAN 12508c2ecf20Sopenharmony_ci bool "Emulate Privileged Access Never using TTBR0_EL1 switching" 12518c2ecf20Sopenharmony_ci help 12528c2ecf20Sopenharmony_ci Enabling this option prevents the kernel from accessing 12538c2ecf20Sopenharmony_ci user-space memory directly by pointing TTBR0_EL1 to a reserved 12548c2ecf20Sopenharmony_ci zeroed area and reserved ASID. The user access routines 12558c2ecf20Sopenharmony_ci restore the valid TTBR0_EL1 temporarily. 12568c2ecf20Sopenharmony_ci 12578c2ecf20Sopenharmony_ciconfig ARM64_TAGGED_ADDR_ABI 12588c2ecf20Sopenharmony_ci bool "Enable the tagged user addresses syscall ABI" 12598c2ecf20Sopenharmony_ci default y 12608c2ecf20Sopenharmony_ci help 12618c2ecf20Sopenharmony_ci When this option is enabled, user applications can opt in to a 12628c2ecf20Sopenharmony_ci relaxed ABI via prctl() allowing tagged addresses to be passed 12638c2ecf20Sopenharmony_ci to system calls as pointer arguments. For details, see 12648c2ecf20Sopenharmony_ci Documentation/arm64/tagged-address-abi.rst. 12658c2ecf20Sopenharmony_ci 12668c2ecf20Sopenharmony_cimenuconfig COMPAT 12678c2ecf20Sopenharmony_ci bool "Kernel support for 32-bit EL0" 12688c2ecf20Sopenharmony_ci depends on ARM64_4K_PAGES || EXPERT 12698c2ecf20Sopenharmony_ci select COMPAT_BINFMT_ELF if BINFMT_ELF 12708c2ecf20Sopenharmony_ci select HAVE_UID16 12718c2ecf20Sopenharmony_ci select OLD_SIGSUSPEND3 12728c2ecf20Sopenharmony_ci select COMPAT_OLD_SIGACTION 12738c2ecf20Sopenharmony_ci help 12748c2ecf20Sopenharmony_ci This option enables support for a 32-bit EL0 running under a 64-bit 12758c2ecf20Sopenharmony_ci kernel at EL1. AArch32-specific components such as system calls, 12768c2ecf20Sopenharmony_ci the user helper functions, VFP support and the ptrace interface are 12778c2ecf20Sopenharmony_ci handled appropriately by the kernel. 12788c2ecf20Sopenharmony_ci 12798c2ecf20Sopenharmony_ci If you use a page size other than 4KB (i.e, 16KB or 64KB), please be aware 12808c2ecf20Sopenharmony_ci that you will only be able to execute AArch32 binaries that were compiled 12818c2ecf20Sopenharmony_ci with page size aligned segments. 12828c2ecf20Sopenharmony_ci 12838c2ecf20Sopenharmony_ci If you want to execute 32-bit userspace applications, say Y. 12848c2ecf20Sopenharmony_ci 12858c2ecf20Sopenharmony_ciif COMPAT 12868c2ecf20Sopenharmony_ci 12878c2ecf20Sopenharmony_ciconfig KUSER_HELPERS 12888c2ecf20Sopenharmony_ci bool "Enable kuser helpers page for 32-bit applications" 12898c2ecf20Sopenharmony_ci default y 12908c2ecf20Sopenharmony_ci help 12918c2ecf20Sopenharmony_ci Warning: disabling this option may break 32-bit user programs. 12928c2ecf20Sopenharmony_ci 12938c2ecf20Sopenharmony_ci Provide kuser helpers to compat tasks. The kernel provides 12948c2ecf20Sopenharmony_ci helper code to userspace in read only form at a fixed location 12958c2ecf20Sopenharmony_ci to allow userspace to be independent of the CPU type fitted to 12968c2ecf20Sopenharmony_ci the system. This permits binaries to be run on ARMv4 through 12978c2ecf20Sopenharmony_ci to ARMv8 without modification. 12988c2ecf20Sopenharmony_ci 12998c2ecf20Sopenharmony_ci See Documentation/arm/kernel_user_helpers.rst for details. 13008c2ecf20Sopenharmony_ci 13018c2ecf20Sopenharmony_ci However, the fixed address nature of these helpers can be used 13028c2ecf20Sopenharmony_ci by ROP (return orientated programming) authors when creating 13038c2ecf20Sopenharmony_ci exploits. 13048c2ecf20Sopenharmony_ci 13058c2ecf20Sopenharmony_ci If all of the binaries and libraries which run on your platform 13068c2ecf20Sopenharmony_ci are built specifically for your platform, and make no use of 13078c2ecf20Sopenharmony_ci these helpers, then you can turn this option off to hinder 13088c2ecf20Sopenharmony_ci such exploits. However, in that case, if a binary or library 13098c2ecf20Sopenharmony_ci relying on those helpers is run, it will not function correctly. 13108c2ecf20Sopenharmony_ci 13118c2ecf20Sopenharmony_ci Say N here only if you are absolutely certain that you do not 13128c2ecf20Sopenharmony_ci need these helpers; otherwise, the safe option is to say Y. 13138c2ecf20Sopenharmony_ci 13148c2ecf20Sopenharmony_ciconfig COMPAT_VDSO 13158c2ecf20Sopenharmony_ci bool "Enable vDSO for 32-bit applications" 13168c2ecf20Sopenharmony_ci depends on !CPU_BIG_ENDIAN 13178c2ecf20Sopenharmony_ci depends on (CC_IS_CLANG && LD_IS_LLD) || "$(CROSS_COMPILE_COMPAT)" != "" 13188c2ecf20Sopenharmony_ci select GENERIC_COMPAT_VDSO 13198c2ecf20Sopenharmony_ci default y 13208c2ecf20Sopenharmony_ci help 13218c2ecf20Sopenharmony_ci Place in the process address space of 32-bit applications an 13228c2ecf20Sopenharmony_ci ELF shared object providing fast implementations of gettimeofday 13238c2ecf20Sopenharmony_ci and clock_gettime. 13248c2ecf20Sopenharmony_ci 13258c2ecf20Sopenharmony_ci You must have a 32-bit build of glibc 2.22 or later for programs 13268c2ecf20Sopenharmony_ci to seamlessly take advantage of this. 13278c2ecf20Sopenharmony_ci 13288c2ecf20Sopenharmony_ciconfig THUMB2_COMPAT_VDSO 13298c2ecf20Sopenharmony_ci bool "Compile the 32-bit vDSO for Thumb-2 mode" if EXPERT 13308c2ecf20Sopenharmony_ci depends on COMPAT_VDSO 13318c2ecf20Sopenharmony_ci default y 13328c2ecf20Sopenharmony_ci help 13338c2ecf20Sopenharmony_ci Compile the compat vDSO with '-mthumb -fomit-frame-pointer' if y, 13348c2ecf20Sopenharmony_ci otherwise with '-marm'. 13358c2ecf20Sopenharmony_ci 13368c2ecf20Sopenharmony_cimenuconfig ARMV8_DEPRECATED 13378c2ecf20Sopenharmony_ci bool "Emulate deprecated/obsolete ARMv8 instructions" 13388c2ecf20Sopenharmony_ci depends on SYSCTL 13398c2ecf20Sopenharmony_ci help 13408c2ecf20Sopenharmony_ci Legacy software support may require certain instructions 13418c2ecf20Sopenharmony_ci that have been deprecated or obsoleted in the architecture. 13428c2ecf20Sopenharmony_ci 13438c2ecf20Sopenharmony_ci Enable this config to enable selective emulation of these 13448c2ecf20Sopenharmony_ci features. 13458c2ecf20Sopenharmony_ci 13468c2ecf20Sopenharmony_ci If unsure, say Y 13478c2ecf20Sopenharmony_ci 13488c2ecf20Sopenharmony_ciif ARMV8_DEPRECATED 13498c2ecf20Sopenharmony_ci 13508c2ecf20Sopenharmony_ciconfig SWP_EMULATION 13518c2ecf20Sopenharmony_ci bool "Emulate SWP/SWPB instructions" 13528c2ecf20Sopenharmony_ci help 13538c2ecf20Sopenharmony_ci ARMv8 obsoletes the use of A32 SWP/SWPB instructions such that 13548c2ecf20Sopenharmony_ci they are always undefined. Say Y here to enable software 13558c2ecf20Sopenharmony_ci emulation of these instructions for userspace using LDXR/STXR. 13568c2ecf20Sopenharmony_ci This feature can be controlled at runtime with the abi.swp 13578c2ecf20Sopenharmony_ci sysctl which is disabled by default. 13588c2ecf20Sopenharmony_ci 13598c2ecf20Sopenharmony_ci In some older versions of glibc [<=2.8] SWP is used during futex 13608c2ecf20Sopenharmony_ci trylock() operations with the assumption that the code will not 13618c2ecf20Sopenharmony_ci be preempted. This invalid assumption may be more likely to fail 13628c2ecf20Sopenharmony_ci with SWP emulation enabled, leading to deadlock of the user 13638c2ecf20Sopenharmony_ci application. 13648c2ecf20Sopenharmony_ci 13658c2ecf20Sopenharmony_ci NOTE: when accessing uncached shared regions, LDXR/STXR rely 13668c2ecf20Sopenharmony_ci on an external transaction monitoring block called a global 13678c2ecf20Sopenharmony_ci monitor to maintain update atomicity. If your system does not 13688c2ecf20Sopenharmony_ci implement a global monitor, this option can cause programs that 13698c2ecf20Sopenharmony_ci perform SWP operations to uncached memory to deadlock. 13708c2ecf20Sopenharmony_ci 13718c2ecf20Sopenharmony_ci If unsure, say Y 13728c2ecf20Sopenharmony_ci 13738c2ecf20Sopenharmony_ciconfig CP15_BARRIER_EMULATION 13748c2ecf20Sopenharmony_ci bool "Emulate CP15 Barrier instructions" 13758c2ecf20Sopenharmony_ci help 13768c2ecf20Sopenharmony_ci The CP15 barrier instructions - CP15ISB, CP15DSB, and 13778c2ecf20Sopenharmony_ci CP15DMB - are deprecated in ARMv8 (and ARMv7). It is 13788c2ecf20Sopenharmony_ci strongly recommended to use the ISB, DSB, and DMB 13798c2ecf20Sopenharmony_ci instructions instead. 13808c2ecf20Sopenharmony_ci 13818c2ecf20Sopenharmony_ci Say Y here to enable software emulation of these 13828c2ecf20Sopenharmony_ci instructions for AArch32 userspace code. When this option is 13838c2ecf20Sopenharmony_ci enabled, CP15 barrier usage is traced which can help 13848c2ecf20Sopenharmony_ci identify software that needs updating. This feature can be 13858c2ecf20Sopenharmony_ci controlled at runtime with the abi.cp15_barrier sysctl. 13868c2ecf20Sopenharmony_ci 13878c2ecf20Sopenharmony_ci If unsure, say Y 13888c2ecf20Sopenharmony_ci 13898c2ecf20Sopenharmony_ciconfig SETEND_EMULATION 13908c2ecf20Sopenharmony_ci bool "Emulate SETEND instruction" 13918c2ecf20Sopenharmony_ci help 13928c2ecf20Sopenharmony_ci The SETEND instruction alters the data-endianness of the 13938c2ecf20Sopenharmony_ci AArch32 EL0, and is deprecated in ARMv8. 13948c2ecf20Sopenharmony_ci 13958c2ecf20Sopenharmony_ci Say Y here to enable software emulation of the instruction 13968c2ecf20Sopenharmony_ci for AArch32 userspace code. This feature can be controlled 13978c2ecf20Sopenharmony_ci at runtime with the abi.setend sysctl. 13988c2ecf20Sopenharmony_ci 13998c2ecf20Sopenharmony_ci Note: All the cpus on the system must have mixed endian support at EL0 14008c2ecf20Sopenharmony_ci for this feature to be enabled. If a new CPU - which doesn't support mixed 14018c2ecf20Sopenharmony_ci endian - is hotplugged in after this feature has been enabled, there could 14028c2ecf20Sopenharmony_ci be unexpected results in the applications. 14038c2ecf20Sopenharmony_ci 14048c2ecf20Sopenharmony_ci If unsure, say Y 14058c2ecf20Sopenharmony_ciendif 14068c2ecf20Sopenharmony_ci 14078c2ecf20Sopenharmony_ciendif 14088c2ecf20Sopenharmony_ci 14098c2ecf20Sopenharmony_cimenu "ARMv8.1 architectural features" 14108c2ecf20Sopenharmony_ci 14118c2ecf20Sopenharmony_ciconfig ARM64_HW_AFDBM 14128c2ecf20Sopenharmony_ci bool "Support for hardware updates of the Access and Dirty page flags" 14138c2ecf20Sopenharmony_ci default y 14148c2ecf20Sopenharmony_ci help 14158c2ecf20Sopenharmony_ci The ARMv8.1 architecture extensions introduce support for 14168c2ecf20Sopenharmony_ci hardware updates of the access and dirty information in page 14178c2ecf20Sopenharmony_ci table entries. When enabled in TCR_EL1 (HA and HD bits) on 14188c2ecf20Sopenharmony_ci capable processors, accesses to pages with PTE_AF cleared will 14198c2ecf20Sopenharmony_ci set this bit instead of raising an access flag fault. 14208c2ecf20Sopenharmony_ci Similarly, writes to read-only pages with the DBM bit set will 14218c2ecf20Sopenharmony_ci clear the read-only bit (AP[2]) instead of raising a 14228c2ecf20Sopenharmony_ci permission fault. 14238c2ecf20Sopenharmony_ci 14248c2ecf20Sopenharmony_ci Kernels built with this configuration option enabled continue 14258c2ecf20Sopenharmony_ci to work on pre-ARMv8.1 hardware and the performance impact is 14268c2ecf20Sopenharmony_ci minimal. If unsure, say Y. 14278c2ecf20Sopenharmony_ci 14288c2ecf20Sopenharmony_ciconfig ARM64_PAN 14298c2ecf20Sopenharmony_ci bool "Enable support for Privileged Access Never (PAN)" 14308c2ecf20Sopenharmony_ci default y 14318c2ecf20Sopenharmony_ci help 14328c2ecf20Sopenharmony_ci Privileged Access Never (PAN; part of the ARMv8.1 Extensions) 14338c2ecf20Sopenharmony_ci prevents the kernel or hypervisor from accessing user-space (EL0) 14348c2ecf20Sopenharmony_ci memory directly. 14358c2ecf20Sopenharmony_ci 14368c2ecf20Sopenharmony_ci Choosing this option will cause any unprotected (not using 14378c2ecf20Sopenharmony_ci copy_to_user et al) memory access to fail with a permission fault. 14388c2ecf20Sopenharmony_ci 14398c2ecf20Sopenharmony_ci The feature is detected at runtime, and will remain as a 'nop' 14408c2ecf20Sopenharmony_ci instruction if the cpu does not implement the feature. 14418c2ecf20Sopenharmony_ci 14428c2ecf20Sopenharmony_ciconfig AS_HAS_LSE_ATOMICS 14438c2ecf20Sopenharmony_ci def_bool $(as-instr,.arch_extension lse) 14448c2ecf20Sopenharmony_ci 14458c2ecf20Sopenharmony_ciconfig ARM64_LSE_ATOMICS 14468c2ecf20Sopenharmony_ci bool 14478c2ecf20Sopenharmony_ci default ARM64_USE_LSE_ATOMICS 14488c2ecf20Sopenharmony_ci depends on AS_HAS_LSE_ATOMICS 14498c2ecf20Sopenharmony_ci 14508c2ecf20Sopenharmony_ciconfig ARM64_USE_LSE_ATOMICS 14518c2ecf20Sopenharmony_ci bool "Atomic instructions" 14528c2ecf20Sopenharmony_ci depends on JUMP_LABEL 14538c2ecf20Sopenharmony_ci default y 14548c2ecf20Sopenharmony_ci help 14558c2ecf20Sopenharmony_ci As part of the Large System Extensions, ARMv8.1 introduces new 14568c2ecf20Sopenharmony_ci atomic instructions that are designed specifically to scale in 14578c2ecf20Sopenharmony_ci very large systems. 14588c2ecf20Sopenharmony_ci 14598c2ecf20Sopenharmony_ci Say Y here to make use of these instructions for the in-kernel 14608c2ecf20Sopenharmony_ci atomic routines. This incurs a small overhead on CPUs that do 14618c2ecf20Sopenharmony_ci not support these instructions and requires the kernel to be 14628c2ecf20Sopenharmony_ci built with binutils >= 2.25 in order for the new instructions 14638c2ecf20Sopenharmony_ci to be used. 14648c2ecf20Sopenharmony_ci 14658c2ecf20Sopenharmony_ciconfig ARM64_VHE 14668c2ecf20Sopenharmony_ci bool "Enable support for Virtualization Host Extensions (VHE)" 14678c2ecf20Sopenharmony_ci default y 14688c2ecf20Sopenharmony_ci help 14698c2ecf20Sopenharmony_ci Virtualization Host Extensions (VHE) allow the kernel to run 14708c2ecf20Sopenharmony_ci directly at EL2 (instead of EL1) on processors that support 14718c2ecf20Sopenharmony_ci it. This leads to better performance for KVM, as they reduce 14728c2ecf20Sopenharmony_ci the cost of the world switch. 14738c2ecf20Sopenharmony_ci 14748c2ecf20Sopenharmony_ci Selecting this option allows the VHE feature to be detected 14758c2ecf20Sopenharmony_ci at runtime, and does not affect processors that do not 14768c2ecf20Sopenharmony_ci implement this feature. 14778c2ecf20Sopenharmony_ci 14788c2ecf20Sopenharmony_ciendmenu 14798c2ecf20Sopenharmony_ci 14808c2ecf20Sopenharmony_cimenu "ARMv8.2 architectural features" 14818c2ecf20Sopenharmony_ci 14828c2ecf20Sopenharmony_ciconfig ARM64_UAO 14838c2ecf20Sopenharmony_ci bool "Enable support for User Access Override (UAO)" 14848c2ecf20Sopenharmony_ci default y 14858c2ecf20Sopenharmony_ci help 14868c2ecf20Sopenharmony_ci User Access Override (UAO; part of the ARMv8.2 Extensions) 14878c2ecf20Sopenharmony_ci causes the 'unprivileged' variant of the load/store instructions to 14888c2ecf20Sopenharmony_ci be overridden to be privileged. 14898c2ecf20Sopenharmony_ci 14908c2ecf20Sopenharmony_ci This option changes get_user() and friends to use the 'unprivileged' 14918c2ecf20Sopenharmony_ci variant of the load/store instructions. This ensures that user-space 14928c2ecf20Sopenharmony_ci really did have access to the supplied memory. When addr_limit is 14938c2ecf20Sopenharmony_ci set to kernel memory the UAO bit will be set, allowing privileged 14948c2ecf20Sopenharmony_ci access to kernel memory. 14958c2ecf20Sopenharmony_ci 14968c2ecf20Sopenharmony_ci Choosing this option will cause copy_to_user() et al to use user-space 14978c2ecf20Sopenharmony_ci memory permissions. 14988c2ecf20Sopenharmony_ci 14998c2ecf20Sopenharmony_ci The feature is detected at runtime, the kernel will use the 15008c2ecf20Sopenharmony_ci regular load/store instructions if the cpu does not implement the 15018c2ecf20Sopenharmony_ci feature. 15028c2ecf20Sopenharmony_ci 15038c2ecf20Sopenharmony_ciconfig ARM64_PMEM 15048c2ecf20Sopenharmony_ci bool "Enable support for persistent memory" 15058c2ecf20Sopenharmony_ci select ARCH_HAS_PMEM_API 15068c2ecf20Sopenharmony_ci select ARCH_HAS_UACCESS_FLUSHCACHE 15078c2ecf20Sopenharmony_ci help 15088c2ecf20Sopenharmony_ci Say Y to enable support for the persistent memory API based on the 15098c2ecf20Sopenharmony_ci ARMv8.2 DCPoP feature. 15108c2ecf20Sopenharmony_ci 15118c2ecf20Sopenharmony_ci The feature is detected at runtime, and the kernel will use DC CVAC 15128c2ecf20Sopenharmony_ci operations if DC CVAP is not supported (following the behaviour of 15138c2ecf20Sopenharmony_ci DC CVAP itself if the system does not define a point of persistence). 15148c2ecf20Sopenharmony_ci 15158c2ecf20Sopenharmony_ciconfig ARM64_RAS_EXTN 15168c2ecf20Sopenharmony_ci bool "Enable support for RAS CPU Extensions" 15178c2ecf20Sopenharmony_ci default y 15188c2ecf20Sopenharmony_ci help 15198c2ecf20Sopenharmony_ci CPUs that support the Reliability, Availability and Serviceability 15208c2ecf20Sopenharmony_ci (RAS) Extensions, part of ARMv8.2 are able to track faults and 15218c2ecf20Sopenharmony_ci errors, classify them and report them to software. 15228c2ecf20Sopenharmony_ci 15238c2ecf20Sopenharmony_ci On CPUs with these extensions system software can use additional 15248c2ecf20Sopenharmony_ci barriers to determine if faults are pending and read the 15258c2ecf20Sopenharmony_ci classification from a new set of registers. 15268c2ecf20Sopenharmony_ci 15278c2ecf20Sopenharmony_ci Selecting this feature will allow the kernel to use these barriers 15288c2ecf20Sopenharmony_ci and access the new registers if the system supports the extension. 15298c2ecf20Sopenharmony_ci Platform RAS features may additionally depend on firmware support. 15308c2ecf20Sopenharmony_ci 15318c2ecf20Sopenharmony_ciconfig ARM64_CNP 15328c2ecf20Sopenharmony_ci bool "Enable support for Common Not Private (CNP) translations" 15338c2ecf20Sopenharmony_ci default y 15348c2ecf20Sopenharmony_ci depends on ARM64_PAN || !ARM64_SW_TTBR0_PAN 15358c2ecf20Sopenharmony_ci help 15368c2ecf20Sopenharmony_ci Common Not Private (CNP) allows translation table entries to 15378c2ecf20Sopenharmony_ci be shared between different PEs in the same inner shareable 15388c2ecf20Sopenharmony_ci domain, so the hardware can use this fact to optimise the 15398c2ecf20Sopenharmony_ci caching of such entries in the TLB. 15408c2ecf20Sopenharmony_ci 15418c2ecf20Sopenharmony_ci Selecting this option allows the CNP feature to be detected 15428c2ecf20Sopenharmony_ci at runtime, and does not affect PEs that do not implement 15438c2ecf20Sopenharmony_ci this feature. 15448c2ecf20Sopenharmony_ci 15458c2ecf20Sopenharmony_ciendmenu 15468c2ecf20Sopenharmony_ci 15478c2ecf20Sopenharmony_cimenu "ARMv8.3 architectural features" 15488c2ecf20Sopenharmony_ci 15498c2ecf20Sopenharmony_ciconfig ARM64_PTR_AUTH 15508c2ecf20Sopenharmony_ci bool "Enable support for pointer authentication" 15518c2ecf20Sopenharmony_ci default y 15528c2ecf20Sopenharmony_ci depends on (CC_HAS_SIGN_RETURN_ADDRESS || CC_HAS_BRANCH_PROT_PAC_RET) && AS_HAS_PAC 15538c2ecf20Sopenharmony_ci # Modern compilers insert a .note.gnu.property section note for PAC 15548c2ecf20Sopenharmony_ci # which is only understood by binutils starting with version 2.33.1. 15558c2ecf20Sopenharmony_ci depends on LD_IS_LLD || LD_VERSION >= 233010000 || (CC_IS_GCC && GCC_VERSION < 90100) 15568c2ecf20Sopenharmony_ci depends on !CC_IS_CLANG || AS_HAS_CFI_NEGATE_RA_STATE 15578c2ecf20Sopenharmony_ci depends on (!FUNCTION_GRAPH_TRACER || DYNAMIC_FTRACE_WITH_REGS) 15588c2ecf20Sopenharmony_ci help 15598c2ecf20Sopenharmony_ci Pointer authentication (part of the ARMv8.3 Extensions) provides 15608c2ecf20Sopenharmony_ci instructions for signing and authenticating pointers against secret 15618c2ecf20Sopenharmony_ci keys, which can be used to mitigate Return Oriented Programming (ROP) 15628c2ecf20Sopenharmony_ci and other attacks. 15638c2ecf20Sopenharmony_ci 15648c2ecf20Sopenharmony_ci This option enables these instructions at EL0 (i.e. for userspace). 15658c2ecf20Sopenharmony_ci Choosing this option will cause the kernel to initialise secret keys 15668c2ecf20Sopenharmony_ci for each process at exec() time, with these keys being 15678c2ecf20Sopenharmony_ci context-switched along with the process. 15688c2ecf20Sopenharmony_ci 15698c2ecf20Sopenharmony_ci If the compiler supports the -mbranch-protection or 15708c2ecf20Sopenharmony_ci -msign-return-address flag (e.g. GCC 7 or later), then this option 15718c2ecf20Sopenharmony_ci will also cause the kernel itself to be compiled with return address 15728c2ecf20Sopenharmony_ci protection. In this case, and if the target hardware is known to 15738c2ecf20Sopenharmony_ci support pointer authentication, then CONFIG_STACKPROTECTOR can be 15748c2ecf20Sopenharmony_ci disabled with minimal loss of protection. 15758c2ecf20Sopenharmony_ci 15768c2ecf20Sopenharmony_ci The feature is detected at runtime. If the feature is not present in 15778c2ecf20Sopenharmony_ci hardware it will not be advertised to userspace/KVM guest nor will it 15788c2ecf20Sopenharmony_ci be enabled. 15798c2ecf20Sopenharmony_ci 15808c2ecf20Sopenharmony_ci If the feature is present on the boot CPU but not on a late CPU, then 15818c2ecf20Sopenharmony_ci the late CPU will be parked. Also, if the boot CPU does not have 15828c2ecf20Sopenharmony_ci address auth and the late CPU has then the late CPU will still boot 15838c2ecf20Sopenharmony_ci but with the feature disabled. On such a system, this option should 15848c2ecf20Sopenharmony_ci not be selected. 15858c2ecf20Sopenharmony_ci 15868c2ecf20Sopenharmony_ci This feature works with FUNCTION_GRAPH_TRACER option only if 15878c2ecf20Sopenharmony_ci DYNAMIC_FTRACE_WITH_REGS is enabled. 15888c2ecf20Sopenharmony_ci 15898c2ecf20Sopenharmony_ciconfig CC_HAS_BRANCH_PROT_PAC_RET 15908c2ecf20Sopenharmony_ci # GCC 9 or later, clang 8 or later 15918c2ecf20Sopenharmony_ci def_bool $(cc-option,-mbranch-protection=pac-ret+leaf) 15928c2ecf20Sopenharmony_ci 15938c2ecf20Sopenharmony_ciconfig CC_HAS_SIGN_RETURN_ADDRESS 15948c2ecf20Sopenharmony_ci # GCC 7, 8 15958c2ecf20Sopenharmony_ci def_bool $(cc-option,-msign-return-address=all) 15968c2ecf20Sopenharmony_ci 15978c2ecf20Sopenharmony_ciconfig AS_HAS_PAC 15988c2ecf20Sopenharmony_ci def_bool $(cc-option,-Wa$(comma)-march=armv8.3-a) 15998c2ecf20Sopenharmony_ci 16008c2ecf20Sopenharmony_ciconfig AS_HAS_CFI_NEGATE_RA_STATE 16018c2ecf20Sopenharmony_ci def_bool $(as-instr,.cfi_startproc\n.cfi_negate_ra_state\n.cfi_endproc\n) 16028c2ecf20Sopenharmony_ci 16038c2ecf20Sopenharmony_ciendmenu 16048c2ecf20Sopenharmony_ci 16058c2ecf20Sopenharmony_cimenu "ARMv8.4 architectural features" 16068c2ecf20Sopenharmony_ci 16078c2ecf20Sopenharmony_ciconfig ARM64_AMU_EXTN 16088c2ecf20Sopenharmony_ci bool "Enable support for the Activity Monitors Unit CPU extension" 16098c2ecf20Sopenharmony_ci default y 16108c2ecf20Sopenharmony_ci help 16118c2ecf20Sopenharmony_ci The activity monitors extension is an optional extension introduced 16128c2ecf20Sopenharmony_ci by the ARMv8.4 CPU architecture. This enables support for version 1 16138c2ecf20Sopenharmony_ci of the activity monitors architecture, AMUv1. 16148c2ecf20Sopenharmony_ci 16158c2ecf20Sopenharmony_ci To enable the use of this extension on CPUs that implement it, say Y. 16168c2ecf20Sopenharmony_ci 16178c2ecf20Sopenharmony_ci Note that for architectural reasons, firmware _must_ implement AMU 16188c2ecf20Sopenharmony_ci support when running on CPUs that present the activity monitors 16198c2ecf20Sopenharmony_ci extension. The required support is present in: 16208c2ecf20Sopenharmony_ci * Version 1.5 and later of the ARM Trusted Firmware 16218c2ecf20Sopenharmony_ci 16228c2ecf20Sopenharmony_ci For kernels that have this configuration enabled but boot with broken 16238c2ecf20Sopenharmony_ci firmware, you may need to say N here until the firmware is fixed. 16248c2ecf20Sopenharmony_ci Otherwise you may experience firmware panics or lockups when 16258c2ecf20Sopenharmony_ci accessing the counter registers. Even if you are not observing these 16268c2ecf20Sopenharmony_ci symptoms, the values returned by the register reads might not 16278c2ecf20Sopenharmony_ci correctly reflect reality. Most commonly, the value read will be 0, 16288c2ecf20Sopenharmony_ci indicating that the counter is not enabled. 16298c2ecf20Sopenharmony_ci 16308c2ecf20Sopenharmony_ciconfig AS_HAS_ARMV8_4 16318c2ecf20Sopenharmony_ci def_bool $(cc-option,-Wa$(comma)-march=armv8.4-a) 16328c2ecf20Sopenharmony_ci 16338c2ecf20Sopenharmony_ciconfig ARM64_TLB_RANGE 16348c2ecf20Sopenharmony_ci bool "Enable support for tlbi range feature" 16358c2ecf20Sopenharmony_ci default y 16368c2ecf20Sopenharmony_ci depends on AS_HAS_ARMV8_4 16378c2ecf20Sopenharmony_ci help 16388c2ecf20Sopenharmony_ci ARMv8.4-TLBI provides TLBI invalidation instruction that apply to a 16398c2ecf20Sopenharmony_ci range of input addresses. 16408c2ecf20Sopenharmony_ci 16418c2ecf20Sopenharmony_ci The feature introduces new assembly instructions, and they were 16428c2ecf20Sopenharmony_ci support when binutils >= 2.30. 16438c2ecf20Sopenharmony_ci 16448c2ecf20Sopenharmony_ciendmenu 16458c2ecf20Sopenharmony_ci 16468c2ecf20Sopenharmony_cimenu "ARMv8.5 architectural features" 16478c2ecf20Sopenharmony_ci 16488c2ecf20Sopenharmony_ciconfig ARM64_BTI 16498c2ecf20Sopenharmony_ci bool "Branch Target Identification support" 16508c2ecf20Sopenharmony_ci default y 16518c2ecf20Sopenharmony_ci help 16528c2ecf20Sopenharmony_ci Branch Target Identification (part of the ARMv8.5 Extensions) 16538c2ecf20Sopenharmony_ci provides a mechanism to limit the set of locations to which computed 16548c2ecf20Sopenharmony_ci branch instructions such as BR or BLR can jump. 16558c2ecf20Sopenharmony_ci 16568c2ecf20Sopenharmony_ci To make use of BTI on CPUs that support it, say Y. 16578c2ecf20Sopenharmony_ci 16588c2ecf20Sopenharmony_ci BTI is intended to provide complementary protection to other control 16598c2ecf20Sopenharmony_ci flow integrity protection mechanisms, such as the Pointer 16608c2ecf20Sopenharmony_ci authentication mechanism provided as part of the ARMv8.3 Extensions. 16618c2ecf20Sopenharmony_ci For this reason, it does not make sense to enable this option without 16628c2ecf20Sopenharmony_ci also enabling support for pointer authentication. Thus, when 16638c2ecf20Sopenharmony_ci enabling this option you should also select ARM64_PTR_AUTH=y. 16648c2ecf20Sopenharmony_ci 16658c2ecf20Sopenharmony_ci Userspace binaries must also be specifically compiled to make use of 16668c2ecf20Sopenharmony_ci this mechanism. If you say N here or the hardware does not support 16678c2ecf20Sopenharmony_ci BTI, such binaries can still run, but you get no additional 16688c2ecf20Sopenharmony_ci enforcement of branch destinations. 16698c2ecf20Sopenharmony_ci 16708c2ecf20Sopenharmony_ciconfig ARM64_BTI_KERNEL 16718c2ecf20Sopenharmony_ci bool "Use Branch Target Identification for kernel" 16728c2ecf20Sopenharmony_ci default y 16738c2ecf20Sopenharmony_ci depends on ARM64_BTI 16748c2ecf20Sopenharmony_ci depends on ARM64_PTR_AUTH 16758c2ecf20Sopenharmony_ci depends on CC_HAS_BRANCH_PROT_PAC_RET_BTI 16768c2ecf20Sopenharmony_ci # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94697 16778c2ecf20Sopenharmony_ci depends on !CC_IS_GCC || GCC_VERSION >= 100100 16788c2ecf20Sopenharmony_ci # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106671 16798c2ecf20Sopenharmony_ci depends on !CC_IS_GCC 16808c2ecf20Sopenharmony_ci # https://github.com/llvm/llvm-project/commit/a88c722e687e6780dcd6a58718350dc76fcc4cc9 16818c2ecf20Sopenharmony_ci depends on !CC_IS_CLANG || CLANG_VERSION >= 120000 16828c2ecf20Sopenharmony_ci depends on (!FUNCTION_GRAPH_TRACER || DYNAMIC_FTRACE_WITH_REGS) 16838c2ecf20Sopenharmony_ci help 16848c2ecf20Sopenharmony_ci Build the kernel with Branch Target Identification annotations 16858c2ecf20Sopenharmony_ci and enable enforcement of this for kernel code. When this option 16868c2ecf20Sopenharmony_ci is enabled and the system supports BTI all kernel code including 16878c2ecf20Sopenharmony_ci modular code must have BTI enabled. 16888c2ecf20Sopenharmony_ci 16898c2ecf20Sopenharmony_ciconfig CC_HAS_BRANCH_PROT_PAC_RET_BTI 16908c2ecf20Sopenharmony_ci # GCC 9 or later, clang 8 or later 16918c2ecf20Sopenharmony_ci def_bool $(cc-option,-mbranch-protection=pac-ret+leaf+bti) 16928c2ecf20Sopenharmony_ci 16938c2ecf20Sopenharmony_ciconfig ARM64_E0PD 16948c2ecf20Sopenharmony_ci bool "Enable support for E0PD" 16958c2ecf20Sopenharmony_ci default y 16968c2ecf20Sopenharmony_ci help 16978c2ecf20Sopenharmony_ci E0PD (part of the ARMv8.5 extensions) allows us to ensure 16988c2ecf20Sopenharmony_ci that EL0 accesses made via TTBR1 always fault in constant time, 16998c2ecf20Sopenharmony_ci providing similar benefits to KASLR as those provided by KPTI, but 17008c2ecf20Sopenharmony_ci with lower overhead and without disrupting legitimate access to 17018c2ecf20Sopenharmony_ci kernel memory such as SPE. 17028c2ecf20Sopenharmony_ci 17038c2ecf20Sopenharmony_ci This option enables E0PD for TTBR1 where available. 17048c2ecf20Sopenharmony_ci 17058c2ecf20Sopenharmony_ciconfig ARCH_RANDOM 17068c2ecf20Sopenharmony_ci bool "Enable support for random number generation" 17078c2ecf20Sopenharmony_ci default y 17088c2ecf20Sopenharmony_ci help 17098c2ecf20Sopenharmony_ci Random number generation (part of the ARMv8.5 Extensions) 17108c2ecf20Sopenharmony_ci provides a high bandwidth, cryptographically secure 17118c2ecf20Sopenharmony_ci hardware random number generator. 17128c2ecf20Sopenharmony_ci 17138c2ecf20Sopenharmony_ciconfig ARM64_AS_HAS_MTE 17148c2ecf20Sopenharmony_ci # Initial support for MTE went in binutils 2.32.0, checked with 17158c2ecf20Sopenharmony_ci # ".arch armv8.5-a+memtag" below. However, this was incomplete 17168c2ecf20Sopenharmony_ci # as a late addition to the final architecture spec (LDGM/STGM) 17178c2ecf20Sopenharmony_ci # is only supported in the newer 2.32.x and 2.33 binutils 17188c2ecf20Sopenharmony_ci # versions, hence the extra "stgm" instruction check below. 17198c2ecf20Sopenharmony_ci def_bool $(as-instr,.arch armv8.5-a+memtag\nstgm xzr$(comma)[x0]) 17208c2ecf20Sopenharmony_ci 17218c2ecf20Sopenharmony_ciconfig ARM64_MTE 17228c2ecf20Sopenharmony_ci bool "Memory Tagging Extension support" 17238c2ecf20Sopenharmony_ci default y 17248c2ecf20Sopenharmony_ci depends on ARM64_AS_HAS_MTE && ARM64_TAGGED_ADDR_ABI 17258c2ecf20Sopenharmony_ci depends on AS_HAS_LSE_ATOMICS 17268c2ecf20Sopenharmony_ci select ARCH_USES_HIGH_VMA_FLAGS 17278c2ecf20Sopenharmony_ci help 17288c2ecf20Sopenharmony_ci Memory Tagging (part of the ARMv8.5 Extensions) provides 17298c2ecf20Sopenharmony_ci architectural support for run-time, always-on detection of 17308c2ecf20Sopenharmony_ci various classes of memory error to aid with software debugging 17318c2ecf20Sopenharmony_ci to eliminate vulnerabilities arising from memory-unsafe 17328c2ecf20Sopenharmony_ci languages. 17338c2ecf20Sopenharmony_ci 17348c2ecf20Sopenharmony_ci This option enables the support for the Memory Tagging 17358c2ecf20Sopenharmony_ci Extension at EL0 (i.e. for userspace). 17368c2ecf20Sopenharmony_ci 17378c2ecf20Sopenharmony_ci Selecting this option allows the feature to be detected at 17388c2ecf20Sopenharmony_ci runtime. Any secondary CPU not implementing this feature will 17398c2ecf20Sopenharmony_ci not be allowed a late bring-up. 17408c2ecf20Sopenharmony_ci 17418c2ecf20Sopenharmony_ci Userspace binaries that want to use this feature must 17428c2ecf20Sopenharmony_ci explicitly opt in. The mechanism for the userspace is 17438c2ecf20Sopenharmony_ci described in: 17448c2ecf20Sopenharmony_ci 17458c2ecf20Sopenharmony_ci Documentation/arm64/memory-tagging-extension.rst. 17468c2ecf20Sopenharmony_ci 17478c2ecf20Sopenharmony_ciendmenu 17488c2ecf20Sopenharmony_ci 17498c2ecf20Sopenharmony_ciconfig ARM64_SVE 17508c2ecf20Sopenharmony_ci bool "ARM Scalable Vector Extension support" 17518c2ecf20Sopenharmony_ci default y 17528c2ecf20Sopenharmony_ci depends on !KVM || ARM64_VHE 17538c2ecf20Sopenharmony_ci help 17548c2ecf20Sopenharmony_ci The Scalable Vector Extension (SVE) is an extension to the AArch64 17558c2ecf20Sopenharmony_ci execution state which complements and extends the SIMD functionality 17568c2ecf20Sopenharmony_ci of the base architecture to support much larger vectors and to enable 17578c2ecf20Sopenharmony_ci additional vectorisation opportunities. 17588c2ecf20Sopenharmony_ci 17598c2ecf20Sopenharmony_ci To enable use of this extension on CPUs that implement it, say Y. 17608c2ecf20Sopenharmony_ci 17618c2ecf20Sopenharmony_ci On CPUs that support the SVE2 extensions, this option will enable 17628c2ecf20Sopenharmony_ci those too. 17638c2ecf20Sopenharmony_ci 17648c2ecf20Sopenharmony_ci Note that for architectural reasons, firmware _must_ implement SVE 17658c2ecf20Sopenharmony_ci support when running on SVE capable hardware. The required support 17668c2ecf20Sopenharmony_ci is present in: 17678c2ecf20Sopenharmony_ci 17688c2ecf20Sopenharmony_ci * version 1.5 and later of the ARM Trusted Firmware 17698c2ecf20Sopenharmony_ci * the AArch64 boot wrapper since commit 5e1261e08abf 17708c2ecf20Sopenharmony_ci ("bootwrapper: SVE: Enable SVE for EL2 and below"). 17718c2ecf20Sopenharmony_ci 17728c2ecf20Sopenharmony_ci For other firmware implementations, consult the firmware documentation 17738c2ecf20Sopenharmony_ci or vendor. 17748c2ecf20Sopenharmony_ci 17758c2ecf20Sopenharmony_ci If you need the kernel to boot on SVE-capable hardware with broken 17768c2ecf20Sopenharmony_ci firmware, you may need to say N here until you get your firmware 17778c2ecf20Sopenharmony_ci fixed. Otherwise, you may experience firmware panics or lockups when 17788c2ecf20Sopenharmony_ci booting the kernel. If unsure and you are not observing these 17798c2ecf20Sopenharmony_ci symptoms, you should assume that it is safe to say Y. 17808c2ecf20Sopenharmony_ci 17818c2ecf20Sopenharmony_ci CPUs that support SVE are architecturally required to support the 17828c2ecf20Sopenharmony_ci Virtualization Host Extensions (VHE), so the kernel makes no 17838c2ecf20Sopenharmony_ci provision for supporting SVE alongside KVM without VHE enabled. 17848c2ecf20Sopenharmony_ci Thus, you will need to enable CONFIG_ARM64_VHE if you want to support 17858c2ecf20Sopenharmony_ci KVM in the same kernel image. 17868c2ecf20Sopenharmony_ci 17878c2ecf20Sopenharmony_ciconfig ARM64_MODULE_PLTS 17888c2ecf20Sopenharmony_ci bool "Use PLTs to allow module memory to spill over into vmalloc area" 17898c2ecf20Sopenharmony_ci depends on MODULES 17908c2ecf20Sopenharmony_ci select HAVE_MOD_ARCH_SPECIFIC 17918c2ecf20Sopenharmony_ci help 17928c2ecf20Sopenharmony_ci Allocate PLTs when loading modules so that jumps and calls whose 17938c2ecf20Sopenharmony_ci targets are too far away for their relative offsets to be encoded 17948c2ecf20Sopenharmony_ci in the instructions themselves can be bounced via veneers in the 17958c2ecf20Sopenharmony_ci module's PLT. This allows modules to be allocated in the generic 17968c2ecf20Sopenharmony_ci vmalloc area after the dedicated module memory area has been 17978c2ecf20Sopenharmony_ci exhausted. 17988c2ecf20Sopenharmony_ci 17998c2ecf20Sopenharmony_ci When running with address space randomization (KASLR), the module 18008c2ecf20Sopenharmony_ci region itself may be too far away for ordinary relative jumps and 18018c2ecf20Sopenharmony_ci calls, and so in that case, module PLTs are required and cannot be 18028c2ecf20Sopenharmony_ci disabled. 18038c2ecf20Sopenharmony_ci 18048c2ecf20Sopenharmony_ci Specific errata workaround(s) might also force module PLTs to be 18058c2ecf20Sopenharmony_ci enabled (ARM64_ERRATUM_843419). 18068c2ecf20Sopenharmony_ci 18078c2ecf20Sopenharmony_ciconfig ARM64_PSEUDO_NMI 18088c2ecf20Sopenharmony_ci bool "Support for NMI-like interrupts" 18098c2ecf20Sopenharmony_ci select ARM_GIC_V3 18108c2ecf20Sopenharmony_ci help 18118c2ecf20Sopenharmony_ci Adds support for mimicking Non-Maskable Interrupts through the use of 18128c2ecf20Sopenharmony_ci GIC interrupt priority. This support requires version 3 or later of 18138c2ecf20Sopenharmony_ci ARM GIC. 18148c2ecf20Sopenharmony_ci 18158c2ecf20Sopenharmony_ci This high priority configuration for interrupts needs to be 18168c2ecf20Sopenharmony_ci explicitly enabled by setting the kernel parameter 18178c2ecf20Sopenharmony_ci "irqchip.gicv3_pseudo_nmi" to 1. 18188c2ecf20Sopenharmony_ci 18198c2ecf20Sopenharmony_ci If unsure, say N 18208c2ecf20Sopenharmony_ci 18218c2ecf20Sopenharmony_ciif ARM64_PSEUDO_NMI 18228c2ecf20Sopenharmony_ciconfig ARM64_DEBUG_PRIORITY_MASKING 18238c2ecf20Sopenharmony_ci bool "Debug interrupt priority masking" 18248c2ecf20Sopenharmony_ci help 18258c2ecf20Sopenharmony_ci This adds runtime checks to functions enabling/disabling 18268c2ecf20Sopenharmony_ci interrupts when using priority masking. The additional checks verify 18278c2ecf20Sopenharmony_ci the validity of ICC_PMR_EL1 when calling concerned functions. 18288c2ecf20Sopenharmony_ci 18298c2ecf20Sopenharmony_ci If unsure, say N 18308c2ecf20Sopenharmony_ciendif 18318c2ecf20Sopenharmony_ci 18328c2ecf20Sopenharmony_ciconfig RELOCATABLE 18338c2ecf20Sopenharmony_ci bool "Build a relocatable kernel image" if EXPERT 18348c2ecf20Sopenharmony_ci select ARCH_HAS_RELR 18358c2ecf20Sopenharmony_ci default y 18368c2ecf20Sopenharmony_ci help 18378c2ecf20Sopenharmony_ci This builds the kernel as a Position Independent Executable (PIE), 18388c2ecf20Sopenharmony_ci which retains all relocation metadata required to relocate the 18398c2ecf20Sopenharmony_ci kernel binary at runtime to a different virtual address than the 18408c2ecf20Sopenharmony_ci address it was linked at. 18418c2ecf20Sopenharmony_ci Since AArch64 uses the RELA relocation format, this requires a 18428c2ecf20Sopenharmony_ci relocation pass at runtime even if the kernel is loaded at the 18438c2ecf20Sopenharmony_ci same address it was linked at. 18448c2ecf20Sopenharmony_ci 18458c2ecf20Sopenharmony_ciconfig RANDOMIZE_BASE 18468c2ecf20Sopenharmony_ci bool "Randomize the address of the kernel image" 18478c2ecf20Sopenharmony_ci select ARM64_MODULE_PLTS if MODULES 18488c2ecf20Sopenharmony_ci select RELOCATABLE 18498c2ecf20Sopenharmony_ci help 18508c2ecf20Sopenharmony_ci Randomizes the virtual address at which the kernel image is 18518c2ecf20Sopenharmony_ci loaded, as a security feature that deters exploit attempts 18528c2ecf20Sopenharmony_ci relying on knowledge of the location of kernel internals. 18538c2ecf20Sopenharmony_ci 18548c2ecf20Sopenharmony_ci It is the bootloader's job to provide entropy, by passing a 18558c2ecf20Sopenharmony_ci random u64 value in /chosen/kaslr-seed at kernel entry. 18568c2ecf20Sopenharmony_ci 18578c2ecf20Sopenharmony_ci When booting via the UEFI stub, it will invoke the firmware's 18588c2ecf20Sopenharmony_ci EFI_RNG_PROTOCOL implementation (if available) to supply entropy 18598c2ecf20Sopenharmony_ci to the kernel proper. In addition, it will randomise the physical 18608c2ecf20Sopenharmony_ci location of the kernel Image as well. 18618c2ecf20Sopenharmony_ci 18628c2ecf20Sopenharmony_ci If unsure, say N. 18638c2ecf20Sopenharmony_ci 18648c2ecf20Sopenharmony_ciconfig RANDOMIZE_MODULE_REGION_FULL 18658c2ecf20Sopenharmony_ci bool "Randomize the module region over a 4 GB range" 18668c2ecf20Sopenharmony_ci depends on RANDOMIZE_BASE 18678c2ecf20Sopenharmony_ci default y 18688c2ecf20Sopenharmony_ci help 18698c2ecf20Sopenharmony_ci Randomizes the location of the module region inside a 4 GB window 18708c2ecf20Sopenharmony_ci covering the core kernel. This way, it is less likely for modules 18718c2ecf20Sopenharmony_ci to leak information about the location of core kernel data structures 18728c2ecf20Sopenharmony_ci but it does imply that function calls between modules and the core 18738c2ecf20Sopenharmony_ci kernel will need to be resolved via veneers in the module PLT. 18748c2ecf20Sopenharmony_ci 18758c2ecf20Sopenharmony_ci When this option is not set, the module region will be randomized over 18768c2ecf20Sopenharmony_ci a limited range that contains the [_stext, _etext] interval of the 18778c2ecf20Sopenharmony_ci core kernel, so branch relocations are always in range. 18788c2ecf20Sopenharmony_ci 18798c2ecf20Sopenharmony_ciconfig CC_HAVE_STACKPROTECTOR_SYSREG 18808c2ecf20Sopenharmony_ci def_bool $(cc-option,-mstack-protector-guard=sysreg -mstack-protector-guard-reg=sp_el0 -mstack-protector-guard-offset=0) 18818c2ecf20Sopenharmony_ci 18828c2ecf20Sopenharmony_ciconfig STACKPROTECTOR_PER_TASK 18838c2ecf20Sopenharmony_ci def_bool y 18848c2ecf20Sopenharmony_ci depends on STACKPROTECTOR && CC_HAVE_STACKPROTECTOR_SYSREG 18858c2ecf20Sopenharmony_ci 18868c2ecf20Sopenharmony_ciendmenu 18878c2ecf20Sopenharmony_ci 18888c2ecf20Sopenharmony_cimenu "Boot options" 18898c2ecf20Sopenharmony_ci 18908c2ecf20Sopenharmony_ciconfig ARM64_ACPI_PARKING_PROTOCOL 18918c2ecf20Sopenharmony_ci bool "Enable support for the ARM64 ACPI parking protocol" 18928c2ecf20Sopenharmony_ci depends on ACPI 18938c2ecf20Sopenharmony_ci help 18948c2ecf20Sopenharmony_ci Enable support for the ARM64 ACPI parking protocol. If disabled 18958c2ecf20Sopenharmony_ci the kernel will not allow booting through the ARM64 ACPI parking 18968c2ecf20Sopenharmony_ci protocol even if the corresponding data is present in the ACPI 18978c2ecf20Sopenharmony_ci MADT table. 18988c2ecf20Sopenharmony_ci 18998c2ecf20Sopenharmony_ciconfig CMDLINE 19008c2ecf20Sopenharmony_ci string "Default kernel command string" 19018c2ecf20Sopenharmony_ci default "" 19028c2ecf20Sopenharmony_ci help 19038c2ecf20Sopenharmony_ci Provide a set of default command-line options at build time by 19048c2ecf20Sopenharmony_ci entering them here. As a minimum, you should specify the the 19058c2ecf20Sopenharmony_ci root device (e.g. root=/dev/nfs). 19068c2ecf20Sopenharmony_ci 19078c2ecf20Sopenharmony_ciconfig CMDLINE_FORCE 19088c2ecf20Sopenharmony_ci bool "Always use the default kernel command string" 19098c2ecf20Sopenharmony_ci depends on CMDLINE != "" 19108c2ecf20Sopenharmony_ci help 19118c2ecf20Sopenharmony_ci Always use the default kernel command string, even if the boot 19128c2ecf20Sopenharmony_ci loader passes other arguments to the kernel. 19138c2ecf20Sopenharmony_ci This is useful if you cannot or don't want to change the 19148c2ecf20Sopenharmony_ci command-line options your boot loader passes to the kernel. 19158c2ecf20Sopenharmony_ci 19168c2ecf20Sopenharmony_ciconfig EFI_STUB 19178c2ecf20Sopenharmony_ci bool 19188c2ecf20Sopenharmony_ci 19198c2ecf20Sopenharmony_ciconfig EFI 19208c2ecf20Sopenharmony_ci bool "UEFI runtime support" 19218c2ecf20Sopenharmony_ci depends on OF && !CPU_BIG_ENDIAN 19228c2ecf20Sopenharmony_ci depends on KERNEL_MODE_NEON 19238c2ecf20Sopenharmony_ci select ARCH_SUPPORTS_ACPI 19248c2ecf20Sopenharmony_ci select LIBFDT 19258c2ecf20Sopenharmony_ci select UCS2_STRING 19268c2ecf20Sopenharmony_ci select EFI_PARAMS_FROM_FDT 19278c2ecf20Sopenharmony_ci select EFI_RUNTIME_WRAPPERS 19288c2ecf20Sopenharmony_ci select EFI_STUB 19298c2ecf20Sopenharmony_ci select EFI_GENERIC_STUB 19308c2ecf20Sopenharmony_ci default y 19318c2ecf20Sopenharmony_ci help 19328c2ecf20Sopenharmony_ci This option provides support for runtime services provided 19338c2ecf20Sopenharmony_ci by UEFI firmware (such as non-volatile variables, realtime 19348c2ecf20Sopenharmony_ci clock, and platform reset). A UEFI stub is also provided to 19358c2ecf20Sopenharmony_ci allow the kernel to be booted as an EFI application. This 19368c2ecf20Sopenharmony_ci is only useful on systems that have UEFI firmware. 19378c2ecf20Sopenharmony_ci 19388c2ecf20Sopenharmony_ciconfig DMI 19398c2ecf20Sopenharmony_ci bool "Enable support for SMBIOS (DMI) tables" 19408c2ecf20Sopenharmony_ci depends on EFI 19418c2ecf20Sopenharmony_ci default y 19428c2ecf20Sopenharmony_ci help 19438c2ecf20Sopenharmony_ci This enables SMBIOS/DMI feature for systems. 19448c2ecf20Sopenharmony_ci 19458c2ecf20Sopenharmony_ci This option is only useful on systems that have UEFI firmware. 19468c2ecf20Sopenharmony_ci However, even with this option, the resultant kernel should 19478c2ecf20Sopenharmony_ci continue to boot on existing non-UEFI platforms. 19488c2ecf20Sopenharmony_ci 19498c2ecf20Sopenharmony_ciendmenu 19508c2ecf20Sopenharmony_ci 19518c2ecf20Sopenharmony_ciconfig SYSVIPC_COMPAT 19528c2ecf20Sopenharmony_ci def_bool y 19538c2ecf20Sopenharmony_ci depends on COMPAT && SYSVIPC 19548c2ecf20Sopenharmony_ci 19558c2ecf20Sopenharmony_ciconfig ARCH_ENABLE_HUGEPAGE_MIGRATION 19568c2ecf20Sopenharmony_ci def_bool y 19578c2ecf20Sopenharmony_ci depends on HUGETLB_PAGE && MIGRATION 19588c2ecf20Sopenharmony_ci 19598c2ecf20Sopenharmony_ciconfig ARCH_ENABLE_THP_MIGRATION 19608c2ecf20Sopenharmony_ci def_bool y 19618c2ecf20Sopenharmony_ci depends on TRANSPARENT_HUGEPAGE 19628c2ecf20Sopenharmony_ci 19638c2ecf20Sopenharmony_cimenu "Power management options" 19648c2ecf20Sopenharmony_ci 19658c2ecf20Sopenharmony_cisource "kernel/power/Kconfig" 19668c2ecf20Sopenharmony_ci 19678c2ecf20Sopenharmony_ciconfig ARCH_HIBERNATION_POSSIBLE 19688c2ecf20Sopenharmony_ci def_bool y 19698c2ecf20Sopenharmony_ci depends on CPU_PM 19708c2ecf20Sopenharmony_ci 19718c2ecf20Sopenharmony_ciconfig ARCH_HIBERNATION_HEADER 19728c2ecf20Sopenharmony_ci def_bool y 19738c2ecf20Sopenharmony_ci depends on HIBERNATION 19748c2ecf20Sopenharmony_ci 19758c2ecf20Sopenharmony_ciconfig ARCH_SUSPEND_POSSIBLE 19768c2ecf20Sopenharmony_ci def_bool y 19778c2ecf20Sopenharmony_ci 19788c2ecf20Sopenharmony_ciendmenu 19798c2ecf20Sopenharmony_ci 19808c2ecf20Sopenharmony_cimenu "CPU Power Management" 19818c2ecf20Sopenharmony_ci 19828c2ecf20Sopenharmony_cisource "drivers/cpuidle/Kconfig" 19838c2ecf20Sopenharmony_ci 19848c2ecf20Sopenharmony_cisource "drivers/cpufreq/Kconfig" 19858c2ecf20Sopenharmony_ci 19868c2ecf20Sopenharmony_ciendmenu 19878c2ecf20Sopenharmony_ci 19888c2ecf20Sopenharmony_cisource "drivers/firmware/Kconfig" 19898c2ecf20Sopenharmony_ci 19908c2ecf20Sopenharmony_cisource "drivers/acpi/Kconfig" 19918c2ecf20Sopenharmony_ci 19928c2ecf20Sopenharmony_cisource "arch/arm64/kvm/Kconfig" 19938c2ecf20Sopenharmony_ci 19948c2ecf20Sopenharmony_ciif CRYPTO 19958c2ecf20Sopenharmony_cisource "arch/arm64/crypto/Kconfig" 19968c2ecf20Sopenharmony_ciendif 1997