Kconfig 9.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286
  1. # SPDX-License-Identifier: GPL-2.0-only
  2. menu "EFI (Extensible Firmware Interface) Support"
  3. depends on EFI
  4. config EFI_VARS
  5. tristate "EFI Variable Support via sysfs"
  6. depends on EFI && (X86 || IA64)
  7. default n
  8. help
  9. If you say Y here, you are able to get EFI (Extensible Firmware
  10. Interface) variable information via sysfs. You may read,
  11. write, create, and destroy EFI variables through this interface.
  12. Note that this driver is only retained for compatibility with
  13. legacy users: new users should use the efivarfs filesystem
  14. instead.
  15. config EFI_ESRT
  16. bool
  17. depends on EFI && !IA64
  18. default y
  19. config EFI_VARS_PSTORE
  20. tristate "Register efivars backend for pstore"
  21. depends on PSTORE
  22. default y
  23. help
  24. Say Y here to enable use efivars as a backend to pstore. This
  25. will allow writing console messages, crash dumps, or anything
  26. else supported by pstore to EFI variables.
  27. config EFI_VARS_PSTORE_DEFAULT_DISABLE
  28. bool "Disable using efivars as a pstore backend by default"
  29. depends on EFI_VARS_PSTORE
  30. default n
  31. help
  32. Saying Y here will disable the use of efivars as a storage
  33. backend for pstore by default. This setting can be overridden
  34. using the efivars module's pstore_disable parameter.
  35. config EFI_RUNTIME_MAP
  36. bool "Export efi runtime maps to sysfs"
  37. depends on X86 && EFI && KEXEC_CORE
  38. default y
  39. help
  40. Export efi runtime memory maps to /sys/firmware/efi/runtime-map.
  41. That memory map is used for example by kexec to set up efi virtual
  42. mapping the 2nd kernel, but can also be used for debugging purposes.
  43. See also Documentation/ABI/testing/sysfs-firmware-efi-runtime-map.
  44. config EFI_FAKE_MEMMAP
  45. bool "Enable EFI fake memory map"
  46. depends on EFI && X86
  47. default n
  48. help
  49. Saying Y here will enable "efi_fake_mem" boot option.
  50. By specifying this parameter, you can add arbitrary attribute
  51. to specific memory range by updating original (firmware provided)
  52. EFI memmap.
  53. This is useful for debugging of EFI memmap related feature.
  54. e.g. Address Range Mirroring feature.
  55. config EFI_MAX_FAKE_MEM
  56. int "maximum allowable number of ranges in efi_fake_mem boot option"
  57. depends on EFI_FAKE_MEMMAP
  58. range 1 128
  59. default 8
  60. help
  61. Maximum allowable number of ranges in efi_fake_mem boot option.
  62. Ranges can be set up to this value using comma-separated list.
  63. The default value is 8.
  64. config EFI_SOFT_RESERVE
  65. bool "Reserve EFI Specific Purpose Memory"
  66. depends on EFI && EFI_STUB && ACPI_HMAT
  67. default ACPI_HMAT
  68. help
  69. On systems that have mixed performance classes of memory EFI
  70. may indicate specific purpose memory with an attribute (See
  71. EFI_MEMORY_SP in UEFI 2.8). A memory range tagged with this
  72. attribute may have unique performance characteristics compared
  73. to the system's general purpose "System RAM" pool. On the
  74. expectation that such memory has application specific usage,
  75. and its base EFI memory type is "conventional" answer Y to
  76. arrange for the kernel to reserve it as a "Soft Reserved"
  77. resource, and set aside for direct-access (device-dax) by
  78. default. The memory range can later be optionally assigned to
  79. the page allocator by system administrator policy via the
  80. device-dax kmem facility. Say N to have the kernel treat this
  81. memory as "System RAM" by default.
  82. If unsure, say Y.
  83. config EFI_PARAMS_FROM_FDT
  84. bool
  85. help
  86. Select this config option from the architecture Kconfig if
  87. the EFI runtime support gets system table address, memory
  88. map address, and other parameters from the device tree.
  89. config EFI_RUNTIME_WRAPPERS
  90. bool
  91. config EFI_GENERIC_STUB
  92. bool
  93. config EFI_ARMSTUB_DTB_LOADER
  94. bool "Enable the DTB loader"
  95. depends on EFI_GENERIC_STUB && !RISCV
  96. default y
  97. help
  98. Select this config option to add support for the dtb= command
  99. line parameter, allowing a device tree blob to be loaded into
  100. memory from the EFI System Partition by the stub.
  101. If the device tree is provided by the platform or by
  102. the bootloader this option may not be needed.
  103. But, for various development reasons and to maintain existing
  104. functionality for bootloaders that do not have such support
  105. this option is necessary.
  106. config EFI_GENERIC_STUB_INITRD_CMDLINE_LOADER
  107. bool "Enable the command line initrd loader" if !X86
  108. depends on EFI_STUB && (EFI_GENERIC_STUB || X86)
  109. default y
  110. depends on !RISCV
  111. help
  112. Select this config option to add support for the initrd= command
  113. line parameter, allowing an initrd that resides on the same volume
  114. as the kernel image to be loaded into memory.
  115. This method is deprecated.
  116. config EFI_BOOTLOADER_CONTROL
  117. tristate "EFI Bootloader Control"
  118. default n
  119. help
  120. This module installs a reboot hook, such that if reboot() is
  121. invoked with a string argument NNN, "NNN" is copied to the
  122. "LoaderEntryOneShot" EFI variable, to be read by the
  123. bootloader. If the string matches one of the boot labels
  124. defined in its configuration, the bootloader will boot once
  125. to that label. The "LoaderEntryRebootReason" EFI variable is
  126. set with the reboot reason: "reboot" or "shutdown". The
  127. bootloader reads this reboot reason and takes particular
  128. action according to its policy.
  129. config EFI_CAPSULE_LOADER
  130. tristate "EFI capsule loader"
  131. depends on EFI
  132. help
  133. This option exposes a loader interface "/dev/efi_capsule_loader" for
  134. users to load EFI capsules. This driver requires working runtime
  135. capsule support in the firmware, which many OEMs do not provide.
  136. Most users should say N.
  137. config EFI_CAPSULE_QUIRK_QUARK_CSH
  138. bool "Add support for Quark capsules with non-standard headers"
  139. depends on X86 && !64BIT
  140. select EFI_CAPSULE_LOADER
  141. default y
  142. help
  143. Add support for processing Quark X1000 EFI capsules, whose header
  144. layout deviates from the layout mandated by the UEFI specification.
  145. config EFI_TEST
  146. tristate "EFI Runtime Service Tests Support"
  147. depends on EFI
  148. default n
  149. help
  150. This driver uses the efi.<service> function pointers directly instead
  151. of going through the efivar API, because it is not trying to test the
  152. kernel subsystem, just for testing the UEFI runtime service
  153. interfaces which are provided by the firmware. This driver is used
  154. by the Firmware Test Suite (FWTS) for testing the UEFI runtime
  155. interfaces readiness of the firmware.
  156. Details for FWTS are available from:
  157. <https://wiki.ubuntu.com/FirmwareTestSuite>
  158. Say Y here to enable the runtime services support via /dev/efi_test.
  159. If unsure, say N.
  160. config APPLE_PROPERTIES
  161. bool "Apple Device Properties"
  162. depends on EFI_STUB && X86
  163. select EFI_DEV_PATH_PARSER
  164. select UCS2_STRING
  165. help
  166. Retrieve properties from EFI on Apple Macs and assign them to
  167. devices, allowing for improved support of Apple hardware.
  168. Properties that would otherwise be missing include the
  169. Thunderbolt Device ROM and GPU configuration data.
  170. If unsure, say Y if you have a Mac. Otherwise N.
  171. config RESET_ATTACK_MITIGATION
  172. bool "Reset memory attack mitigation"
  173. depends on EFI_STUB
  174. help
  175. Request that the firmware clear the contents of RAM after a reboot
  176. using the TCG Platform Reset Attack Mitigation specification. This
  177. protects against an attacker forcibly rebooting the system while it
  178. still contains secrets in RAM, booting another OS and extracting the
  179. secrets. This should only be enabled when userland is configured to
  180. clear the MemoryOverwriteRequest flag on clean shutdown after secrets
  181. have been evicted, since otherwise it will trigger even on clean
  182. reboots.
  183. config EFI_RCI2_TABLE
  184. bool "EFI Runtime Configuration Interface Table Version 2 Support"
  185. depends on X86 || COMPILE_TEST
  186. help
  187. Displays the content of the Runtime Configuration Interface
  188. Table version 2 on Dell EMC PowerEdge systems as a binary
  189. attribute 'rci2' under /sys/firmware/efi/tables directory.
  190. RCI2 table contains BIOS HII in XML format and is used to populate
  191. BIOS setup page in Dell EMC OpenManage Server Administrator tool.
  192. The BIOS setup page contains BIOS tokens which can be configured.
  193. Say Y here for Dell EMC PowerEdge systems.
  194. config EFI_DISABLE_PCI_DMA
  195. bool "Clear Busmaster bit on PCI bridges during ExitBootServices()"
  196. help
  197. Disable the busmaster bit in the control register on all PCI bridges
  198. while calling ExitBootServices() and passing control to the runtime
  199. kernel. System firmware may configure the IOMMU to prevent malicious
  200. PCI devices from being able to attack the OS via DMA. However, since
  201. firmware can't guarantee that the OS is IOMMU-aware, it will tear
  202. down IOMMU configuration when ExitBootServices() is called. This
  203. leaves a window between where a hostile device could still cause
  204. damage before Linux configures the IOMMU again.
  205. If you say Y here, the EFI stub will clear the busmaster bit on all
  206. PCI bridges before ExitBootServices() is called. This will prevent
  207. any malicious PCI devices from being able to perform DMA until the
  208. kernel reenables busmastering after configuring the IOMMU.
  209. This option will cause failures with some poorly behaved hardware
  210. and should not be enabled without testing. The kernel commandline
  211. options "efi=disable_early_pci_dma" or "efi=no_disable_early_pci_dma"
  212. may be used to override this option.
  213. endmenu
  214. config EFI_EMBEDDED_FIRMWARE
  215. bool
  216. depends on EFI
  217. select CRYPTO_LIB_SHA256
  218. config UEFI_CPER
  219. bool
  220. config UEFI_CPER_ARM
  221. bool
  222. depends on UEFI_CPER && ( ARM || ARM64 )
  223. default y
  224. config UEFI_CPER_X86
  225. bool
  226. depends on UEFI_CPER && X86
  227. default y
  228. config EFI_DEV_PATH_PARSER
  229. bool
  230. depends on ACPI
  231. default n
  232. config EFI_EARLYCON
  233. def_bool y
  234. depends on EFI && SERIAL_EARLYCON && !ARM && !IA64
  235. select FONT_SUPPORT
  236. select ARCH_USE_MEMREMAP_PROT
  237. config EFI_CUSTOM_SSDT_OVERLAYS
  238. bool "Load custom ACPI SSDT overlay from an EFI variable"
  239. depends on EFI && ACPI
  240. default ACPI_TABLE_UPGRADE
  241. help
  242. Allow loading of an ACPI SSDT overlay from an EFI variable specified
  243. by a kernel command line option.
  244. See Documentation/admin-guide/acpi/ssdt-overlays.rst for more
  245. information.