162306a36Sopenharmony_ci# SPDX-License-Identifier: GPL-2.0 262306a36Sopenharmony_ci 362306a36Sopenharmony_cimenu "UML-specific options" 462306a36Sopenharmony_ci 562306a36Sopenharmony_ciconfig UML 662306a36Sopenharmony_ci bool 762306a36Sopenharmony_ci default y 862306a36Sopenharmony_ci select ARCH_HAS_CPU_FINALIZE_INIT 962306a36Sopenharmony_ci select ARCH_HAS_FORTIFY_SOURCE 1062306a36Sopenharmony_ci select ARCH_HAS_GCOV_PROFILE_ALL 1162306a36Sopenharmony_ci select ARCH_HAS_KCOV 1262306a36Sopenharmony_ci select ARCH_HAS_STRNCPY_FROM_USER 1362306a36Sopenharmony_ci select ARCH_HAS_STRNLEN_USER 1462306a36Sopenharmony_ci select ARCH_NO_PREEMPT 1562306a36Sopenharmony_ci select HAVE_ARCH_AUDITSYSCALL 1662306a36Sopenharmony_ci select HAVE_ARCH_KASAN if X86_64 1762306a36Sopenharmony_ci select HAVE_ARCH_KASAN_VMALLOC if HAVE_ARCH_KASAN 1862306a36Sopenharmony_ci select HAVE_ARCH_SECCOMP_FILTER 1962306a36Sopenharmony_ci select HAVE_ASM_MODVERSIONS 2062306a36Sopenharmony_ci select HAVE_UID16 2162306a36Sopenharmony_ci select HAVE_DEBUG_KMEMLEAK 2262306a36Sopenharmony_ci select HAVE_DEBUG_BUGVERBOSE 2362306a36Sopenharmony_ci select NO_DMA if !UML_DMA_EMULATION 2462306a36Sopenharmony_ci select OF_EARLY_FLATTREE if OF 2562306a36Sopenharmony_ci select GENERIC_IRQ_SHOW 2662306a36Sopenharmony_ci select GENERIC_CPU_DEVICES 2762306a36Sopenharmony_ci select HAVE_GCC_PLUGINS 2862306a36Sopenharmony_ci select ARCH_SUPPORTS_LTO_CLANG 2962306a36Sopenharmony_ci select ARCH_SUPPORTS_LTO_CLANG_THIN 3062306a36Sopenharmony_ci select TRACE_IRQFLAGS_SUPPORT 3162306a36Sopenharmony_ci select TTY # Needed for line.c 3262306a36Sopenharmony_ci select HAVE_ARCH_VMAP_STACK 3362306a36Sopenharmony_ci select HAVE_RUST if X86_64 3462306a36Sopenharmony_ci 3562306a36Sopenharmony_ciconfig MMU 3662306a36Sopenharmony_ci bool 3762306a36Sopenharmony_ci default y 3862306a36Sopenharmony_ci 3962306a36Sopenharmony_ciconfig UML_DMA_EMULATION 4062306a36Sopenharmony_ci bool 4162306a36Sopenharmony_ci 4262306a36Sopenharmony_ciconfig NO_IOMEM 4362306a36Sopenharmony_ci bool "disable IOMEM" if EXPERT 4462306a36Sopenharmony_ci depends on !INDIRECT_IOMEM 4562306a36Sopenharmony_ci default y 4662306a36Sopenharmony_ci 4762306a36Sopenharmony_ciconfig UML_IOMEM_EMULATION 4862306a36Sopenharmony_ci bool 4962306a36Sopenharmony_ci select INDIRECT_IOMEM 5062306a36Sopenharmony_ci select GENERIC_PCI_IOMAP 5162306a36Sopenharmony_ci select GENERIC_IOMAP 5262306a36Sopenharmony_ci select NO_GENERIC_PCI_IOPORT_MAP 5362306a36Sopenharmony_ci 5462306a36Sopenharmony_ciconfig NO_IOPORT_MAP 5562306a36Sopenharmony_ci def_bool y 5662306a36Sopenharmony_ci 5762306a36Sopenharmony_ciconfig ISA 5862306a36Sopenharmony_ci bool 5962306a36Sopenharmony_ci 6062306a36Sopenharmony_ciconfig SBUS 6162306a36Sopenharmony_ci bool 6262306a36Sopenharmony_ci 6362306a36Sopenharmony_ciconfig LOCKDEP_SUPPORT 6462306a36Sopenharmony_ci bool 6562306a36Sopenharmony_ci default y 6662306a36Sopenharmony_ci 6762306a36Sopenharmony_ciconfig STACKTRACE_SUPPORT 6862306a36Sopenharmony_ci bool 6962306a36Sopenharmony_ci default y 7062306a36Sopenharmony_ci select STACKTRACE 7162306a36Sopenharmony_ci 7262306a36Sopenharmony_ciconfig GENERIC_CALIBRATE_DELAY 7362306a36Sopenharmony_ci bool 7462306a36Sopenharmony_ci default y 7562306a36Sopenharmony_ci 7662306a36Sopenharmony_ciconfig HZ 7762306a36Sopenharmony_ci int 7862306a36Sopenharmony_ci default 100 7962306a36Sopenharmony_ci 8062306a36Sopenharmony_ciconfig NR_CPUS 8162306a36Sopenharmony_ci int 8262306a36Sopenharmony_ci range 1 1 8362306a36Sopenharmony_ci default 1 8462306a36Sopenharmony_ci 8562306a36Sopenharmony_ciconfig ARCH_HAS_CACHE_LINE_SIZE 8662306a36Sopenharmony_ci def_bool y 8762306a36Sopenharmony_ci 8862306a36Sopenharmony_cisource "arch/$(HEADER_ARCH)/um/Kconfig" 8962306a36Sopenharmony_ci 9062306a36Sopenharmony_ciconfig MAY_HAVE_RUNTIME_DEPS 9162306a36Sopenharmony_ci bool 9262306a36Sopenharmony_ci 9362306a36Sopenharmony_ciconfig STATIC_LINK 9462306a36Sopenharmony_ci bool "Force a static link" 9562306a36Sopenharmony_ci depends on CC_CAN_LINK_STATIC_NO_RUNTIME_DEPS || !MAY_HAVE_RUNTIME_DEPS 9662306a36Sopenharmony_ci help 9762306a36Sopenharmony_ci This option gives you the ability to force a static link of UML. 9862306a36Sopenharmony_ci Normally, UML is linked as a shared binary. This is inconvenient for 9962306a36Sopenharmony_ci use in a chroot jail. So, if you intend to run UML inside a chroot, 10062306a36Sopenharmony_ci you probably want to say Y here. 10162306a36Sopenharmony_ci Additionally, this option enables using higher memory spaces (up to 10262306a36Sopenharmony_ci 2.75G) for UML. 10362306a36Sopenharmony_ci 10462306a36Sopenharmony_ci NOTE: This option is incompatible with some networking features which 10562306a36Sopenharmony_ci depend on features that require being dynamically loaded (like NSS). 10662306a36Sopenharmony_ci 10762306a36Sopenharmony_ciconfig LD_SCRIPT_STATIC 10862306a36Sopenharmony_ci bool 10962306a36Sopenharmony_ci default y 11062306a36Sopenharmony_ci depends on STATIC_LINK 11162306a36Sopenharmony_ci 11262306a36Sopenharmony_ciconfig LD_SCRIPT_DYN 11362306a36Sopenharmony_ci bool 11462306a36Sopenharmony_ci default y 11562306a36Sopenharmony_ci depends on !LD_SCRIPT_STATIC 11662306a36Sopenharmony_ci 11762306a36Sopenharmony_ciconfig LD_SCRIPT_DYN_RPATH 11862306a36Sopenharmony_ci bool "set rpath in the binary" if EXPERT 11962306a36Sopenharmony_ci default y 12062306a36Sopenharmony_ci depends on LD_SCRIPT_DYN 12162306a36Sopenharmony_ci help 12262306a36Sopenharmony_ci Add /lib (and /lib64 for 64-bit) to the linux binary's rpath 12362306a36Sopenharmony_ci explicitly. 12462306a36Sopenharmony_ci 12562306a36Sopenharmony_ci You may need to turn this off if compiling for nix systems 12662306a36Sopenharmony_ci that have their libraries in random /nix directories and 12762306a36Sopenharmony_ci might otherwise unexpected use libraries from /lib or /lib64 12862306a36Sopenharmony_ci instead of the desired ones. 12962306a36Sopenharmony_ci 13062306a36Sopenharmony_ciconfig HOSTFS 13162306a36Sopenharmony_ci tristate "Host filesystem" 13262306a36Sopenharmony_ci help 13362306a36Sopenharmony_ci While the User-Mode Linux port uses its own root file system for 13462306a36Sopenharmony_ci booting and normal file access, this module lets the UML user 13562306a36Sopenharmony_ci access files stored on the host. It does not require any 13662306a36Sopenharmony_ci network connection between the Host and UML. An example use of 13762306a36Sopenharmony_ci this might be: 13862306a36Sopenharmony_ci 13962306a36Sopenharmony_ci mount none /tmp/fromhost -t hostfs -o /tmp/umlshare 14062306a36Sopenharmony_ci 14162306a36Sopenharmony_ci where /tmp/fromhost is an empty directory inside UML and 14262306a36Sopenharmony_ci /tmp/umlshare is a directory on the host with files the UML user 14362306a36Sopenharmony_ci wishes to access. 14462306a36Sopenharmony_ci 14562306a36Sopenharmony_ci For more information, see 14662306a36Sopenharmony_ci <http://user-mode-linux.sourceforge.net/hostfs.html>. 14762306a36Sopenharmony_ci 14862306a36Sopenharmony_ci If you'd like to be able to work with files stored on the host, 14962306a36Sopenharmony_ci say Y or M here; otherwise say N. 15062306a36Sopenharmony_ci 15162306a36Sopenharmony_ciconfig MCONSOLE 15262306a36Sopenharmony_ci bool "Management console" 15362306a36Sopenharmony_ci depends on PROC_FS 15462306a36Sopenharmony_ci default y 15562306a36Sopenharmony_ci help 15662306a36Sopenharmony_ci The user mode linux management console is a low-level interface to 15762306a36Sopenharmony_ci the kernel, somewhat like the i386 SysRq interface. Since there is 15862306a36Sopenharmony_ci a full-blown operating system running under every user mode linux 15962306a36Sopenharmony_ci instance, there is much greater flexibility possible than with the 16062306a36Sopenharmony_ci SysRq mechanism. 16162306a36Sopenharmony_ci 16262306a36Sopenharmony_ci If you answer 'Y' to this option, to use this feature, you need the 16362306a36Sopenharmony_ci mconsole client (called uml_mconsole) which is present in CVS in 16462306a36Sopenharmony_ci 2.4.5-9um and later (path /tools/mconsole), and is also in the 16562306a36Sopenharmony_ci distribution RPM package in 2.4.6 and later. 16662306a36Sopenharmony_ci 16762306a36Sopenharmony_ci It is safe to say 'Y' here. 16862306a36Sopenharmony_ci 16962306a36Sopenharmony_ciconfig MAGIC_SYSRQ 17062306a36Sopenharmony_ci bool "Magic SysRq key" 17162306a36Sopenharmony_ci depends on MCONSOLE 17262306a36Sopenharmony_ci help 17362306a36Sopenharmony_ci If you say Y here, you will have some control over the system even 17462306a36Sopenharmony_ci if the system crashes for example during kernel debugging (e.g., you 17562306a36Sopenharmony_ci will be able to flush the buffer cache to disk, reboot the system 17662306a36Sopenharmony_ci immediately or dump some status information). A key for each of the 17762306a36Sopenharmony_ci possible requests is provided. 17862306a36Sopenharmony_ci 17962306a36Sopenharmony_ci This is the feature normally accomplished by pressing a key 18062306a36Sopenharmony_ci while holding SysRq (Alt+PrintScreen). 18162306a36Sopenharmony_ci 18262306a36Sopenharmony_ci On UML, this is accomplished by sending a "sysrq" command with 18362306a36Sopenharmony_ci mconsole, followed by the letter for the requested command. 18462306a36Sopenharmony_ci 18562306a36Sopenharmony_ci The keys are documented in <file:Documentation/admin-guide/sysrq.rst>. Don't say Y 18662306a36Sopenharmony_ci unless you really know what this hack does. 18762306a36Sopenharmony_ci 18862306a36Sopenharmony_ciconfig KERNEL_STACK_ORDER 18962306a36Sopenharmony_ci int "Kernel stack size order" 19062306a36Sopenharmony_ci default 2 if 64BIT 19162306a36Sopenharmony_ci range 2 10 if 64BIT 19262306a36Sopenharmony_ci default 1 if !64BIT 19362306a36Sopenharmony_ci help 19462306a36Sopenharmony_ci This option determines the size of UML kernel stacks. They will 19562306a36Sopenharmony_ci be 1 << order pages. The default is OK unless you're running Valgrind 19662306a36Sopenharmony_ci on UML, in which case, set this to 3. 19762306a36Sopenharmony_ci It is possible to reduce the stack to 1 for 64BIT and 0 for 32BIT on 19862306a36Sopenharmony_ci older (pre-2017) CPUs. It is not recommended on newer CPUs due to the 19962306a36Sopenharmony_ci increase in the size of the state which needs to be saved when handling 20062306a36Sopenharmony_ci signals. 20162306a36Sopenharmony_ci 20262306a36Sopenharmony_ciconfig MMAPPER 20362306a36Sopenharmony_ci tristate "iomem emulation driver" 20462306a36Sopenharmony_ci help 20562306a36Sopenharmony_ci This driver allows a host file to be used as emulated IO memory inside 20662306a36Sopenharmony_ci UML. 20762306a36Sopenharmony_ci 20862306a36Sopenharmony_ciconfig PGTABLE_LEVELS 20962306a36Sopenharmony_ci int 21062306a36Sopenharmony_ci default 3 if 3_LEVEL_PGTABLES 21162306a36Sopenharmony_ci default 2 21262306a36Sopenharmony_ci 21362306a36Sopenharmony_ciconfig UML_TIME_TRAVEL_SUPPORT 21462306a36Sopenharmony_ci bool 21562306a36Sopenharmony_ci prompt "Support time-travel mode (e.g. for test execution)" 21662306a36Sopenharmony_ci # inf-cpu mode is incompatible with the benchmarking 21762306a36Sopenharmony_ci depends on !RAID6_PQ_BENCHMARK 21862306a36Sopenharmony_ci depends on !SMP 21962306a36Sopenharmony_ci help 22062306a36Sopenharmony_ci Enable this option to support time travel inside the UML instance. 22162306a36Sopenharmony_ci 22262306a36Sopenharmony_ci After enabling this option, two modes are accessible at runtime 22362306a36Sopenharmony_ci (selected by the kernel command line), see the kernel's command- 22462306a36Sopenharmony_ci line help for more details. 22562306a36Sopenharmony_ci 22662306a36Sopenharmony_ci It is safe to say Y, but you probably don't need this. 22762306a36Sopenharmony_ci 22862306a36Sopenharmony_ciconfig KASAN_SHADOW_OFFSET 22962306a36Sopenharmony_ci hex 23062306a36Sopenharmony_ci depends on KASAN 23162306a36Sopenharmony_ci default 0x100000000000 23262306a36Sopenharmony_ci help 23362306a36Sopenharmony_ci This is the offset at which the ~16TB of shadow memory is 23462306a36Sopenharmony_ci mapped and used by KASAN for memory debugging. This can be any 23562306a36Sopenharmony_ci address that has at least KASAN_SHADOW_SIZE (total address space divided 23662306a36Sopenharmony_ci by 8) amount of space so that the KASAN shadow memory does not conflict 23762306a36Sopenharmony_ci with anything. The default is 0x100000000000, which works even if mem is 23862306a36Sopenharmony_ci set to a large value. On low-memory systems, try 0x7fff8000, as it fits 23962306a36Sopenharmony_ci into the immediate of most instructions, improving performance. 24062306a36Sopenharmony_ci 24162306a36Sopenharmony_ciendmenu 24262306a36Sopenharmony_ci 24362306a36Sopenharmony_cisource "arch/um/drivers/Kconfig" 24462306a36Sopenharmony_ci 24562306a36Sopenharmony_ciconfig ARCH_SUSPEND_POSSIBLE 24662306a36Sopenharmony_ci def_bool y 24762306a36Sopenharmony_ci 24862306a36Sopenharmony_cimenu "Power management options" 24962306a36Sopenharmony_ci 25062306a36Sopenharmony_cisource "kernel/power/Kconfig" 25162306a36Sopenharmony_ci 25262306a36Sopenharmony_ciendmenu 253