xref: /linux/arch/s390/Kconfig (revision 9b03fa105c6978f0e20fd311ac903226a9e89890)
1# SPDX-License-Identifier: GPL-2.0
2config MMU
3	def_bool y
4
5config CPU_BIG_ENDIAN
6	def_bool y
7
8config LOCKDEP_SUPPORT
9	def_bool y
10
11config STACKTRACE_SUPPORT
12	def_bool y
13
14config ARCH_HAS_ILOG2_U32
15	def_bool n
16
17config ARCH_HAS_ILOG2_U64
18	def_bool n
19
20config ARCH_PROC_KCORE_TEXT
21	def_bool y
22
23config GENERIC_HWEIGHT
24	def_bool !HAVE_MARCH_Z196_FEATURES
25
26config GENERIC_BUG
27	def_bool y if BUG
28
29config GENERIC_BUG_RELATIVE_POINTERS
30	def_bool y
31
32config GENERIC_LOCKBREAK
33	def_bool y if PREEMPTION
34
35config PGSTE
36	def_bool y if KVM
37
38config AUDIT_ARCH
39	def_bool y
40
41config NO_IOPORT_MAP
42	def_bool y
43
44config ARCH_SUPPORTS_UPROBES
45	def_bool y
46
47config KASAN_SHADOW_OFFSET
48	hex
49	depends on KASAN
50	default 0x1C000000000000
51
52config CC_ASM_FLAG_OUTPUT_BROKEN
53	def_bool CC_IS_GCC && GCC_VERSION < 140200
54	help
55	  GCC versions before 14.2.0 may die with an internal
56	  compiler error in some configurations if flag output
57	  operands are used within inline assemblies.
58
59config CC_HAS_ASM_AOR_FORMAT_FLAGS
60	def_bool !(CC_IS_CLANG && CLANG_VERSION < 190100)
61	help
62	  Clang versions before 19.1.0 do not support A,
63	  O, and R inline assembly format flags.
64
65config S390
66	def_bool y
67	#
68	# Note: keep this list sorted alphabetically
69	#
70	imply IMA_SECURE_AND_OR_TRUSTED_BOOT
71	select ALTERNATE_USER_ADDRESS_SPACE
72	select ARCH_32BIT_USTAT_F_TINODE
73	select ARCH_CORRECT_STACKTRACE_ON_KRETPROBE
74	select ARCH_ENABLE_MEMORY_HOTPLUG if SPARSEMEM
75	select ARCH_ENABLE_MEMORY_HOTREMOVE
76	select ARCH_ENABLE_SPLIT_PMD_PTLOCK if PGTABLE_LEVELS > 2
77	select ARCH_HAS_CPU_FINALIZE_INIT
78	select ARCH_HAS_CRC32
79	select ARCH_HAS_CURRENT_STACK_POINTER
80	select ARCH_HAS_DEBUG_VIRTUAL
81	select ARCH_HAS_DEBUG_VM_PGTABLE
82	select ARCH_HAS_DEBUG_WX
83	select ARCH_HAS_DEVMEM_IS_ALLOWED
84	select ARCH_HAS_DMA_OPS if PCI
85	select ARCH_HAS_ELF_RANDOMIZE
86	select ARCH_HAS_FORCE_DMA_UNENCRYPTED
87	select ARCH_HAS_FORTIFY_SOURCE
88	select ARCH_HAS_GCOV_PROFILE_ALL
89	select ARCH_HAS_GIGANTIC_PAGE
90	select ARCH_HAS_KCOV
91	select ARCH_HAS_MEMBARRIER_SYNC_CORE
92	select ARCH_HAS_MEM_ENCRYPT
93	select ARCH_HAS_NMI_SAFE_THIS_CPU_OPS
94	select ARCH_HAS_PREEMPT_LAZY
95	select ARCH_HAS_PTDUMP
96	select ARCH_HAS_PTE_SPECIAL
97	select ARCH_HAS_SCALED_CPUTIME
98	select ARCH_HAS_SET_DIRECT_MAP
99	select ARCH_HAS_SET_MEMORY
100	select ARCH_HAS_STRICT_KERNEL_RWX
101	select ARCH_HAS_STRICT_MODULE_RWX
102	select ARCH_HAS_SYSCALL_WRAPPER
103	select ARCH_HAS_UBSAN
104	select ARCH_HAS_VDSO_TIME_DATA
105	select ARCH_HAVE_NMI_SAFE_CMPXCHG
106	select ARCH_INLINE_READ_LOCK
107	select ARCH_INLINE_READ_LOCK_BH
108	select ARCH_INLINE_READ_LOCK_IRQ
109	select ARCH_INLINE_READ_LOCK_IRQSAVE
110	select ARCH_INLINE_READ_TRYLOCK
111	select ARCH_INLINE_READ_UNLOCK
112	select ARCH_INLINE_READ_UNLOCK_BH
113	select ARCH_INLINE_READ_UNLOCK_IRQ
114	select ARCH_INLINE_READ_UNLOCK_IRQRESTORE
115	select ARCH_INLINE_SPIN_LOCK
116	select ARCH_INLINE_SPIN_LOCK_BH
117	select ARCH_INLINE_SPIN_LOCK_IRQ
118	select ARCH_INLINE_SPIN_LOCK_IRQSAVE
119	select ARCH_INLINE_SPIN_TRYLOCK
120	select ARCH_INLINE_SPIN_TRYLOCK_BH
121	select ARCH_INLINE_SPIN_UNLOCK
122	select ARCH_INLINE_SPIN_UNLOCK_BH
123	select ARCH_INLINE_SPIN_UNLOCK_IRQ
124	select ARCH_INLINE_SPIN_UNLOCK_IRQRESTORE
125	select ARCH_INLINE_WRITE_LOCK
126	select ARCH_INLINE_WRITE_LOCK_BH
127	select ARCH_INLINE_WRITE_LOCK_IRQ
128	select ARCH_INLINE_WRITE_LOCK_IRQSAVE
129	select ARCH_INLINE_WRITE_TRYLOCK
130	select ARCH_INLINE_WRITE_UNLOCK
131	select ARCH_INLINE_WRITE_UNLOCK_BH
132	select ARCH_INLINE_WRITE_UNLOCK_IRQ
133	select ARCH_INLINE_WRITE_UNLOCK_IRQRESTORE
134	select ARCH_MHP_MEMMAP_ON_MEMORY_ENABLE
135	select ARCH_STACKWALK
136	select ARCH_SUPPORTS_ATOMIC_RMW
137	select ARCH_SUPPORTS_DEBUG_PAGEALLOC
138	select ARCH_SUPPORTS_HUGETLBFS
139	select ARCH_SUPPORTS_INT128 if CC_HAS_INT128 && CC_IS_CLANG
140	select ARCH_SUPPORTS_MSEAL_SYSTEM_MAPPINGS
141	select ARCH_SUPPORTS_NUMA_BALANCING
142	select ARCH_SUPPORTS_PER_VMA_LOCK
143	select ARCH_USE_BUILTIN_BSWAP
144	select ARCH_USE_CMPXCHG_LOCKREF
145	select ARCH_USE_SYM_ANNOTATIONS
146	select ARCH_WANTS_NO_INSTR
147	select ARCH_WANT_DEFAULT_BPF_JIT
148	select ARCH_WANT_IPC_PARSE_VERSION
149	select ARCH_WANT_KERNEL_PMD_MKWRITE
150	select ARCH_WANT_LD_ORPHAN_WARN
151	select ARCH_WANT_OPTIMIZE_HUGETLB_VMEMMAP
152	select BUILDTIME_TABLE_SORT
153	select CLONE_BACKWARDS2
154	select DCACHE_WORD_ACCESS if !KMSAN
155	select DYNAMIC_FTRACE if FUNCTION_TRACER
156	select FUNCTION_ALIGNMENT_8B if CC_IS_GCC
157	select FUNCTION_ALIGNMENT_16B if !CC_IS_GCC
158	select GENERIC_ALLOCATOR
159	select GENERIC_CPU_DEVICES
160	select GENERIC_CPU_AUTOPROBE
161	select GENERIC_CPU_VULNERABILITIES
162	select GENERIC_ENTRY
163	select GENERIC_GETTIMEOFDAY
164	select GENERIC_SMP_IDLE_THREAD
165	select GENERIC_TIME_VSYSCALL
166	select GENERIC_VDSO_DATA_STORE
167	select GENERIC_VDSO_TIME_NS
168	select GENERIC_IOREMAP if PCI
169	select HAVE_ALIGNED_STRUCT_PAGE
170	select HAVE_ARCH_AUDITSYSCALL
171	select HAVE_ARCH_JUMP_LABEL
172	select HAVE_ARCH_JUMP_LABEL_RELATIVE
173	select HAVE_ARCH_KASAN
174	select HAVE_ARCH_KASAN_VMALLOC
175	select HAVE_ARCH_KCSAN
176	select HAVE_ARCH_KMSAN
177	select HAVE_ARCH_KFENCE
178	select HAVE_ARCH_RANDOMIZE_KSTACK_OFFSET
179	select HAVE_ARCH_SECCOMP_FILTER
180	select HAVE_ARCH_SOFT_DIRTY
181	select HAVE_ARCH_STACKLEAK
182	select HAVE_ARCH_TRACEHOOK
183	select HAVE_ARCH_TRANSPARENT_HUGEPAGE
184	select HAVE_ARCH_VMAP_STACK
185	select HAVE_ASM_MODVERSIONS
186	select HAVE_BUILDTIME_MCOUNT_SORT
187	select HAVE_CMPXCHG_DOUBLE
188	select HAVE_CMPXCHG_LOCAL
189	select HAVE_DEBUG_KMEMLEAK
190	select HAVE_DMA_CONTIGUOUS
191	select HAVE_DYNAMIC_FTRACE
192	select HAVE_DYNAMIC_FTRACE_WITH_ARGS
193	select HAVE_FTRACE_REGS_HAVING_PT_REGS
194	select HAVE_DYNAMIC_FTRACE_WITH_DIRECT_CALLS
195	select HAVE_DYNAMIC_FTRACE_WITH_REGS
196	select HAVE_EBPF_JIT if HAVE_MARCH_Z196_FEATURES
197	select HAVE_EFFICIENT_UNALIGNED_ACCESS
198	select HAVE_GUP_FAST
199	select HAVE_FENTRY
200	select HAVE_FTRACE_GRAPH_FUNC
201	select HAVE_FTRACE_MCOUNT_RECORD
202	select HAVE_FUNCTION_ARG_ACCESS_API
203	select HAVE_FUNCTION_ERROR_INJECTION
204	select HAVE_FUNCTION_GRAPH_FREGS
205	select HAVE_FUNCTION_GRAPH_TRACER
206	select HAVE_FUNCTION_TRACER
207	select HAVE_GCC_PLUGINS
208	select HAVE_GENERIC_VDSO
209	select HAVE_IOREMAP_PROT if PCI
210	select HAVE_KERNEL_BZIP2
211	select HAVE_KERNEL_GZIP
212	select HAVE_KERNEL_LZ4
213	select HAVE_KERNEL_LZMA
214	select HAVE_KERNEL_LZO
215	select HAVE_KERNEL_UNCOMPRESSED
216	select HAVE_KERNEL_XZ
217	select HAVE_KERNEL_ZSTD
218	select HAVE_KPROBES
219	select HAVE_KPROBES_ON_FTRACE
220	select HAVE_KRETPROBES
221	select HAVE_LIVEPATCH
222	select HAVE_MEMBLOCK_PHYS_MAP
223	select HAVE_MOD_ARCH_SPECIFIC
224	select HAVE_NMI
225	select HAVE_NOP_MCOUNT
226	select HAVE_PAGE_SIZE_4KB
227	select HAVE_PCI
228	select HAVE_PERF_EVENTS
229	select HAVE_PERF_REGS
230	select HAVE_PERF_USER_STACK_DUMP
231	select HAVE_PREEMPT_DYNAMIC_KEY
232	select HAVE_REGS_AND_STACK_ACCESS_API
233	select HAVE_RELIABLE_STACKTRACE
234	select HAVE_RETHOOK
235	select HAVE_RSEQ
236	select HAVE_SAMPLE_FTRACE_DIRECT
237	select HAVE_SAMPLE_FTRACE_DIRECT_MULTI
238	select HAVE_SETUP_PER_CPU_AREA
239	select HAVE_SOFTIRQ_ON_OWN_STACK
240	select HAVE_SYSCALL_TRACEPOINTS
241	select HAVE_VIRT_CPU_ACCOUNTING
242	select HAVE_VIRT_CPU_ACCOUNTING_IDLE
243	select HOTPLUG_SMT
244	select IOMMU_HELPER		if PCI
245	select IOMMU_SUPPORT		if PCI
246	select KASAN_VMALLOC if KASAN
247	select LOCK_MM_AND_FIND_VMA
248	select MMU_GATHER_MERGE_VMAS
249	select MMU_GATHER_NO_GATHER
250	select MMU_GATHER_RCU_TABLE_FREE
251	select MODULES_USE_ELF_RELA
252	select NEED_DMA_MAP_STATE	if PCI
253	select NEED_PER_CPU_EMBED_FIRST_CHUNK
254	select NEED_PROC_VMCORE_DEVICE_RAM if PROC_VMCORE
255	select NEED_SG_DMA_LENGTH	if PCI
256	select OLD_SIGACTION
257	select OLD_SIGSUSPEND3
258	select PCI_DOMAINS		if PCI
259	select PCI_MSI			if PCI
260	select PCI_MSI_ARCH_FALLBACKS	if PCI_MSI
261	select PCI_QUIRKS		if PCI
262	select SPARSE_IRQ
263	select SWIOTLB
264	select SYSCTL_EXCEPTION_TRACE
265	select THREAD_INFO_IN_TASK
266	select TRACE_IRQFLAGS_SUPPORT
267	select TTY
268	select USER_STACKTRACE_SUPPORT
269	select VDSO_GETRANDOM
270	select VIRT_CPU_ACCOUNTING
271	select VMAP_STACK
272	select ZONE_DMA
273	# Note: keep the above list sorted alphabetically
274
275config SCHED_OMIT_FRAME_POINTER
276	def_bool y
277
278config PGTABLE_LEVELS
279	int
280	default 5
281
282source "kernel/livepatch/Kconfig"
283
284config ARCH_SUPPORTS_KEXEC
285	def_bool y
286
287config ARCH_SUPPORTS_KEXEC_FILE
288	def_bool y
289
290config ARCH_SUPPORTS_KEXEC_SIG
291	def_bool MODULE_SIG_FORMAT
292
293config ARCH_SUPPORTS_KEXEC_PURGATORY
294	def_bool y
295
296config ARCH_SUPPORTS_CRASH_DUMP
297	def_bool y
298	help
299	  Refer to <file:Documentation/arch/s390/zfcpdump.rst> for more details on this.
300	  This option also enables s390 zfcpdump.
301	  See also <file:Documentation/arch/s390/zfcpdump.rst>
302
303config ARCH_DEFAULT_CRASH_DUMP
304	def_bool y
305
306menu "Processor type and features"
307
308config HAVE_MARCH_Z10_FEATURES
309	def_bool n
310
311config HAVE_MARCH_Z196_FEATURES
312	def_bool n
313	select HAVE_MARCH_Z10_FEATURES
314
315config HAVE_MARCH_ZEC12_FEATURES
316	def_bool n
317	select HAVE_MARCH_Z196_FEATURES
318
319config HAVE_MARCH_Z13_FEATURES
320	def_bool n
321	select HAVE_MARCH_ZEC12_FEATURES
322
323config HAVE_MARCH_Z14_FEATURES
324	def_bool n
325	select HAVE_MARCH_Z13_FEATURES
326
327config HAVE_MARCH_Z15_FEATURES
328	def_bool n
329	select HAVE_MARCH_Z14_FEATURES
330
331config HAVE_MARCH_Z16_FEATURES
332	def_bool n
333	select HAVE_MARCH_Z15_FEATURES
334
335config HAVE_MARCH_Z17_FEATURES
336	def_bool n
337	select HAVE_MARCH_Z16_FEATURES
338
339choice
340	prompt "Processor type"
341	default MARCH_Z196
342
343config MARCH_Z10
344	bool "IBM System z10"
345	select HAVE_MARCH_Z10_FEATURES
346	depends on $(cc-option,-march=z10)
347	help
348	  Select this to enable optimizations for IBM System z10 (2097 and 2098
349	  series). This is the oldest machine generation currently supported.
350
351config MARCH_Z196
352	bool "IBM zEnterprise 114 and 196"
353	select HAVE_MARCH_Z196_FEATURES
354	depends on $(cc-option,-march=z196)
355	help
356	  Select this to enable optimizations for IBM zEnterprise 114 and 196
357	  (2818 and 2817 series). The kernel will be slightly faster but will
358	  not work on older machines.
359
360config MARCH_ZEC12
361	bool "IBM zBC12 and zEC12"
362	select HAVE_MARCH_ZEC12_FEATURES
363	depends on $(cc-option,-march=zEC12)
364	help
365	  Select this to enable optimizations for IBM zBC12 and zEC12 (2828 and
366	  2827 series). The kernel will be slightly faster but will not work on
367	  older machines.
368
369config MARCH_Z13
370	bool "IBM z13s and z13"
371	select HAVE_MARCH_Z13_FEATURES
372	depends on $(cc-option,-march=z13)
373	help
374	  Select this to enable optimizations for IBM z13s and z13 (2965 and
375	  2964 series). The kernel will be slightly faster but will not work on
376	  older machines.
377
378config MARCH_Z14
379	bool "IBM z14 ZR1 and z14"
380	select HAVE_MARCH_Z14_FEATURES
381	depends on $(cc-option,-march=z14)
382	help
383	  Select this to enable optimizations for IBM z14 ZR1 and z14 (3907
384	  and 3906 series). The kernel will be slightly faster but will not
385	  work on older machines.
386
387config MARCH_Z15
388	bool "IBM z15"
389	select HAVE_MARCH_Z15_FEATURES
390	depends on $(cc-option,-march=z15)
391	help
392	  Select this to enable optimizations for IBM z15 (8562
393	  and 8561 series). The kernel will be slightly faster but will not
394	  work on older machines.
395
396config MARCH_Z16
397	bool "IBM z16"
398	select HAVE_MARCH_Z16_FEATURES
399	depends on $(cc-option,-march=z16)
400	help
401	  Select this to enable optimizations for IBM z16 (3931 and
402	  3932 series).
403
404config MARCH_Z17
405	bool "IBM z17"
406	select HAVE_MARCH_Z17_FEATURES
407	depends on $(cc-option,-march=z17)
408	help
409	  Select this to enable optimizations for IBM z17 (9175 and
410	  9176 series).
411
412endchoice
413
414config MARCH_Z10_TUNE
415	def_bool TUNE_Z10 || MARCH_Z10 && TUNE_DEFAULT
416
417config MARCH_Z196_TUNE
418	def_bool TUNE_Z196 || MARCH_Z196 && TUNE_DEFAULT
419
420config MARCH_ZEC12_TUNE
421	def_bool TUNE_ZEC12 || MARCH_ZEC12 && TUNE_DEFAULT
422
423config MARCH_Z13_TUNE
424	def_bool TUNE_Z13 || MARCH_Z13 && TUNE_DEFAULT
425
426config MARCH_Z14_TUNE
427	def_bool TUNE_Z14 || MARCH_Z14 && TUNE_DEFAULT
428
429config MARCH_Z15_TUNE
430	def_bool TUNE_Z15 || MARCH_Z15 && TUNE_DEFAULT
431
432config MARCH_Z16_TUNE
433	def_bool TUNE_Z16 || MARCH_Z16 && TUNE_DEFAULT
434
435config MARCH_Z17_TUNE
436	def_bool TUNE_Z17 || MARCH_Z17 && TUNE_DEFAULT
437
438choice
439	prompt "Tune code generation"
440	default TUNE_DEFAULT
441	help
442	  Cause the compiler to tune (-mtune) the generated code for a machine.
443	  This will make the code run faster on the selected machine but
444	  somewhat slower on other machines.
445	  This option only changes how the compiler emits instructions, not the
446	  selection of instructions itself, so the resulting kernel will run on
447	  all other machines.
448
449config TUNE_DEFAULT
450	bool "Default"
451	help
452	  Tune the generated code for the target processor for which the kernel
453	  will be compiled.
454
455config TUNE_Z10
456	bool "IBM System z10"
457
458config TUNE_Z196
459	bool "IBM zEnterprise 114 and 196"
460	depends on $(cc-option,-mtune=z196)
461
462config TUNE_ZEC12
463	bool "IBM zBC12 and zEC12"
464	depends on $(cc-option,-mtune=zEC12)
465
466config TUNE_Z13
467	bool "IBM z13s and z13"
468	depends on $(cc-option,-mtune=z13)
469
470config TUNE_Z14
471	bool "IBM z14 ZR1 and z14"
472	depends on $(cc-option,-mtune=z14)
473
474config TUNE_Z15
475	bool "IBM z15"
476	depends on $(cc-option,-mtune=z15)
477
478config TUNE_Z16
479	bool "IBM z16"
480	depends on $(cc-option,-mtune=z16)
481
482config TUNE_Z17
483	bool "IBM z17"
484	depends on $(cc-option,-mtune=z17)
485
486endchoice
487
488config 64BIT
489	def_bool y
490
491config COMMAND_LINE_SIZE
492	int "Maximum size of kernel command line"
493	default 4096
494	range 896 1048576
495	help
496	  This allows you to specify the maximum length of the kernel command
497	  line.
498
499config COMPAT
500	def_bool n
501	prompt "Kernel support for 31 bit emulation"
502	select ARCH_WANT_OLD_COMPAT_IPC
503	select COMPAT_OLD_SIGACTION
504	select HAVE_UID16
505	depends on MULTIUSER
506	depends on !CC_IS_CLANG && !LD_IS_LLD
507	help
508	  Select this option if you want to enable your system kernel to
509	  handle system-calls from ELF binaries for 31 bit ESA.  This option
510	  (and some other stuff like libraries and such) is needed for
511	  executing 31 bit applications.
512
513	  If unsure say N.
514
515config SMP
516	def_bool y
517
518config NR_CPUS
519	int "Maximum number of CPUs (2-512)"
520	range 2 512
521	default "64"
522	help
523	  This allows you to specify the maximum number of CPUs which this
524	  kernel will support. The maximum supported value is 512 and the
525	  minimum value which makes sense is 2.
526
527	  This is purely to save memory - each supported CPU adds
528	  approximately sixteen kilobytes to the kernel image.
529
530config HOTPLUG_CPU
531	def_bool y
532
533config NUMA
534	bool "NUMA support"
535	depends on SCHED_TOPOLOGY
536	default n
537	help
538	  Enable NUMA support
539
540	  This option adds NUMA support to the kernel.
541
542config NODES_SHIFT
543	int
544	depends on NUMA
545	default "1"
546
547config SCHED_SMT
548	def_bool n
549
550config SCHED_MC
551	def_bool n
552
553config SCHED_TOPOLOGY
554	def_bool y
555	prompt "Topology scheduler support"
556	select SCHED_SMT
557	select SCHED_MC
558	help
559	  Topology scheduler support improves the CPU scheduler's decision
560	  making when dealing with machines that have multi-threading,
561	  multiple cores or multiple books.
562
563config SCHED_TOPOLOGY_VERTICAL
564	def_bool y
565	bool "Use vertical CPU polarization by default"
566	depends on SCHED_TOPOLOGY
567	help
568	  Use vertical CPU polarization by default if available.
569	  The default CPU polarization is horizontal.
570
571config HIPERDISPATCH_ON
572	def_bool y
573	bool "Use hiperdispatch on vertical polarization by default"
574	depends on SCHED_TOPOLOGY
575	depends on PROC_SYSCTL
576	help
577	  Hiperdispatch aims to improve the CPU scheduler's decision
578	  making when using vertical polarization by adjusting CPU
579	  capacities dynamically. Set this option to use hiperdispatch
580	  on vertical polarization by default. This can be overwritten
581	  by sysctl's s390.hiperdispatch attribute later on.
582
583source "kernel/Kconfig.hz"
584
585config CERT_STORE
586	bool "Get user certificates via DIAG320"
587	depends on KEYS
588	select CRYPTO_LIB_SHA256
589	help
590	  Enable this option if you want to access user-provided secure boot
591	  certificates via DIAG 0x320.
592
593	  These certificates will be made available via the keyring named
594	  'cert_store'.
595
596config KERNEL_NOBP
597	def_bool n
598	prompt "Enable modified branch prediction for the kernel by default"
599	help
600	  If this option is selected the kernel will switch to a modified
601	  branch prediction mode if the firmware interface is available.
602	  The modified branch prediction mode improves the behaviour in
603	  regard to speculative execution.
604
605	  With the option enabled the kernel parameter "nobp=0" or "nospec"
606	  can be used to run the kernel in the normal branch prediction mode.
607
608	  With the option disabled the modified branch prediction mode is
609	  enabled with the "nobp=1" kernel parameter.
610
611	  If unsure, say N.
612
613config EXPOLINE
614	def_bool n
615	depends on $(cc-option,-mindirect-branch=thunk)
616	prompt "Avoid speculative indirect branches in the kernel"
617	help
618	  Compile the kernel with the expoline compiler options to guard
619	  against kernel-to-user data leaks by avoiding speculative indirect
620	  branches.
621	  Requires a compiler with -mindirect-branch=thunk support for full
622	  protection. The kernel may run slower.
623
624	  If unsure, say N.
625
626config EXPOLINE_EXTERN
627	def_bool EXPOLINE && CC_IS_GCC && GCC_VERSION >= 110200 && \
628		 $(success,$(srctree)/arch/s390/tools/gcc-thunk-extern.sh $(CC))
629	help
630	  Generate expolines as external functions if the compiler supports it.
631	  This option is required for some tooling like kpatch, if expolines
632	  are enabled. The kernel is compiled with
633	  -mindirect-branch=thunk-extern, which requires a newer compiler.
634
635choice
636	prompt "Expoline default"
637	depends on EXPOLINE
638	default EXPOLINE_FULL
639
640config EXPOLINE_OFF
641	bool "spectre_v2=off"
642
643config EXPOLINE_AUTO
644	bool "spectre_v2=auto"
645
646config EXPOLINE_FULL
647	bool "spectre_v2=on"
648
649endchoice
650
651config RELOCATABLE
652	def_bool y
653	select ARCH_VMLINUX_NEEDS_RELOCS
654	help
655	  This builds a kernel image that retains relocation information
656	  so it can be loaded at an arbitrary address.
657	  The relocations make the kernel image about 15% larger (compressed
658	  10%), but are discarded at runtime.
659	  Note: this option exists only for documentation purposes, please do
660	  not remove it.
661
662config RANDOMIZE_BASE
663	bool "Randomize the address of the kernel image (KASLR)"
664	default y
665	help
666	  In support of Kernel Address Space Layout Randomization (KASLR),
667	  this randomizes the address at which the kernel image is loaded,
668	  as a security feature that deters exploit attempts relying on
669	  knowledge of the location of kernel internals.
670
671config RANDOMIZE_IDENTITY_BASE
672	bool "Randomize the address of the identity mapping base"
673	depends on RANDOMIZE_BASE
674	default DEBUG_VM
675	help
676	  The identity mapping base address is pinned to zero by default.
677	  Allow randomization of that base to expose otherwise missed
678	  notion of physical and virtual addresses of data structures.
679	  That does not have any impact on the base address at which the
680	  kernel image is loaded.
681
682	  If unsure, say N
683
684config KERNEL_IMAGE_BASE
685	hex "Kernel image base address"
686	range 0x100000 0x1FFFFFE0000000 if !KASAN
687	range 0x100000 0x1BFFFFE0000000 if KASAN
688	default 0x3FFE0000000 if !KASAN
689	default 0x7FFFE0000000 if KASAN
690	help
691	  This is the address at which the kernel image is loaded in case
692	  Kernel Address Space Layout Randomization (KASLR) is disabled.
693
694	  In case the Protected virtualization guest support is enabled the
695	  Ultravisor imposes a virtual address limit. If the value of this
696	  option leads to the kernel image exceeding the Ultravisor limit,
697	  this option is ignored and the image is loaded below the limit.
698
699	  If the value of this option leads to the kernel image overlapping
700	  the virtual memory where other data structures are located, this
701	  option is ignored and the image is loaded above the structures.
702
703endmenu
704
705menu "Memory setup"
706
707config ARCH_SPARSEMEM_ENABLE
708	def_bool y
709	select SPARSEMEM_VMEMMAP_ENABLE
710	select SPARSEMEM_VMEMMAP
711
712config ARCH_SPARSEMEM_DEFAULT
713	def_bool y
714
715config MAX_PHYSMEM_BITS
716	int "Maximum size of supported physical memory in bits (42-53)"
717	range 42 53
718	default "46"
719	help
720	  This option specifies the maximum supported size of physical memory
721	  in bits. Supported is any size between 2^42 (4TB) and 2^53 (8PB).
722	  Increasing the number of bits also increases the kernel image size.
723	  By default 46 bits (64TB) are supported.
724
725endmenu
726
727menu "I/O subsystem"
728
729config QDIO
730	def_tristate y
731	prompt "QDIO support"
732	help
733	  This driver provides the Queued Direct I/O base support for
734	  IBM System z.
735
736	  To compile this driver as a module, choose M here: the
737	  module will be called qdio.
738
739	  If unsure, say Y.
740
741if PCI
742
743config PCI_NR_FUNCTIONS
744	int "Maximum number of PCI functions (1-4096)"
745	range 1 4096
746	default "512"
747	help
748	  This allows you to specify the maximum number of PCI functions which
749	  this kernel will support.
750
751endif # PCI
752
753config HAS_IOMEM
754	def_bool PCI
755
756config CHSC_SCH
757	def_tristate m
758	prompt "Support for CHSC subchannels"
759	help
760	  This driver allows usage of CHSC subchannels. A CHSC subchannel
761	  is usually present on LPAR only.
762	  The driver creates a device /dev/chsc, which may be used to
763	  obtain I/O configuration information about the machine and
764	  to issue asynchronous chsc commands (DANGEROUS).
765	  You will usually only want to use this interface on a special
766	  LPAR designated for system management.
767
768	  To compile this driver as a module, choose M here: the
769	  module will be called chsc_sch.
770
771	  If unsure, say N.
772
773config SCM_BUS
774	def_bool y
775	prompt "SCM bus driver"
776	help
777	  Bus driver for Storage Class Memory.
778
779config EADM_SCH
780	def_tristate m
781	prompt "Support for EADM subchannels"
782	depends on SCM_BUS
783	help
784	  This driver allows usage of EADM subchannels. EADM subchannels act
785	  as a communication vehicle for SCM increments.
786
787	  To compile this driver as a module, choose M here: the
788	  module will be called eadm_sch.
789
790config AP
791	def_tristate y
792	prompt "Support for Adjunct Processors (ap)"
793	help
794	  This driver allows usage to Adjunct Processor (AP) devices via
795	  the ap bus, cards and queues. Supported Adjunct Processors are
796	  the CryptoExpress Cards (CEX).
797
798	  To compile this driver as a module, choose M here: the
799	  module will be called ap.
800
801	  If unsure, say Y (default).
802
803config AP_DEBUG
804	def_bool n
805	prompt "Enable debug features for Adjunct Processor (ap) devices"
806	depends on AP
807	help
808	  Say 'Y' here to enable some additional debug features for Adjunct
809	  Processor (ap) devices.
810
811	  There will be some more sysfs attributes displayed for ap queues.
812
813	  Do not enable on production level kernel build.
814
815	  If unsure, say N.
816
817config VFIO_CCW
818	def_tristate n
819	prompt "Support for VFIO-CCW subchannels"
820	depends on VFIO
821	select VFIO_MDEV
822	help
823	  This driver allows usage of I/O subchannels via VFIO-CCW.
824
825	  To compile this driver as a module, choose M here: the
826	  module will be called vfio_ccw.
827
828config VFIO_AP
829	def_tristate n
830	prompt "VFIO support for AP devices"
831	depends on KVM
832	depends on VFIO
833	depends on AP
834	select VFIO_MDEV
835	help
836	  This driver grants access to Adjunct Processor (AP) devices
837	  via the VFIO mediated device interface.
838
839	  To compile this driver as a module, choose M here: the module
840	  will be called vfio_ap.
841
842endmenu
843
844config CCW
845	def_bool y
846
847config HAVE_PNETID
848	tristate
849	default (SMC || CCWGROUP)
850
851menu "Virtualization"
852
853config PFAULT
854	def_bool y
855	prompt "Pseudo page fault support"
856	help
857	  Select this option, if you want to use PFAULT pseudo page fault
858	  handling under VM. If running native or in LPAR, this option
859	  has no effect. If your VM does not support PFAULT, PAGEEX
860	  pseudo page fault handling will be used.
861	  Note that VM 4.2 supports PFAULT but has a bug in its
862	  implementation that causes some problems.
863	  Everybody who wants to run Linux under VM != VM4.2 should select
864	  this option.
865
866config CMM
867	def_tristate n
868	prompt "Cooperative memory management"
869	help
870	  Select this option, if you want to enable the kernel interface
871	  to reduce the memory size of the system. This is accomplished
872	  by allocating pages of memory and put them "on hold". This only
873	  makes sense for a system running under VM where the unused pages
874	  will be reused by VM for other guest systems. The interface
875	  allows an external monitor to balance memory of many systems.
876	  Everybody who wants to run Linux under VM should select this
877	  option.
878
879config CMM_IUCV
880	def_bool y
881	prompt "IUCV special message interface to cooperative memory management"
882	depends on CMM && (SMSGIUCV=y || CMM=SMSGIUCV)
883	help
884	  Select this option to enable the special message interface to
885	  the cooperative memory management.
886
887config APPLDATA_BASE
888	def_bool n
889	prompt "Linux - VM Monitor Stream, base infrastructure"
890	depends on PROC_SYSCTL
891	help
892	  This provides a kernel interface for creating and updating z/VM APPLDATA
893	  monitor records. The monitor records are updated at certain time
894	  intervals, once the timer is started.
895	  Writing 1 or 0 to /proc/appldata/timer starts(1) or stops(0) the timer,
896	  i.e. enables or disables monitoring on the Linux side.
897	  A custom interval value (in seconds) can be written to
898	  /proc/appldata/interval.
899
900	  Defaults are 60 seconds interval and timer off.
901	  The /proc entries can also be read from, showing the current settings.
902
903config APPLDATA_MEM
904	def_tristate m
905	prompt "Monitor memory management statistics"
906	depends on APPLDATA_BASE && VM_EVENT_COUNTERS
907	help
908	  This provides memory management related data to the Linux - VM Monitor
909	  Stream, like paging/swapping rate, memory utilisation, etc.
910	  Writing 1 or 0 to /proc/appldata/memory creates(1) or removes(0) a z/VM
911	  APPLDATA monitor record, i.e. enables or disables monitoring this record
912	  on the z/VM side.
913
914	  Default is disabled.
915	  The /proc entry can also be read from, showing the current settings.
916
917	  This can also be compiled as a module, which will be called
918	  appldata_mem.o.
919
920config APPLDATA_OS
921	def_tristate m
922	prompt "Monitor OS statistics"
923	depends on APPLDATA_BASE
924	help
925	  This provides OS related data to the Linux - VM Monitor Stream, like
926	  CPU utilisation, etc.
927	  Writing 1 or 0 to /proc/appldata/os creates(1) or removes(0) a z/VM
928	  APPLDATA monitor record, i.e. enables or disables monitoring this record
929	  on the z/VM side.
930
931	  Default is disabled.
932	  This can also be compiled as a module, which will be called
933	  appldata_os.o.
934
935config APPLDATA_NET_SUM
936	def_tristate m
937	prompt "Monitor overall network statistics"
938	depends on APPLDATA_BASE && NET
939	help
940	  This provides network related data to the Linux - VM Monitor Stream,
941	  currently there is only a total sum of network I/O statistics, no
942	  per-interface data.
943	  Writing 1 or 0 to /proc/appldata/net_sum creates(1) or removes(0) a z/VM
944	  APPLDATA monitor record, i.e. enables or disables monitoring this record
945	  on the z/VM side.
946
947	  Default is disabled.
948	  This can also be compiled as a module, which will be called
949	  appldata_net_sum.o.
950
951config S390_HYPFS
952	def_bool y
953	prompt "s390 hypervisor information"
954	help
955	  This provides several binary files at (debugfs)/s390_hypfs/ to
956	  provide accounting information in an s390 hypervisor environment.
957
958config S390_HYPFS_FS
959	def_bool n
960	prompt "s390 hypervisor file system support"
961	select SYS_HYPERVISOR
962	depends on S390_HYPFS
963	help
964	  This is a virtual file system intended to provide accounting
965	  information in an s390 hypervisor environment. This file system
966	  is deprecated and should not be used.
967
968	  Say N if you are unsure.
969
970source "arch/s390/kvm/Kconfig"
971
972config S390_GUEST
973	def_bool y
974	prompt "s390 support for virtio devices"
975	select TTY
976	select VIRTUALIZATION
977	select VIRTIO
978	help
979	  Enabling this option adds support for virtio based paravirtual device
980	  drivers on s390.
981
982	  Select this option if you want to run the kernel as a guest under
983	  the KVM hypervisor.
984
985endmenu
986
987config S390_MODULES_SANITY_TEST_HELPERS
988	def_bool n
989
990menu "Selftests"
991
992config S390_UNWIND_SELFTEST
993	def_tristate n
994	depends on KUNIT
995	default KUNIT_ALL_TESTS
996	prompt "Test unwind functions"
997	help
998	  This option enables s390 specific stack unwinder testing kernel
999	  module. This option is not useful for distributions or general
1000	  kernels, but only for kernel developers working on architecture code.
1001
1002	  Say N if you are unsure.
1003
1004config S390_KPROBES_SANITY_TEST
1005	def_tristate n
1006	prompt "Enable s390 specific kprobes tests"
1007	depends on KPROBES
1008	depends on KUNIT
1009	help
1010	  This option enables an s390 specific kprobes test module. This option
1011	  is not useful for distributions or general kernels, but only for kernel
1012	  developers working on architecture code.
1013
1014	  Say N if you are unsure.
1015
1016config S390_MODULES_SANITY_TEST
1017	def_tristate n
1018	depends on KUNIT
1019	default KUNIT_ALL_TESTS
1020	prompt "Enable s390 specific modules tests"
1021	select S390_MODULES_SANITY_TEST_HELPERS
1022	help
1023	  This option enables an s390 specific modules test. This option is
1024	  not useful for distributions or general kernels, but only for
1025	  kernel developers working on architecture code.
1026
1027	  Say N if you are unsure.
1028endmenu
1029