]>
Commit | Line | Data |
---|---|---|
0b11dbf7 MY |
1 | # |
2 | # Serial device configuration | |
3 | # | |
4 | ||
5 | menu "Serial drivers" | |
6 | ||
8c458588 HG |
7 | config REQUIRE_SERIAL_CONSOLE |
8 | bool "Require a serial port for console" | |
9 | # Running without a serial console is not supported by the | |
10 | # non-dm serial code | |
11 | depends on DM_SERIAL | |
12 | default y | |
13 | help | |
14 | Require a serial port for the console, and panic if none is found | |
15 | during serial port initialization (default y). Set this to n on | |
16 | boards which have no debug serial port whatsoever. | |
17 | ||
da333ae7 MY |
18 | config DM_SERIAL |
19 | bool "Enable Driver Model for serial drivers" | |
20 | depends on DM | |
21 | help | |
f94a1bed SG |
22 | Enable driver model for serial. This replaces |
23 | drivers/serial/serial.c with the serial uclass, which | |
24 | implements serial_putc() etc. The uclass interface is | |
25 | defined in include/serial.h. | |
ff247b7a | 26 | |
2f964aa7 SG |
27 | config DEBUG_UART |
28 | bool "Enable an early debug UART for debugging" | |
29 | help | |
30 | The debug UART is intended for use very early in U-Boot to debug | |
31 | problems when an ICE or other debug mechanism is not available. | |
32 | ||
33 | To use it you should: | |
34 | - Make sure your UART supports this interface | |
35 | - Enable CONFIG_DEBUG_UART | |
36 | - Enable the CONFIG for your UART to tell it to provide this interface | |
37 | (e.g. CONFIG_DEBUG_UART_NS16550) | |
38 | - Define the required settings as needed (see below) | |
39 | - Call debug_uart_init() before use | |
40 | - Call debug_uart_putc() to output a character | |
41 | ||
42 | Depending on your platform it may be possible to use this UART before | |
43 | a stack is available. | |
44 | ||
45 | If your UART does not support this interface you can probably add | |
46 | support quite easily. Remember that you cannot use driver model and | |
47 | it is preferred to use no stack. | |
48 | ||
49 | You must not use this UART once driver model is working and the | |
50 | serial drivers are up and running (done in serial_init()). Otherwise | |
51 | the drivers may conflict and you will get strange output. | |
52 | ||
21d00436 SG |
53 | choice |
54 | prompt "Select which UART will provide the debug UART" | |
55 | depends on DEBUG_UART | |
b1e361b6 | 56 | default DEBUG_UART_NS16550 |
21d00436 | 57 | |
220e8021 TC |
58 | config DEBUG_UART_ALTERA_JTAGUART |
59 | bool "Altera JTAG UART" | |
60 | help | |
61 | Select this to enable a debug UART using the altera_jtag_uart driver. | |
62 | You will need to provide parameters to make this work. The driver will | |
63 | be available until the real driver model serial is running. | |
64 | ||
da2f838d TC |
65 | config DEBUG_UART_ALTERA_UART |
66 | bool "Altera UART" | |
67 | help | |
68 | Select this to enable a debug UART using the altera_uart driver. | |
69 | You will need to provide parameters to make this work. The driver will | |
70 | be available until the real driver model serial is running. | |
71 | ||
21d00436 SG |
72 | config DEBUG_UART_NS16550 |
73 | bool "ns16550" | |
74 | help | |
75 | Select this to enable a debug UART using the ns16550 driver. You | |
76 | will need to provide parameters to make this work. The driver will | |
77 | be available until the real driver model serial is running. | |
78 | ||
275854ba SG |
79 | config DEBUG_EFI_CONSOLE |
80 | bool "EFI" | |
81 | depends on EFI_APP | |
82 | help | |
83 | Select this to enable a debug console which calls back to EFI to | |
84 | output to the console. This can be useful for early debugging of | |
85 | U-Boot when running on top of EFI (Extensive Firmware Interface). | |
86 | This is a type of BIOS used by PCs. | |
87 | ||
bf6e7022 SG |
88 | config DEBUG_UART_S5P |
89 | bool "Samsung S5P" | |
90 | help | |
91 | Select this to enable a debug UART using the serial_s5p driver. You | |
92 | will need to provide parameters to make this work. The driver will | |
93 | be available until the real driver-model serial is running. | |
94 | ||
c54c0a4c SG |
95 | config DEBUG_UART_ZYNQ |
96 | bool "Xilinx Zynq" | |
97 | help | |
98 | Select this to enable a debug UART using the serial_s5p driver. You | |
99 | will need to provide parameters to make this work. The driver will | |
100 | be available until the real driver-model serial is running. | |
101 | ||
e43ce3fc FR |
102 | config DEBUG_UART_APBUART |
103 | depends on LEON3 | |
104 | bool "Gaisler APBUART" | |
105 | help | |
106 | Select this to enable a debug UART using the serial_leon3 driver. You | |
107 | will need to provide parameters to make this work. The driver will | |
108 | be available until the real driver model serial is running. | |
109 | ||
21d00436 SG |
110 | endchoice |
111 | ||
2f964aa7 SG |
112 | config DEBUG_UART_BASE |
113 | hex "Base address of UART" | |
114 | depends on DEBUG_UART | |
115 | help | |
116 | This is the base address of your UART for memory-mapped UARTs. | |
117 | ||
118 | A default should be provided by your board, but if not you will need | |
119 | to use the correct value here. | |
120 | ||
121 | config DEBUG_UART_CLOCK | |
122 | int "UART input clock" | |
123 | depends on DEBUG_UART | |
124 | help | |
125 | The UART input clock determines the speed of the internal UART | |
126 | circuitry. The baud rate is derived from this by dividing the input | |
127 | clock down. | |
128 | ||
129 | A default should be provided by your board, but if not you will need | |
130 | to use the correct value here. | |
131 | ||
dd0b0122 SG |
132 | config DEBUG_UART_SHIFT |
133 | int "UART register shift" | |
134 | depends on DEBUG_UART | |
135 | default 0 if DEBUG_UART | |
136 | help | |
137 | Some UARTs (notably ns16550) support different register layouts | |
138 | where the registers are spaced either as bytes, words or some other | |
139 | value. Use this value to specify the shift to use, where 0=byte | |
140 | registers, 2=32-bit word registers, etc. | |
141 | ||
0e977bc1 SG |
142 | config DEBUG_UART_BOARD_INIT |
143 | bool "Enable board-specific debug UART init" | |
144 | depends on DEBUG_UART | |
145 | help | |
146 | Some boards need to set things up before the debug UART can be used. | |
147 | On these boards a call to debug_uart_init() is insufficient. When | |
148 | this option is enabled, the function board_debug_uart_init() will | |
149 | be called when debug_uart_init() is called. You can put any code | |
150 | here that is needed to set up the UART ready for use, such as set | |
151 | pin multiplexing or enable clocks. | |
152 | ||
c7fefcb9 SG |
153 | config DEBUG_UART_ANNOUNCE |
154 | bool "Show a message when the debug UART starts up" | |
155 | depends on DEBUG_UART | |
156 | help | |
157 | Enable this option to show a message when the debug UART is ready | |
158 | for use. You will see a message like "<debug_uart> " as soon as | |
159 | U-Boot has the UART ready for use (i.e. your code calls | |
160 | debug_uart_init()). This can be useful just as a check that | |
161 | everything is working. | |
162 | ||
220e8021 TC |
163 | config ALTERA_JTAG_UART |
164 | bool "Altera JTAG UART support" | |
165 | depends on DM_SERIAL | |
166 | help | |
167 | Select this to enable an JTAG UART for Altera devices.The JTAG UART | |
168 | core implements a method to communicate serial character streams | |
169 | between a host PC and a Qsys system on an Altera FPGA. Please find | |
170 | details on the "Embedded Peripherals IP User Guide" of Altera. | |
171 | ||
172 | config ALTERA_JTAG_UART_BYPASS | |
173 | bool "Bypass output when no connection" | |
174 | depends on ALTERA_JTAG_UART | |
175 | help | |
176 | Bypass console output and keep going even if there is no JTAG | |
177 | terminal connection with the host. The console output will resume | |
178 | once the JTAG terminal is connected. Without the bypass, the console | |
179 | output will wait forever until a JTAG terminal is connected. If you | |
180 | not are sure, say Y. | |
181 | ||
da2f838d TC |
182 | config ALTERA_UART |
183 | bool "Altera UART support" | |
184 | depends on DM_SERIAL | |
185 | help | |
186 | Select this to enable an UART for Altera devices. Please find | |
187 | details on the "Embedded Peripherals IP User Guide" of Altera. | |
188 | ||
765a1b1e SG |
189 | config ROCKCHIP_SERIAL |
190 | bool "Rockchip on-chip UART support" | |
d18f37c7 | 191 | depends on ARCH_ROCKCHIP && DM_SERIAL |
765a1b1e SG |
192 | help |
193 | Select this to enable a debug UART for Rockchip devices. This uses | |
194 | the ns16550 driver. You will need to #define CONFIG_SYS_NS16550 in | |
195 | your board config header. The clock input is automatically set to | |
196 | use the oscillator (24MHz). | |
197 | ||
8e62d32e TC |
198 | config NS16550_SERIAL |
199 | bool "NS16550 UART or compatible" | |
200 | depends on DM_SERIAL | |
201 | help | |
202 | Support NS16550 UART or compatible with driver model. This can be | |
203 | enabled in the device tree with the correct input clock frequency. | |
204 | If the input clock frequency is not defined in the device tree, | |
205 | the macro CONFIG_SYS_NS16550_CLK defined in a legacy board header | |
206 | file will be used. It can be a constant or a function to get clock, | |
207 | eg, get_serial_clock(). | |
208 | ||
af282245 SG |
209 | config SANDBOX_SERIAL |
210 | bool "Sandbox UART support" | |
2ea65f3e | 211 | depends on SANDBOX |
af282245 SG |
212 | help |
213 | Select this to enable a seral UART for sandbox. This is required to | |
214 | operate correctly, otherwise you will see no serial output from | |
215 | sandbox. The emulated UART will display to the console and console | |
216 | input will be fed into the UART. This allows you to interact with | |
217 | U-Boot. | |
218 | ||
219 | The operation of the console is controlled by the -t command-line | |
220 | flag. In raw mode, U-Boot sees all characters from the terminal | |
221 | before they are processed, including Ctrl-C. In cooked mode, Ctrl-C | |
222 | is processed by the terminal, and terminates U-Boot. Valid options | |
223 | are: | |
224 | ||
225 | -t raw-with-sigs Raw mode, Ctrl-C will terminate U-Boot | |
226 | -t raw Raw mode, Ctrl-C is processed by U-Boot | |
227 | -t cooked Cooked mode, Ctrl-C terminates | |
228 | ||
ff247b7a | 229 | config UNIPHIER_SERIAL |
b6ef3a3f | 230 | bool "Support for UniPhier on-chip UART" |
2ea65f3e | 231 | depends on ARCH_UNIPHIER |
ff247b7a | 232 | help |
b6ef3a3f MY |
233 | If you have a UniPhier based board and want to use the on-chip |
234 | serial ports, say Y to this option. If unsure, say N. | |
dcfe4a54 SG |
235 | |
236 | config X86_SERIAL | |
237 | bool "Support for 16550 serial port on x86 machines" | |
238 | depends on X86 | |
239 | default y | |
240 | help | |
241 | Most x86 machines have a ns16550 UART or compatible. This can be | |
242 | enabled in the device tree with the correct input clock frequency | |
243 | provided (default 1843200). Enable this to obtain serial console | |
244 | output. | |
0b11dbf7 MY |
245 | |
246 | endmenu |