Kconfig 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402
  1. menu "LED Support"
  2. config LED
  3. bool "Enable LED support"
  4. depends on DM
  5. help
  6. Many boards have LEDs which can be used to signal status or alerts.
  7. U-Boot provides a uclass API to implement this feature. LED drivers
  8. can provide access to board-specific LEDs. Use of the device tree
  9. for configuration is encouraged.
  10. config LED_BCM6328
  11. bool "LED Support for BCM6328"
  12. depends on LED && ARCH_BMIPS
  13. help
  14. This option enables support for LEDs connected to the BCM6328
  15. LED HW controller accessed via MMIO registers.
  16. HW blinking is supported and up to 24 LEDs can be controlled.
  17. All LEDs can blink at the same time but the delay is shared, which
  18. means that if one LED is set to blink at 100ms and then a different
  19. LED is set to blink at 200ms, both will blink at 200ms.
  20. config LED_BCM6358
  21. bool "LED Support for BCM6358"
  22. depends on LED && ARCH_BMIPS
  23. help
  24. This option enables support for LEDs connected to the BCM6358
  25. LED HW controller accessed via MMIO registers.
  26. HW has no blinking capabilities and up to 32 LEDs can be controlled.
  27. config LED_BCM6858
  28. bool "LED Support for BCM6858"
  29. depends on LED && (ARCH_BCM68360 || ARCH_BCM6858 || ARCH_BCM63158)
  30. help
  31. This option enables support for LEDs connected to the BCM6858
  32. HW has blinking capabilities and up to 32 LEDs can be controlled.
  33. config LED_CORTINA
  34. bool "LED Support for Cortina Access CAxxxx SoCs"
  35. depends on LED && (CORTINA_PLATFORM)
  36. help
  37. This option enables support for LEDs connected to the Cortina
  38. Access CAxxxx SOCs.
  39. config LED_BLINK
  40. bool "Support LED blinking"
  41. depends on LED
  42. help
  43. Some drivers can support automatic blinking of LEDs with a given
  44. period, without needing timers or extra code to handle the timing.
  45. This option enables support for this which adds slightly to the
  46. code size.
  47. config SPL_LED
  48. bool "Enable LED support in SPL"
  49. depends on SPL && SPL_DM
  50. help
  51. The LED subsystem adds a small amount of overhead to the image.
  52. If this is acceptable and you have a need to use LEDs in SPL,
  53. enable this option. You will need to enable device tree in SPL
  54. for this to work.
  55. config LED_GPIO
  56. bool "LED support for GPIO-connected LEDs"
  57. depends on LED && DM_GPIO
  58. help
  59. Enable support for LEDs which are connected to GPIO lines. These
  60. GPIOs may be on the SoC or some other device which provides GPIOs.
  61. The GPIO driver must used driver model. LEDs are configured using
  62. the device tree.
  63. config SPL_LED_GPIO
  64. bool "LED support for GPIO-connected LEDs in SPL"
  65. depends on SPL_LED && DM_GPIO
  66. help
  67. This option is an SPL-variant of the LED_GPIO option.
  68. See the help of LED_GPIO for details.
  69. config LED_STATUS
  70. bool "Enable status LED API"
  71. help
  72. Allows common u-boot commands to use a board's leds to
  73. provide status for activities like booting and downloading files.
  74. if LED_STATUS
  75. # Hidden constants
  76. config LED_STATUS_OFF
  77. int
  78. default 0
  79. config LED_STATUS_BLINKING
  80. int
  81. default 1
  82. config LED_STATUS_ON
  83. int
  84. default 2
  85. # Hidden constants end
  86. config LED_STATUS_GPIO
  87. bool "GPIO status LED implementation"
  88. help
  89. The status LED can be connected to a GPIO pin. In such cases, the
  90. gpio_led driver can be used as a status LED backend implementation.
  91. config LED_STATUS_BOARD_SPECIFIC
  92. bool "Specific board"
  93. default y
  94. help
  95. LED support is only for a specific board.
  96. comment "LEDs parameters"
  97. config LED_STATUS0
  98. bool "Enable status LED 0"
  99. if LED_STATUS0
  100. config LED_STATUS_BIT
  101. int "identification"
  102. help
  103. CONFIG_LED_STATUS_BIT is passed into the __led_* functions to identify
  104. which LED is being acted on. As such, the chosen value must be unique
  105. with respect to the other CONFIG_LED_STATUS_BIT's. Mapping the value
  106. to a physical LED is the responsibility of the __led_* function.
  107. config LED_STATUS_STATE
  108. int "initial state"
  109. range LED_STATUS_OFF LED_STATUS_ON
  110. default LED_STATUS_OFF
  111. help
  112. Should be set one of the following:
  113. 0 - off
  114. 1 - blinking
  115. 2 - on
  116. config LED_STATUS_FREQ
  117. int "blink frequency"
  118. range 2 10
  119. default 2
  120. help
  121. The LED blink period calculated from LED_STATUS_FREQ:
  122. LED_STATUS_PERIOD = CONFIG_SYS_HZ/LED_STATUS_FREQ
  123. Values range: 2 - 10
  124. endif # LED_STATUS0
  125. config LED_STATUS1
  126. bool "Enable status LED 1"
  127. if LED_STATUS1
  128. config LED_STATUS_BIT1
  129. int "identification"
  130. help
  131. CONFIG_LED_STATUS_BIT1 is passed into the __led_* functions to
  132. identify which LED is being acted on. As such, the chosen value must
  133. be unique with respect to the other CONFIG_LED_STATUS_BIT's. Mapping
  134. the value to a physical LED is the responsibility of the __led_*
  135. function.
  136. config LED_STATUS_STATE1
  137. int "initial state"
  138. range LED_STATUS_OFF LED_STATUS_ON
  139. default LED_STATUS_OFF
  140. help
  141. Should be set one of the following:
  142. 0 - off
  143. 1 - blinking
  144. 2 - on
  145. config LED_STATUS_FREQ1
  146. int "blink frequency"
  147. range 2 10
  148. default 2
  149. help
  150. The LED blink period calculated from LED_STATUS_FREQ1:
  151. LED_STATUS_PERIOD1 = CONFIG_SYS_HZ/LED_STATUS_FREQ1
  152. Values range: 2 - 10
  153. endif # LED_STATUS1
  154. config LED_STATUS2
  155. bool "Enable status LED 2"
  156. if LED_STATUS2
  157. config LED_STATUS_BIT2
  158. int "identification"
  159. help
  160. CONFIG_LED_STATUS_BIT2 is passed into the __led_* functions to
  161. identify which LED is being acted on. As such, the chosen value must
  162. be unique with respect to the other CONFIG_LED_STATUS_BIT's. Mapping
  163. the value to a physical LED is the responsibility of the __led_*
  164. function.
  165. config LED_STATUS_STATE2
  166. int "initial state"
  167. range LED_STATUS_OFF LED_STATUS_ON
  168. default LED_STATUS_OFF
  169. help
  170. Should be set one of the following:
  171. 0 - off
  172. 1 - blinking
  173. 2 - on
  174. config LED_STATUS_FREQ2
  175. int "blink frequency"
  176. range 2 10
  177. default 2
  178. help
  179. The LED blink period calculated from LED_STATUS_FREQ2:
  180. LED_STATUS_PERIOD2 = CONFIG_SYS_HZ/LED_STATUS_FREQ2
  181. Values range: 2 - 10
  182. endif # LED_STATUS2
  183. config LED_STATUS3
  184. bool "Enable status LED 3"
  185. if LED_STATUS3
  186. config LED_STATUS_BIT3
  187. int "identification"
  188. help
  189. CONFIG_LED_STATUS_BIT3 is passed into the __led_* functions to
  190. identify which LED is being acted on. As such, the chosen value must
  191. be unique with respect to the other CONFIG_LED_STATUS_BIT's. Mapping
  192. the value to a physical LED is the responsibility of the __led_*
  193. function.
  194. config LED_STATUS_STATE3
  195. int "initial state"
  196. range LED_STATUS_OFF LED_STATUS_ON
  197. default LED_STATUS_OFF
  198. help
  199. Should be set one of the following:
  200. 0 - off
  201. 1 - blinking
  202. 2 - on
  203. config LED_STATUS_FREQ3
  204. int "blink frequency"
  205. range 2 10
  206. default 2
  207. help
  208. The LED blink period calculated from LED_STATUS_FREQ3:
  209. LED_STATUS_PERIOD3 = CONFIG_SYS_HZ/LED_STATUS_FREQ3
  210. Values range: 2 - 10
  211. endif # LED_STATUS3
  212. config LED_STATUS4
  213. bool "Enable status LED 4"
  214. if LED_STATUS4
  215. config LED_STATUS_BIT4
  216. int "identification"
  217. help
  218. CONFIG_LED_STATUS_BIT4 is passed into the __led_* functions to
  219. identify which LED is being acted on. As such, the chosen value must
  220. be unique with respect to the other CONFIG_LED_STATUS_BIT's. Mapping
  221. the value to a physical LED is the responsibility of the __led_*
  222. function.
  223. config LED_STATUS_STATE4
  224. int "initial state"
  225. range LED_STATUS_OFF LED_STATUS_ON
  226. default LED_STATUS_OFF
  227. help
  228. Should be set one of the following:
  229. 0 - off
  230. 1 - blinking
  231. 2 - on
  232. config LED_STATUS_FREQ4
  233. int "blink frequency"
  234. range 2 10
  235. default 2
  236. help
  237. The LED blink period calculated from LED_STATUS_FREQ4:
  238. LED_STATUS_PERIOD4 = CONFIG_SYS_HZ/LED_STATUS_FREQ4
  239. Values range: 2 - 10
  240. endif # LED_STATUS4
  241. config LED_STATUS5
  242. bool "Enable status LED 5"
  243. if LED_STATUS5
  244. config LED_STATUS_BIT5
  245. int "identification"
  246. help
  247. CONFIG_LED_STATUS_BIT5 is passed into the __led_* functions to
  248. identify which LED is being acted on. As such, the chosen value must
  249. be unique with respect to the other CONFIG_LED_STATUS_BIT's. Mapping
  250. the value to a physical LED is the responsibility of the __led_*
  251. function.
  252. config LED_STATUS_STATE5
  253. int "initial state"
  254. range LED_STATUS_OFF LED_STATUS_ON
  255. default LED_STATUS_OFF
  256. help
  257. Should be set one of the following:
  258. 0 - off
  259. 1 - blinking
  260. 2 - on
  261. config LED_STATUS_FREQ5
  262. int "blink frequency"
  263. range 2 10
  264. default 2
  265. help
  266. The LED blink period calculated from LED_STATUS_FREQ5:
  267. LED_STATUS_PERIOD5 = CONFIG_SYS_HZ/LED_STATUS_FREQ5
  268. Values range: 2 - 10
  269. endif # LED_STATUS5
  270. config LED_STATUS_BOOT_ENABLE
  271. bool "Enable BOOT LED"
  272. help
  273. Enable to turn an LED on when the board is booting.
  274. if LED_STATUS_BOOT_ENABLE
  275. config LED_STATUS_BOOT
  276. int "LED to light when the board is booting"
  277. help
  278. Valid enabled LED device number.
  279. endif # LED_STATUS_BOOT_ENABLE
  280. config LED_STATUS_RED_ENABLE
  281. bool "Enable red LED"
  282. help
  283. Enable red status LED.
  284. if LED_STATUS_RED_ENABLE
  285. config LED_STATUS_RED
  286. int "Red LED identification"
  287. help
  288. Valid enabled LED device number.
  289. endif # LED_STATUS_RED_ENABLE
  290. config LED_STATUS_YELLOW_ENABLE
  291. bool "Enable yellow LED"
  292. help
  293. Enable yellow status LED.
  294. if LED_STATUS_YELLOW_ENABLE
  295. config LED_STATUS_YELLOW
  296. int "Yellow LED identification"
  297. help
  298. Valid enabled LED device number.
  299. endif # LED_STATUS_YELLOW_ENABLE
  300. config LED_STATUS_BLUE_ENABLE
  301. bool "Enable blue LED"
  302. help
  303. Enable blue status LED.
  304. if LED_STATUS_BLUE_ENABLE
  305. config LED_STATUS_BLUE
  306. int "Blue LED identification"
  307. help
  308. Valid enabled LED device number.
  309. endif # LED_STATUS_BLUE_ENABLE
  310. config LED_STATUS_GREEN_ENABLE
  311. bool "Enable green LED"
  312. help
  313. Enable green status LED.
  314. if LED_STATUS_GREEN_ENABLE
  315. config LED_STATUS_GREEN
  316. int "Green LED identification"
  317. help
  318. Valid enabled LED device number (0-5).
  319. endif # LED_STATUS_GREEN_ENABLE
  320. config LED_STATUS_CMD
  321. bool "Enable status LED commands"
  322. endif # LED_STATUS
  323. endmenu