Kconfig 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. # SPDX-License-Identifier: GPL-2.0
  2. config DTC
  3. bool
  4. config GENERIC_BUILTIN_DTB
  5. bool
  6. config BUILTIN_DTB_ALL
  7. bool
  8. menuconfig OF
  9. bool "Device Tree and Open Firmware support"
  10. help
  11. This option enables the device tree infrastructure.
  12. It is automatically selected by platforms that need it or can
  13. be enabled manually for unittests, overlays or
  14. compile-coverage.
  15. if OF
  16. config OF_UNITTEST
  17. bool "Device Tree runtime unit tests"
  18. depends on OF_EARLY_FLATTREE
  19. select IRQ_DOMAIN
  20. select OF_RESOLVE
  21. help
  22. This option builds in test cases for the device tree infrastructure
  23. that are executed once at boot time, and the results dumped to the
  24. console.
  25. This option should only be enabled for a development kernel. The tests
  26. will taint the kernel with TAINT_TEST. The tests will cause ERROR and
  27. WARNING messages to print on the console. The tests will cause stack
  28. traces to print on the console. It is possible that the tests will
  29. leave the devicetree in a corrupted state.
  30. The unittest output will be verbose. Copy the output to a file
  31. via capturing the console output or via the dmesg command. Process
  32. this file with scripts/dtc/of_unittest_expect to reduce the
  33. verbosity, test whether expected output is present, and to
  34. summarize the results.
  35. If unsure, say N here. This option is not safe to enable.
  36. config OF_KUNIT_TEST
  37. tristate "Devicetree KUnit Test" if !KUNIT_ALL_TESTS
  38. depends on KUNIT
  39. default KUNIT_ALL_TESTS
  40. help
  41. This option builds KUnit unit tests for device tree infrastructure.
  42. If unsure, say N here, but this option is safe to enable.
  43. config OF_ALL_DTBS
  44. bool "Build all Device Tree Blobs"
  45. depends on COMPILE_TEST
  46. select DTC
  47. help
  48. This option builds all possible Device Tree Blobs (DTBs) for the
  49. current architecture.
  50. If unsure, say N here, but this option is safe to enable.
  51. config OF_FLATTREE
  52. bool
  53. select DTC
  54. select LIBFDT
  55. select CRC32
  56. config OF_EARLY_FLATTREE
  57. def_bool OF && !(SPARC || ALPHA || HEXAGON || M68K || PARISC || S390)
  58. select DMA_DECLARE_COHERENT if HAS_DMA && HAS_IOMEM
  59. select OF_FLATTREE
  60. config OF_PROMTREE
  61. bool
  62. config OF_KOBJ
  63. def_bool SYSFS
  64. # Hardly any platforms need this. It is safe to select, but only do so if you
  65. # need it.
  66. config OF_DYNAMIC
  67. bool "Support for dynamic device trees" if OF_UNITTEST
  68. select OF_KOBJ
  69. help
  70. On some platforms, the device tree can be manipulated at runtime.
  71. While this option is selected automatically on such platforms, you
  72. can enable it manually to improve device tree unit test coverage.
  73. config OF_ADDRESS
  74. def_bool y
  75. depends on !SPARC && (HAS_IOMEM || UML)
  76. config OF_IRQ
  77. def_bool y
  78. depends on !SPARC && IRQ_DOMAIN
  79. config OF_RESERVED_MEM
  80. def_bool OF_EARLY_FLATTREE
  81. config OF_RESOLVE
  82. bool
  83. config OF_OVERLAY
  84. bool "Device Tree overlays"
  85. select OF_DYNAMIC
  86. select OF_FLATTREE
  87. select OF_RESOLVE
  88. help
  89. Overlays are a method to dynamically modify part of the kernel's
  90. device tree with dynamically loaded data.
  91. While this option is selected automatically when needed, you can
  92. enable it manually to improve device tree unit test coverage.
  93. config OF_OVERLAY_KUNIT_TEST
  94. tristate "Device Tree overlay KUnit tests" if !KUNIT_ALL_TESTS
  95. depends on KUNIT
  96. default KUNIT_ALL_TESTS
  97. select DTC
  98. help
  99. This option builds KUnit unit tests for the device tree overlay code.
  100. If unsure, say N here, but this option is safe to enable.
  101. config OF_NUMA
  102. bool
  103. endif # OF