1*4882a593Smuzhiyun# SPDX-License-Identifier: GPL-2.0 2*4882a593Smuzhiyun 3*4882a593Smuzhiyunconfig TRACE_IRQFLAGS_SUPPORT 4*4882a593Smuzhiyun def_bool y 5*4882a593Smuzhiyun 6*4882a593Smuzhiyunconfig TRACE_IRQFLAGS_NMI_SUPPORT 7*4882a593Smuzhiyun def_bool y 8*4882a593Smuzhiyun 9*4882a593Smuzhiyunconfig EARLY_PRINTK_USB 10*4882a593Smuzhiyun bool 11*4882a593Smuzhiyun 12*4882a593Smuzhiyunconfig X86_VERBOSE_BOOTUP 13*4882a593Smuzhiyun bool "Enable verbose x86 bootup info messages" 14*4882a593Smuzhiyun default y 15*4882a593Smuzhiyun help 16*4882a593Smuzhiyun Enables the informational output from the decompression stage 17*4882a593Smuzhiyun (e.g. bzImage) of the boot. If you disable this you will still 18*4882a593Smuzhiyun see errors. Disable this if you want silent bootup. 19*4882a593Smuzhiyun 20*4882a593Smuzhiyunconfig EARLY_PRINTK 21*4882a593Smuzhiyun bool "Early printk" if EXPERT 22*4882a593Smuzhiyun default y 23*4882a593Smuzhiyun help 24*4882a593Smuzhiyun Write kernel log output directly into the VGA buffer or to a serial 25*4882a593Smuzhiyun port. 26*4882a593Smuzhiyun 27*4882a593Smuzhiyun This is useful for kernel debugging when your machine crashes very 28*4882a593Smuzhiyun early before the console code is initialized. For normal operation 29*4882a593Smuzhiyun it is not recommended because it looks ugly and doesn't cooperate 30*4882a593Smuzhiyun with klogd/syslogd or the X server. You should normally say N here, 31*4882a593Smuzhiyun unless you want to debug such a crash. 32*4882a593Smuzhiyun 33*4882a593Smuzhiyunconfig EARLY_PRINTK_DBGP 34*4882a593Smuzhiyun bool "Early printk via EHCI debug port" 35*4882a593Smuzhiyun depends on EARLY_PRINTK && PCI 36*4882a593Smuzhiyun select EARLY_PRINTK_USB 37*4882a593Smuzhiyun help 38*4882a593Smuzhiyun Write kernel log output directly into the EHCI debug port. 39*4882a593Smuzhiyun 40*4882a593Smuzhiyun This is useful for kernel debugging when your machine crashes very 41*4882a593Smuzhiyun early before the console code is initialized. For normal operation 42*4882a593Smuzhiyun it is not recommended because it looks ugly and doesn't cooperate 43*4882a593Smuzhiyun with klogd/syslogd or the X server. You should normally say N here, 44*4882a593Smuzhiyun unless you want to debug such a crash. You need usb debug device. 45*4882a593Smuzhiyun 46*4882a593Smuzhiyunconfig EARLY_PRINTK_USB_XDBC 47*4882a593Smuzhiyun bool "Early printk via the xHCI debug port" 48*4882a593Smuzhiyun depends on EARLY_PRINTK && PCI 49*4882a593Smuzhiyun select EARLY_PRINTK_USB 50*4882a593Smuzhiyun help 51*4882a593Smuzhiyun Write kernel log output directly into the xHCI debug port. 52*4882a593Smuzhiyun 53*4882a593Smuzhiyun One use for this feature is kernel debugging, for example when your 54*4882a593Smuzhiyun machine crashes very early before the regular console code is 55*4882a593Smuzhiyun initialized. Other uses include simpler, lockless logging instead of 56*4882a593Smuzhiyun a full-blown printk console driver + klogd. 57*4882a593Smuzhiyun 58*4882a593Smuzhiyun For normal production environments this is normally not recommended, 59*4882a593Smuzhiyun because it doesn't feed events into klogd/syslogd and doesn't try to 60*4882a593Smuzhiyun print anything on the screen. 61*4882a593Smuzhiyun 62*4882a593Smuzhiyun You should normally say N here, unless you want to debug early 63*4882a593Smuzhiyun crashes or need a very simple printk logging facility. 64*4882a593Smuzhiyun 65*4882a593Smuzhiyunconfig COPY_MC_TEST 66*4882a593Smuzhiyun def_bool n 67*4882a593Smuzhiyun 68*4882a593Smuzhiyunconfig EFI_PGT_DUMP 69*4882a593Smuzhiyun bool "Dump the EFI pagetable" 70*4882a593Smuzhiyun depends on EFI 71*4882a593Smuzhiyun select PTDUMP_CORE 72*4882a593Smuzhiyun help 73*4882a593Smuzhiyun Enable this if you want to dump the EFI page table before 74*4882a593Smuzhiyun enabling virtual mode. This can be used to debug miscellaneous 75*4882a593Smuzhiyun issues with the mapping of the EFI runtime regions into that 76*4882a593Smuzhiyun table. 77*4882a593Smuzhiyun 78*4882a593Smuzhiyunconfig DEBUG_TLBFLUSH 79*4882a593Smuzhiyun bool "Set upper limit of TLB entries to flush one-by-one" 80*4882a593Smuzhiyun depends on DEBUG_KERNEL 81*4882a593Smuzhiyun help 82*4882a593Smuzhiyun 83*4882a593Smuzhiyun X86-only for now. 84*4882a593Smuzhiyun 85*4882a593Smuzhiyun This option allows the user to tune the amount of TLB entries the 86*4882a593Smuzhiyun kernel flushes one-by-one instead of doing a full TLB flush. In 87*4882a593Smuzhiyun certain situations, the former is cheaper. This is controlled by the 88*4882a593Smuzhiyun tlb_flushall_shift knob under /sys/kernel/debug/x86. If you set it 89*4882a593Smuzhiyun to -1, the code flushes the whole TLB unconditionally. Otherwise, 90*4882a593Smuzhiyun for positive values of it, the kernel will use single TLB entry 91*4882a593Smuzhiyun invalidating instructions according to the following formula: 92*4882a593Smuzhiyun 93*4882a593Smuzhiyun flush_entries <= active_tlb_entries / 2^tlb_flushall_shift 94*4882a593Smuzhiyun 95*4882a593Smuzhiyun If in doubt, say "N". 96*4882a593Smuzhiyun 97*4882a593Smuzhiyunconfig IOMMU_DEBUG 98*4882a593Smuzhiyun bool "Enable IOMMU debugging" 99*4882a593Smuzhiyun depends on GART_IOMMU && DEBUG_KERNEL 100*4882a593Smuzhiyun depends on X86_64 101*4882a593Smuzhiyun help 102*4882a593Smuzhiyun Force the IOMMU to on even when you have less than 4GB of 103*4882a593Smuzhiyun memory and add debugging code. On overflow always panic. And 104*4882a593Smuzhiyun allow to enable IOMMU leak tracing. Can be disabled at boot 105*4882a593Smuzhiyun time with iommu=noforce. This will also enable scatter gather 106*4882a593Smuzhiyun list merging. Currently not recommended for production 107*4882a593Smuzhiyun code. When you use it make sure you have a big enough 108*4882a593Smuzhiyun IOMMU/AGP aperture. Most of the options enabled by this can 109*4882a593Smuzhiyun be set more finegrained using the iommu= command line 110*4882a593Smuzhiyun options. See Documentation/x86/x86_64/boot-options.rst for more 111*4882a593Smuzhiyun details. 112*4882a593Smuzhiyun 113*4882a593Smuzhiyunconfig IOMMU_LEAK 114*4882a593Smuzhiyun bool "IOMMU leak tracing" 115*4882a593Smuzhiyun depends on IOMMU_DEBUG && DMA_API_DEBUG 116*4882a593Smuzhiyun help 117*4882a593Smuzhiyun Add a simple leak tracer to the IOMMU code. This is useful when you 118*4882a593Smuzhiyun are debugging a buggy device driver that leaks IOMMU mappings. 119*4882a593Smuzhiyun 120*4882a593Smuzhiyunconfig HAVE_MMIOTRACE_SUPPORT 121*4882a593Smuzhiyun def_bool y 122*4882a593Smuzhiyun 123*4882a593Smuzhiyunconfig X86_DECODER_SELFTEST 124*4882a593Smuzhiyun bool "x86 instruction decoder selftest" 125*4882a593Smuzhiyun depends on DEBUG_KERNEL && INSTRUCTION_DECODER 126*4882a593Smuzhiyun depends on !COMPILE_TEST 127*4882a593Smuzhiyun help 128*4882a593Smuzhiyun Perform x86 instruction decoder selftests at build time. 129*4882a593Smuzhiyun This option is useful for checking the sanity of x86 instruction 130*4882a593Smuzhiyun decoder code. 131*4882a593Smuzhiyun If unsure, say "N". 132*4882a593Smuzhiyun 133*4882a593Smuzhiyunchoice 134*4882a593Smuzhiyun prompt "IO delay type" 135*4882a593Smuzhiyun default IO_DELAY_0X80 136*4882a593Smuzhiyun 137*4882a593Smuzhiyunconfig IO_DELAY_0X80 138*4882a593Smuzhiyun bool "port 0x80 based port-IO delay [recommended]" 139*4882a593Smuzhiyun help 140*4882a593Smuzhiyun This is the traditional Linux IO delay used for in/out_p. 141*4882a593Smuzhiyun It is the most tested hence safest selection here. 142*4882a593Smuzhiyun 143*4882a593Smuzhiyunconfig IO_DELAY_0XED 144*4882a593Smuzhiyun bool "port 0xed based port-IO delay" 145*4882a593Smuzhiyun help 146*4882a593Smuzhiyun Use port 0xed as the IO delay. This frees up port 0x80 which is 147*4882a593Smuzhiyun often used as a hardware-debug port. 148*4882a593Smuzhiyun 149*4882a593Smuzhiyunconfig IO_DELAY_UDELAY 150*4882a593Smuzhiyun bool "udelay based port-IO delay" 151*4882a593Smuzhiyun help 152*4882a593Smuzhiyun Use udelay(2) as the IO delay method. This provides the delay 153*4882a593Smuzhiyun while not having any side-effect on the IO port space. 154*4882a593Smuzhiyun 155*4882a593Smuzhiyunconfig IO_DELAY_NONE 156*4882a593Smuzhiyun bool "no port-IO delay" 157*4882a593Smuzhiyun help 158*4882a593Smuzhiyun No port-IO delay. Will break on old boxes that require port-IO 159*4882a593Smuzhiyun delay for certain operations. Should work on most new machines. 160*4882a593Smuzhiyun 161*4882a593Smuzhiyunendchoice 162*4882a593Smuzhiyun 163*4882a593Smuzhiyunconfig DEBUG_BOOT_PARAMS 164*4882a593Smuzhiyun bool "Debug boot parameters" 165*4882a593Smuzhiyun depends on DEBUG_KERNEL 166*4882a593Smuzhiyun depends on DEBUG_FS 167*4882a593Smuzhiyun help 168*4882a593Smuzhiyun This option will cause struct boot_params to be exported via debugfs. 169*4882a593Smuzhiyun 170*4882a593Smuzhiyunconfig CPA_DEBUG 171*4882a593Smuzhiyun bool "CPA self-test code" 172*4882a593Smuzhiyun depends on DEBUG_KERNEL 173*4882a593Smuzhiyun help 174*4882a593Smuzhiyun Do change_page_attr() self-tests every 30 seconds. 175*4882a593Smuzhiyun 176*4882a593Smuzhiyunconfig DEBUG_ENTRY 177*4882a593Smuzhiyun bool "Debug low-level entry code" 178*4882a593Smuzhiyun depends on DEBUG_KERNEL 179*4882a593Smuzhiyun help 180*4882a593Smuzhiyun This option enables sanity checks in x86's low-level entry code. 181*4882a593Smuzhiyun Some of these sanity checks may slow down kernel entries and 182*4882a593Smuzhiyun exits or otherwise impact performance. 183*4882a593Smuzhiyun 184*4882a593Smuzhiyun If unsure, say N. 185*4882a593Smuzhiyun 186*4882a593Smuzhiyunconfig DEBUG_NMI_SELFTEST 187*4882a593Smuzhiyun bool "NMI Selftest" 188*4882a593Smuzhiyun depends on DEBUG_KERNEL && X86_LOCAL_APIC 189*4882a593Smuzhiyun help 190*4882a593Smuzhiyun Enabling this option turns on a quick NMI selftest to verify 191*4882a593Smuzhiyun that the NMI behaves correctly. 192*4882a593Smuzhiyun 193*4882a593Smuzhiyun This might help diagnose strange hangs that rely on NMI to 194*4882a593Smuzhiyun function properly. 195*4882a593Smuzhiyun 196*4882a593Smuzhiyun If unsure, say N. 197*4882a593Smuzhiyun 198*4882a593Smuzhiyunconfig DEBUG_IMR_SELFTEST 199*4882a593Smuzhiyun bool "Isolated Memory Region self test" 200*4882a593Smuzhiyun depends on INTEL_IMR 201*4882a593Smuzhiyun help 202*4882a593Smuzhiyun This option enables automated sanity testing of the IMR code. 203*4882a593Smuzhiyun Some simple tests are run to verify IMR bounds checking, alignment 204*4882a593Smuzhiyun and overlapping. This option is really only useful if you are 205*4882a593Smuzhiyun debugging an IMR memory map or are modifying the IMR code and want to 206*4882a593Smuzhiyun test your changes. 207*4882a593Smuzhiyun 208*4882a593Smuzhiyun If unsure say N here. 209*4882a593Smuzhiyun 210*4882a593Smuzhiyunconfig X86_DEBUG_FPU 211*4882a593Smuzhiyun bool "Debug the x86 FPU code" 212*4882a593Smuzhiyun depends on DEBUG_KERNEL 213*4882a593Smuzhiyun default y 214*4882a593Smuzhiyun help 215*4882a593Smuzhiyun If this option is enabled then there will be extra sanity 216*4882a593Smuzhiyun checks and (boot time) debug printouts added to the kernel. 217*4882a593Smuzhiyun This debugging adds some small amount of runtime overhead 218*4882a593Smuzhiyun to the kernel. 219*4882a593Smuzhiyun 220*4882a593Smuzhiyun If unsure, say N. 221*4882a593Smuzhiyun 222*4882a593Smuzhiyunconfig PUNIT_ATOM_DEBUG 223*4882a593Smuzhiyun tristate "ATOM Punit debug driver" 224*4882a593Smuzhiyun depends on PCI 225*4882a593Smuzhiyun select DEBUG_FS 226*4882a593Smuzhiyun select IOSF_MBI 227*4882a593Smuzhiyun help 228*4882a593Smuzhiyun This is a debug driver, which gets the power states 229*4882a593Smuzhiyun of all Punit North Complex devices. The power states of 230*4882a593Smuzhiyun each device is exposed as part of the debugfs interface. 231*4882a593Smuzhiyun The current power state can be read from 232*4882a593Smuzhiyun /sys/kernel/debug/punit_atom/dev_power_state 233*4882a593Smuzhiyun 234*4882a593Smuzhiyunchoice 235*4882a593Smuzhiyun prompt "Choose kernel unwinder" 236*4882a593Smuzhiyun default UNWINDER_ORC if X86_64 237*4882a593Smuzhiyun default UNWINDER_FRAME_POINTER if X86_32 238*4882a593Smuzhiyun help 239*4882a593Smuzhiyun This determines which method will be used for unwinding kernel stack 240*4882a593Smuzhiyun traces for panics, oopses, bugs, warnings, perf, /proc/<pid>/stack, 241*4882a593Smuzhiyun livepatch, lockdep, and more. 242*4882a593Smuzhiyun 243*4882a593Smuzhiyunconfig UNWINDER_ORC 244*4882a593Smuzhiyun bool "ORC unwinder" 245*4882a593Smuzhiyun depends on X86_64 246*4882a593Smuzhiyun select STACK_VALIDATION 247*4882a593Smuzhiyun help 248*4882a593Smuzhiyun This option enables the ORC (Oops Rewind Capability) unwinder for 249*4882a593Smuzhiyun unwinding kernel stack traces. It uses a custom data format which is 250*4882a593Smuzhiyun a simplified version of the DWARF Call Frame Information standard. 251*4882a593Smuzhiyun 252*4882a593Smuzhiyun This unwinder is more accurate across interrupt entry frames than the 253*4882a593Smuzhiyun frame pointer unwinder. It also enables a 5-10% performance 254*4882a593Smuzhiyun improvement across the entire kernel compared to frame pointers. 255*4882a593Smuzhiyun 256*4882a593Smuzhiyun Enabling this option will increase the kernel's runtime memory usage 257*4882a593Smuzhiyun by roughly 2-4MB, depending on your kernel config. 258*4882a593Smuzhiyun 259*4882a593Smuzhiyunconfig UNWINDER_FRAME_POINTER 260*4882a593Smuzhiyun bool "Frame pointer unwinder" 261*4882a593Smuzhiyun select FRAME_POINTER 262*4882a593Smuzhiyun help 263*4882a593Smuzhiyun This option enables the frame pointer unwinder for unwinding kernel 264*4882a593Smuzhiyun stack traces. 265*4882a593Smuzhiyun 266*4882a593Smuzhiyun The unwinder itself is fast and it uses less RAM than the ORC 267*4882a593Smuzhiyun unwinder, but the kernel text size will grow by ~3% and the kernel's 268*4882a593Smuzhiyun overall performance will degrade by roughly 5-10%. 269*4882a593Smuzhiyun 270*4882a593Smuzhiyunconfig UNWINDER_GUESS 271*4882a593Smuzhiyun bool "Guess unwinder" 272*4882a593Smuzhiyun depends on EXPERT 273*4882a593Smuzhiyun depends on !STACKDEPOT 274*4882a593Smuzhiyun help 275*4882a593Smuzhiyun This option enables the "guess" unwinder for unwinding kernel stack 276*4882a593Smuzhiyun traces. It scans the stack and reports every kernel text address it 277*4882a593Smuzhiyun finds. Some of the addresses it reports may be incorrect. 278*4882a593Smuzhiyun 279*4882a593Smuzhiyun While this option often produces false positives, it can still be 280*4882a593Smuzhiyun useful in many cases. Unlike the other unwinders, it has no runtime 281*4882a593Smuzhiyun overhead. 282*4882a593Smuzhiyun 283*4882a593Smuzhiyunendchoice 284*4882a593Smuzhiyun 285*4882a593Smuzhiyunconfig FRAME_POINTER 286*4882a593Smuzhiyun depends on !UNWINDER_ORC && !UNWINDER_GUESS 287*4882a593Smuzhiyun bool 288