1# 2# Serial device configuration 3# 4 5menu "Serial drivers" 6 7config BAUDRATE 8 int "Default baudrate" 9 default 115200 10 help 11 Select a default baudrate, where "default" has a driver-specific 12 meaning of either setting the baudrate for the early debug UART 13 in the SPL stage (most drivers) or for choosing a default baudrate 14 in the absence of an environment setting (serial_mxc.c). 15 16config REQUIRE_SERIAL_CONSOLE 17 bool "Require a serial port for console" 18 # Running without a serial console is not supported by the 19 # non-dm serial code 20 depends on DM_SERIAL 21 default y 22 help 23 Require a serial port for the console, and panic if none is found 24 during serial port initialization (default y). Set this to n on 25 boards which have no debug serial port whatsoever. 26 27config SERIAL_PRESENT 28 bool "Provide a serial driver" 29 depends on DM_SERIAL 30 default y 31 help 32 In very space-constrained devices even the full UART driver is too 33 large. In this case the debug UART can still be used in some cases. 34 This option enables the full UART in U-Boot, so if is it disabled, 35 the full UART driver will be omitted, thus saving space. 36 37config SPL_SERIAL_PRESENT 38 bool "Provide a serial driver in SPL" 39 depends on DM_SERIAL 40 default y 41 help 42 In very space-constrained devices even the full UART driver is too 43 large. In this case the debug UART can still be used in some cases. 44 This option enables the full UART in SPL, so if is it disabled, 45 the full UART driver will be omitted, thus saving space. 46 47config DM_SERIAL 48 bool "Enable Driver Model for serial drivers" 49 depends on DM 50 help 51 Enable driver model for serial. This replaces 52 drivers/serial/serial.c with the serial uclass, which 53 implements serial_putc() etc. The uclass interface is 54 defined in include/serial.h. 55 56config SPL_DM_SERIAL 57 bool "Enable Driver Model for serial drivers" 58 depends on DM_SERIAL 59 default y if SPL && DM_SERIAL 60 help 61 Enable driver model for serial in SPL. This replaces 62 drivers/serial/serial.c with the serial uclass, which 63 implements serial_putc() etc. The uclass interface is 64 defined in include/serial.h. 65 66config TPL_DM_SERIAL 67 bool "Enable Driver Model for serial drivers" 68 depends on DM_SERIAL 69 default y if TPL && DM_SERIAL 70 help 71 Enable driver model for serial in TPL. This replaces 72 drivers/serial/serial.c with the serial uclass, which 73 implements serial_putc() etc. The uclass interface is 74 defined in include/serial.h. 75 76config DEBUG_UART 77 bool "Enable an early debug UART for debugging" 78 help 79 The debug UART is intended for use very early in U-Boot to debug 80 problems when an ICE or other debug mechanism is not available. 81 82 To use it you should: 83 - Make sure your UART supports this interface 84 - Enable CONFIG_DEBUG_UART 85 - Enable the CONFIG for your UART to tell it to provide this interface 86 (e.g. CONFIG_DEBUG_UART_NS16550) 87 - Define the required settings as needed (see below) 88 - Call debug_uart_init() before use 89 - Call debug_uart_putc() to output a character 90 91 Depending on your platform it may be possible to use this UART before 92 a stack is available. 93 94 If your UART does not support this interface you can probably add 95 support quite easily. Remember that you cannot use driver model and 96 it is preferred to use no stack. 97 98 You must not use this UART once driver model is working and the 99 serial drivers are up and running (done in serial_init()). Otherwise 100 the drivers may conflict and you will get strange output. 101 102choice 103 prompt "Select which UART will provide the debug UART" 104 depends on DEBUG_UART 105 default DEBUG_UART_NS16550 106 107config DEBUG_UART_ALTERA_JTAGUART 108 bool "Altera JTAG UART" 109 help 110 Select this to enable a debug UART using the altera_jtag_uart driver. 111 You will need to provide parameters to make this work. The driver will 112 be available until the real driver model serial is running. 113 114config DEBUG_UART_ALTERA_UART 115 bool "Altera UART" 116 help 117 Select this to enable a debug UART using the altera_uart driver. 118 You will need to provide parameters to make this work. The driver will 119 be available until the real driver model serial is running. 120 121config DEBUG_UART_AR933X 122 bool "QCA/Atheros ar933x" 123 depends on AR933X_UART 124 help 125 Select this to enable a debug UART using the ar933x uart driver. 126 You will need to provide parameters to make this work. The 127 driver will be available until the real driver model serial is 128 running. 129 130config DEBUG_UART_ATMEL 131 bool "Atmel USART" 132 help 133 Select this to enable a debug UART using the atmel usart driver. You 134 will need to provide parameters to make this work. The driver will 135 be available until the real driver-model serial is running. 136 137config DEBUG_UART_NS16550 138 bool "ns16550" 139 help 140 Select this to enable a debug UART using the ns16550 driver. You 141 will need to provide parameters to make this work. The driver will 142 be available until the real driver model serial is running. 143 144config DEBUG_EFI_CONSOLE 145 bool "EFI" 146 depends on EFI_APP 147 help 148 Select this to enable a debug console which calls back to EFI to 149 output to the console. This can be useful for early debugging of 150 U-Boot when running on top of EFI (Extensive Firmware Interface). 151 This is a type of BIOS used by PCs. 152 153config DEBUG_UART_S5P 154 bool "Samsung S5P" 155 help 156 Select this to enable a debug UART using the serial_s5p driver. You 157 will need to provide parameters to make this work. The driver will 158 be available until the real driver-model serial is running. 159 160config DEBUG_UART_MESON 161 bool "Amlogic Meson" 162 depends on MESON_SERIAL 163 help 164 Select this to enable a debug UART using the serial_meson driver. You 165 will need to provide parameters to make this work. The driver will 166 be available until the real driver-model serial is running. 167 168config DEBUG_UART_UARTLITE 169 bool "Xilinx Uartlite" 170 help 171 Select this to enable a debug UART using the serial_uartlite driver. 172 You will need to provide parameters to make this work. The driver will 173 be available until the real driver-model serial is running. 174 175config DEBUG_UART_ARM_DCC 176 bool "ARM DCC" 177 help 178 Select this to enable a debug UART using the ARM JTAG DCC port. 179 The DCC port can be used for very early debugging and doesn't require 180 any additional setting like address/baudrate/clock. On systems without 181 any serial interface this is the easiest way how to get console. 182 Every ARM core has own DCC port which is the part of debug interface. 183 This port is available at least on ARMv6, ARMv7, ARMv8 and XScale 184 architectures. 185 186config DEBUG_MVEBU_A3700_UART 187 bool "Marvell Armada 3700" 188 help 189 Select this to enable a debug UART using the serial_mvebu driver. You 190 will need to provide parameters to make this work. The driver will 191 be available until the real driver-model serial is running. 192 193config DEBUG_UART_ZYNQ 194 bool "Xilinx Zynq" 195 help 196 Select this to enable a debug UART using the serial_zynq driver. You 197 will need to provide parameters to make this work. The driver will 198 be available until the real driver-model serial is running. 199 200config DEBUG_UART_APBUART 201 depends on LEON3 202 bool "Gaisler APBUART" 203 help 204 Select this to enable a debug UART using the serial_leon3 driver. You 205 will need to provide parameters to make this work. The driver will 206 be available until the real driver model serial is running. 207 208config DEBUG_UART_PL010 209 bool "pl010" 210 help 211 Select this to enable a debug UART using the pl01x driver with the 212 PL010 UART type. You will need to provide parameters to make this 213 work. The driver will be available until the real driver model 214 serial is running. 215 216config DEBUG_UART_PL011 217 bool "pl011" 218 help 219 Select this to enable a debug UART using the pl01x driver with the 220 PL011 UART type. You will need to provide parameters to make this 221 work. The driver will be available until the real driver model 222 serial is running. 223 224config DEBUG_UART_PIC32 225 bool "Microchip PIC32" 226 depends on PIC32_SERIAL 227 help 228 Select this to enable a debug UART using the serial_pic32 driver. You 229 will need to provide parameters to make this work. The driver will 230 be available until the real driver model serial is running. 231 232config DEBUG_UART_UNIPHIER 233 bool "UniPhier on-chip UART" 234 depends on ARCH_UNIPHIER 235 help 236 Select this to enable a debug UART using the UniPhier on-chip UART. 237 You will need to provide DEBUG_UART_BASE to make this work. The 238 driver will be available until the real driver-model serial is 239 running. 240 241endchoice 242 243config DEBUG_UART_BASE 244 hex "Base address of UART" 245 depends on DEBUG_UART 246 help 247 This is the base address of your UART for memory-mapped UARTs. 248 249 A default should be provided by your board, but if not you will need 250 to use the correct value here. 251 252config DEBUG_UART_CLOCK 253 int "UART input clock" 254 depends on DEBUG_UART 255 help 256 The UART input clock determines the speed of the internal UART 257 circuitry. The baud rate is derived from this by dividing the input 258 clock down. 259 260 A default should be provided by your board, but if not you will need 261 to use the correct value here. 262 263config DEBUG_UART_SHIFT 264 int "UART register shift" 265 depends on DEBUG_UART 266 default 0 if DEBUG_UART 267 help 268 Some UARTs (notably ns16550) support different register layouts 269 where the registers are spaced either as bytes, words or some other 270 value. Use this value to specify the shift to use, where 0=byte 271 registers, 2=32-bit word registers, etc. 272 273config DEBUG_UART_BOARD_INIT 274 bool "Enable board-specific debug UART init" 275 depends on DEBUG_UART 276 help 277 Some boards need to set things up before the debug UART can be used. 278 On these boards a call to debug_uart_init() is insufficient. When 279 this option is enabled, the function board_debug_uart_init() will 280 be called when debug_uart_init() is called. You can put any code 281 here that is needed to set up the UART ready for use, such as set 282 pin multiplexing or enable clocks. 283 284config DEBUG_UART_ANNOUNCE 285 bool "Show a message when the debug UART starts up" 286 depends on DEBUG_UART 287 help 288 Enable this option to show a message when the debug UART is ready 289 for use. You will see a message like "<debug_uart> " as soon as 290 U-Boot has the UART ready for use (i.e. your code calls 291 debug_uart_init()). This can be useful just as a check that 292 everything is working. 293 294config DEBUG_UART_SKIP_INIT 295 bool "Skip UART initialization" 296 help 297 Select this if the UART you want to use for debug output is already 298 initialized by the time U-Boot starts its execution. 299 300config ALTERA_JTAG_UART 301 bool "Altera JTAG UART support" 302 depends on DM_SERIAL 303 help 304 Select this to enable an JTAG UART for Altera devices.The JTAG UART 305 core implements a method to communicate serial character streams 306 between a host PC and a Qsys system on an Altera FPGA. Please find 307 details on the "Embedded Peripherals IP User Guide" of Altera. 308 309config ALTERA_JTAG_UART_BYPASS 310 bool "Bypass output when no connection" 311 depends on ALTERA_JTAG_UART 312 help 313 Bypass console output and keep going even if there is no JTAG 314 terminal connection with the host. The console output will resume 315 once the JTAG terminal is connected. Without the bypass, the console 316 output will wait forever until a JTAG terminal is connected. If you 317 not are sure, say Y. 318 319config ALTERA_UART 320 bool "Altera UART support" 321 depends on DM_SERIAL 322 help 323 Select this to enable an UART for Altera devices. Please find 324 details on the "Embedded Peripherals IP User Guide" of Altera. 325 326config AR933X_UART 327 bool "QCA/Atheros ar933x UART support" 328 depends on DM_SERIAL && SOC_AR933X 329 help 330 Select this to enable UART support for QCA/Atheros ar933x 331 devices. This driver uses driver model and requires a device 332 tree binding to operate, please refer to the document at 333 doc/device-tree-bindings/serial/qca,ar9330-uart.txt. 334 335config ATMEL_USART 336 bool "Atmel USART support" 337 help 338 Select this to enable USART support for Atmel SoCs. It can be 339 configured in the device tree, and input clock frequency can 340 be got from the clk node. 341 342config FSL_LPUART 343 bool "Freescale LPUART support" 344 help 345 Select this to enable a Low Power UART for Freescale VF610 and 346 QorIQ Layerscape devices. 347 348config MVEBU_A3700_UART 349 bool "UART support for Armada 3700" 350 default n 351 help 352 Choose this option to add support for UART driver on the Marvell 353 Armada 3700 SoC. The base address is configured via DT. 354 355config MXC_UART 356 bool "IMX serial port support" 357 depends on MX5 || MX6 358 help 359 If you have a machine based on a Motorola IMX CPU you 360 can enable its onboard serial port by enabling this option. 361 362config PIC32_SERIAL 363 bool "Support for Microchip PIC32 on-chip UART" 364 depends on DM_SERIAL && MACH_PIC32 365 default y 366 help 367 Support for the UART found on Microchip PIC32 SoC's. 368 369config SYS_NS16550 370 bool "NS16550 UART or compatible" 371 help 372 Support NS16550 UART or compatible. This can be enabled in the 373 device tree with the correct input clock frequency. If the input 374 clock frequency is not defined in the device tree, the macro 375 CONFIG_SYS_NS16550_CLK defined in a legacy board header file will 376 be used. It can be a constant or a function to get clock, eg, 377 get_serial_clock(). 378 379config INTEL_MID_SERIAL 380 bool "Intel MID platform UART support" 381 depends on DM_SERIAL && OF_CONTROL 382 depends on INTEL_MID 383 select SYS_NS16550 384 help 385 Select this to enable a UART for Intel MID platforms. 386 This uses the ns16550 driver as a library. 387 388config ROCKCHIP_SERIAL 389 bool "Rockchip on-chip UART support" 390 depends on DM_SERIAL && SPL_OF_PLATDATA 391 help 392 Select this to enable a debug UART for Rockchip devices when using 393 CONFIG_SPL_OF_PLATDATA (i.e. a compiled-in device tree replacemenmt). 394 This uses the ns16550 driver, converting the platdata from of-platdata 395 to the ns16550 format. 396 397config SANDBOX_SERIAL 398 bool "Sandbox UART support" 399 depends on SANDBOX 400 help 401 Select this to enable a seral UART for sandbox. This is required to 402 operate correctly, otherwise you will see no serial output from 403 sandbox. The emulated UART will display to the console and console 404 input will be fed into the UART. This allows you to interact with 405 U-Boot. 406 407 The operation of the console is controlled by the -t command-line 408 flag. In raw mode, U-Boot sees all characters from the terminal 409 before they are processed, including Ctrl-C. In cooked mode, Ctrl-C 410 is processed by the terminal, and terminates U-Boot. Valid options 411 are: 412 413 -t raw-with-sigs Raw mode, Ctrl-C will terminate U-Boot 414 -t raw Raw mode, Ctrl-C is processed by U-Boot 415 -t cooked Cooked mode, Ctrl-C terminates 416 417config UNIPHIER_SERIAL 418 bool "Support for UniPhier on-chip UART" 419 depends on ARCH_UNIPHIER 420 default y 421 help 422 If you have a UniPhier based board and want to use the on-chip 423 serial ports, say Y to this option. If unsure, say N. 424 425config XILINX_UARTLITE 426 bool "Xilinx Uarlite support" 427 depends on DM_SERIAL && (MICROBLAZE || ARCH_ZYNQ || ARCH_ZYNQMP || 4xx) 428 help 429 If you have a Xilinx based board and want to use the uartlite 430 serial ports, say Y to this option. If unsure, say N. 431 432config MESON_SERIAL 433 bool "Support for Amlogic Meson UART" 434 depends on DM_SERIAL && ARCH_MESON 435 help 436 If you have an Amlogic Meson based board and want to use the on-chip 437 serial ports, say Y to this option. If unsure, say N. 438 439config MSM_SERIAL 440 bool "Qualcomm on-chip UART" 441 depends on DM_SERIAL 442 help 443 Support Data Mover UART used on Qualcomm Snapdragon SoCs. 444 It should support all Qualcomm devices with UARTDM version 1.4, 445 for example APQ8016 and MSM8916. 446 Single baudrate is supported in current implementation (115200). 447 448config PXA_SERIAL 449 bool "PXA serial port support" 450 help 451 If you have a machine based on a Marvell XScale PXA2xx CPU you 452 can enable its onboard serial ports by enabling this option. 453 454config STI_ASC_SERIAL 455 bool "STMicroelectronics on-chip UART" 456 depends on DM_SERIAL && ARCH_STI 457 help 458 Select this to enable Asynchronous Serial Controller available 459 on STiH410 SoC. This is a basic implementation, it supports 460 following baudrate 9600, 19200, 38400, 57600 and 115200. 461 462endmenu 463