Stefan Reinauer | 1b34226 | 2011-01-05 02:27:53 +0000 | [diff] [blame] | 1 | menu "Console" |
Hung-Te Lin | ad173ea | 2013-02-06 21:24:12 +0800 | [diff] [blame] | 2 | |
Nico Huber | f86baf3 | 2019-01-15 00:05:46 +0100 | [diff] [blame] | 3 | config NO_BOOTBLOCK_CONSOLE |
| 4 | bool |
| 5 | |
Gabe Black | fbb11cf | 2013-06-06 00:21:20 -0700 | [diff] [blame] | 6 | config BOOTBLOCK_CONSOLE |
| 7 | bool "Enable early (bootblock) console output." |
Arthur Heymans | 494b031 | 2019-11-28 16:22:06 +0100 | [diff] [blame] | 8 | depends on !NO_BOOTBLOCK_CONSOLE |
Nico Huber | 1d748c5 | 2019-01-13 13:14:04 +0100 | [diff] [blame] | 9 | default y |
Gabe Black | fbb11cf | 2013-06-06 00:21:20 -0700 | [diff] [blame] | 10 | help |
| 11 | Use console during the bootblock if supported |
| 12 | |
Lee Leahy | 049b462 | 2016-07-31 11:53:28 -0700 | [diff] [blame] | 13 | config POSTCAR_CONSOLE |
| 14 | bool "Enable console output during postcar." |
| 15 | depends on POSTCAR_STAGE |
Kyösti Mälkki | 9fc12e0 | 2019-08-09 07:09:48 +0300 | [diff] [blame] | 16 | default y |
Lee Leahy | 049b462 | 2016-07-31 11:53:28 -0700 | [diff] [blame] | 17 | help |
| 18 | Use console during the postcar if supported |
| 19 | |
Kyösti Mälkki | 361cd81 | 2013-08-12 23:29:57 +0300 | [diff] [blame] | 20 | config SQUELCH_EARLY_SMP |
| 21 | bool "Squelch AP CPUs from early console." |
| 22 | default y |
Lee Leahy | f2ad50f | 2016-02-08 16:19:56 -0800 | [diff] [blame] | 23 | depends on SMP |
Kyösti Mälkki | 361cd81 | 2013-08-12 23:29:57 +0300 | [diff] [blame] | 24 | help |
| 25 | When selected only the BSP CPU will output to early console. |
| 26 | |
| 27 | Console drivers have unpredictable behaviour if multiple threads |
| 28 | attempt to share the same resources without a spinlock. |
| 29 | |
| 30 | If unsure, say Y. |
| 31 | |
Hung-Te Lin | ad173ea | 2013-02-06 21:24:12 +0800 | [diff] [blame] | 32 | config CONSOLE_SERIAL |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 33 | bool "Serial port console output" |
Stefan Reinauer | 509f772 | 2012-12-07 17:31:37 -0800 | [diff] [blame] | 34 | default y |
Nico Huber | 755db95 | 2018-11-11 01:42:17 +0100 | [diff] [blame] | 35 | depends on DRIVERS_UART |
Stefan Reinauer | 509f772 | 2012-12-07 17:31:37 -0800 | [diff] [blame] | 36 | help |
Kyösti Mälkki | afa7b13 | 2014-02-13 17:16:22 +0200 | [diff] [blame] | 37 | Send coreboot debug output to a serial port. |
David Hendricks | 6a503b6 | 2012-12-31 17:28:43 -0800 | [diff] [blame] | 38 | |
Kyösti Mälkki | afa7b13 | 2014-02-13 17:16:22 +0200 | [diff] [blame] | 39 | The type of serial port driver selected based on your configuration is |
| 40 | shown on the following menu line. Supporting multiple different types |
| 41 | of UARTs in one build is not supported. |
Stefan Reinauer | 4885daa | 2011-04-26 23:47:04 +0000 | [diff] [blame] | 42 | |
Nico Huber | da8c12b | 2019-01-11 10:38:02 +0100 | [diff] [blame] | 43 | config FIXED_UART_FOR_CONSOLE |
| 44 | bool |
| 45 | help |
| 46 | Select to remove the prompt from UART_FOR_CONSOLE in case a |
| 47 | specific UART has to be used (e.g. when the platform code |
| 48 | performs dangerous configurations). |
| 49 | |
Raul E Rangel | 6ec3dd2 | 2022-01-21 13:34:21 -0700 | [diff] [blame] | 50 | if CONSOLE_SERIAL || CONSOLE_CBMEM_DUMP_TO_UART |
Patrick Georgi | 0588d19 | 2009-08-12 15:00:51 +0000 | [diff] [blame] | 51 | |
Kyösti Mälkki | afa7b13 | 2014-02-13 17:16:22 +0200 | [diff] [blame] | 52 | comment "I/O mapped, 8250-compatible" |
| 53 | depends on DRIVERS_UART_8250IO |
| 54 | |
| 55 | comment "memory mapped, 8250-compatible" |
| 56 | depends on DRIVERS_UART_8250MEM |
| 57 | |
| 58 | comment "device-specific UART" |
Hung-Te Lin | ad173ea | 2013-02-06 21:24:12 +0800 | [diff] [blame] | 59 | depends on HAVE_UART_SPECIAL |
Stefan Reinauer | 509f772 | 2012-12-07 17:31:37 -0800 | [diff] [blame] | 60 | |
Bryant Ou | 0ee920b | 2020-09-14 23:41:41 -0700 | [diff] [blame] | 61 | config OVERRIDE_UART_FOR_CONSOLE |
| 62 | bool |
| 63 | help |
| 64 | Set to "y" when the platform overrides the index of uart port by providing |
| 65 | a get_uart_for_console routine. |
| 66 | |
| 67 | if !OVERRIDE_UART_FOR_CONSOLE |
| 68 | |
Kyösti Mälkki | 70342a7 | 2014-03-14 22:28:29 +0200 | [diff] [blame] | 69 | config UART_FOR_CONSOLE |
Nico Huber | a96e66a | 2018-11-11 02:51:14 +0100 | [diff] [blame] | 70 | int |
| 71 | prompt "Index for UART port to use for console" if !FIXED_UART_FOR_CONSOLE |
Kyösti Mälkki | 70342a7 | 2014-03-14 22:28:29 +0200 | [diff] [blame] | 72 | default 0 |
Martin Roth | ac76ed9 | 2015-11-19 11:40:43 -0700 | [diff] [blame] | 73 | help |
| 74 | Select an I/O port to use for serial console: |
| 75 | 0 = 0x3f8, 1 = 0x2f8, 2 = 0x3e8, 3 = 0x2e8 |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 76 | |
Kyösti Mälkki | 70342a7 | 2014-03-14 22:28:29 +0200 | [diff] [blame] | 77 | # FIXME: Early programming in romstage is incorrect as we should |
| 78 | # program different LDN to actually change the physical port. |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 79 | config TTYS0_BASE |
| 80 | hex |
Gabe Black | 77ffa0d | 2013-09-30 21:25:49 -0700 | [diff] [blame] | 81 | depends on DRIVERS_UART |
Kyösti Mälkki | 70342a7 | 2014-03-14 22:28:29 +0200 | [diff] [blame] | 82 | default 0x3f8 if UART_FOR_CONSOLE = 0 |
| 83 | default 0x2f8 if UART_FOR_CONSOLE = 1 |
| 84 | default 0x3e8 if UART_FOR_CONSOLE = 2 |
| 85 | default 0x2e8 if UART_FOR_CONSOLE = 3 |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 86 | help |
Kyösti Mälkki | 70342a7 | 2014-03-14 22:28:29 +0200 | [diff] [blame] | 87 | Map the COM port number to the respective I/O port. |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 88 | |
Martin Roth | ac76ed9 | 2015-11-19 11:40:43 -0700 | [diff] [blame] | 89 | comment "Serial port base address = 0x3f8" |
Martin Roth | 3c2e287 | 2019-07-11 12:54:12 -0600 | [diff] [blame] | 90 | depends on DRIVERS_UART_8250IO && UART_FOR_CONSOLE = 0 |
Martin Roth | ac76ed9 | 2015-11-19 11:40:43 -0700 | [diff] [blame] | 91 | comment "Serial port base address = 0x2f8" |
Martin Roth | 3c2e287 | 2019-07-11 12:54:12 -0600 | [diff] [blame] | 92 | depends on DRIVERS_UART_8250IO && UART_FOR_CONSOLE = 1 |
Martin Roth | ac76ed9 | 2015-11-19 11:40:43 -0700 | [diff] [blame] | 93 | comment "Serial port base address = 0x3e8" |
Martin Roth | 3c2e287 | 2019-07-11 12:54:12 -0600 | [diff] [blame] | 94 | depends on DRIVERS_UART_8250IO && UART_FOR_CONSOLE = 2 |
Martin Roth | ac76ed9 | 2015-11-19 11:40:43 -0700 | [diff] [blame] | 95 | comment "Serial port base address = 0x2e8" |
Martin Roth | 3c2e287 | 2019-07-11 12:54:12 -0600 | [diff] [blame] | 96 | depends on DRIVERS_UART_8250IO && UART_FOR_CONSOLE = 3 |
Martin Roth | ac76ed9 | 2015-11-19 11:40:43 -0700 | [diff] [blame] | 97 | |
Bryant Ou | 0ee920b | 2020-09-14 23:41:41 -0700 | [diff] [blame] | 98 | endif |
| 99 | |
Julien Viard de Galbert | 235daa4 | 2018-02-20 11:45:48 +0100 | [diff] [blame] | 100 | config UART_OVERRIDE_BAUDRATE |
Patrick Georgi | 0bb8346 | 2019-11-22 20:58:58 +0100 | [diff] [blame] | 101 | bool |
Julien Viard de Galbert | 235daa4 | 2018-02-20 11:45:48 +0100 | [diff] [blame] | 102 | help |
| 103 | Set to "y" when the platform overrides the baudrate by providing |
| 104 | a get_uart_baudrate routine. |
| 105 | |
| 106 | if !UART_OVERRIDE_BAUDRATE |
| 107 | |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 108 | choice |
Uwe Hermann | a081a3b | 2009-10-26 23:52:34 +0000 | [diff] [blame] | 109 | prompt "Baud rate" |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 110 | default CONSOLE_SERIAL_115200 |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 111 | |
Lee Leahy | cda71b8 | 2016-02-20 05:39:10 -0800 | [diff] [blame] | 112 | config CONSOLE_SERIAL_921600 |
| 113 | bool "921600" |
| 114 | help |
| 115 | Set serial port Baud rate to 921600. |
| 116 | config CONSOLE_SERIAL_460800 |
| 117 | bool "460800" |
| 118 | help |
| 119 | Set serial port Baud rate to 460800. |
| 120 | config CONSOLE_SERIAL_230400 |
| 121 | bool "230400" |
| 122 | help |
| 123 | Set serial port Baud rate to 230400. |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 124 | config CONSOLE_SERIAL_115200 |
| 125 | bool "115200" |
| 126 | help |
Uwe Hermann | a081a3b | 2009-10-26 23:52:34 +0000 | [diff] [blame] | 127 | Set serial port Baud rate to 115200. |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 128 | config CONSOLE_SERIAL_57600 |
| 129 | bool "57600" |
| 130 | help |
Uwe Hermann | a081a3b | 2009-10-26 23:52:34 +0000 | [diff] [blame] | 131 | Set serial port Baud rate to 57600. |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 132 | config CONSOLE_SERIAL_38400 |
| 133 | bool "38400" |
| 134 | help |
Uwe Hermann | a081a3b | 2009-10-26 23:52:34 +0000 | [diff] [blame] | 135 | Set serial port Baud rate to 38400. |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 136 | config CONSOLE_SERIAL_19200 |
| 137 | bool "19200" |
| 138 | help |
Uwe Hermann | a081a3b | 2009-10-26 23:52:34 +0000 | [diff] [blame] | 139 | Set serial port Baud rate to 19200. |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 140 | config CONSOLE_SERIAL_9600 |
| 141 | bool "9600" |
| 142 | help |
Uwe Hermann | a081a3b | 2009-10-26 23:52:34 +0000 | [diff] [blame] | 143 | Set serial port Baud rate to 9600. |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 144 | |
| 145 | endchoice |
Patrick Georgi | 0588d19 | 2009-08-12 15:00:51 +0000 | [diff] [blame] | 146 | |
Stefan Reinauer | 509f772 | 2012-12-07 17:31:37 -0800 | [diff] [blame] | 147 | #FIXME(dhendrix): Change name to SERIAL_BAUD? (Stefan sayz: yes!!) |
Patrick Georgi | 0588d19 | 2009-08-12 15:00:51 +0000 | [diff] [blame] | 148 | config TTYS0_BAUD |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 149 | int |
Lee Leahy | cda71b8 | 2016-02-20 05:39:10 -0800 | [diff] [blame] | 150 | default 921600 if CONSOLE_SERIAL_921600 |
| 151 | default 460800 if CONSOLE_SERIAL_460800 |
| 152 | default 230400 if CONSOLE_SERIAL_230400 |
Uwe Hermann | d12b703 | 2009-10-16 22:39:55 +0000 | [diff] [blame] | 153 | default 115200 if CONSOLE_SERIAL_115200 |
| 154 | default 57600 if CONSOLE_SERIAL_57600 |
| 155 | default 38400 if CONSOLE_SERIAL_38400 |
| 156 | default 19200 if CONSOLE_SERIAL_19200 |
| 157 | default 9600 if CONSOLE_SERIAL_9600 |
| 158 | help |
Uwe Hermann | a081a3b | 2009-10-26 23:52:34 +0000 | [diff] [blame] | 159 | Map the Baud rates to an integer. |
Patrick Georgi | 0588d19 | 2009-08-12 15:00:51 +0000 | [diff] [blame] | 160 | |
Julien Viard de Galbert | 235daa4 | 2018-02-20 11:45:48 +0100 | [diff] [blame] | 161 | endif |
| 162 | |
Uwe Hermann | 168b11b | 2009-10-07 16:15:40 +0000 | [diff] [blame] | 163 | # TODO: Allow user-friendly selection of settings other than 8n1. |
Patrick Georgi | 0e9a925 | 2009-10-06 20:48:07 +0000 | [diff] [blame] | 164 | config TTYS0_LCS |
| 165 | int |
| 166 | default 3 |
Kyösti Mälkki | afa7b13 | 2014-02-13 17:16:22 +0200 | [diff] [blame] | 167 | depends on DRIVERS_UART_8250IO || DRIVERS_UART_8250MEM |
| 168 | |
| 169 | endif # CONSOLE_SERIAL |
Patrick Georgi | 0e9a925 | 2009-10-06 20:48:07 +0000 | [diff] [blame] | 170 | |
Vladimir Serbinenko | 45988da | 2013-03-30 02:02:13 +0100 | [diff] [blame] | 171 | config SPKMODEM |
| 172 | bool "spkmodem (console on speaker) console output" |
| 173 | default n |
Vladimir Serbinenko | d51a089 | 2016-03-04 09:20:20 +0100 | [diff] [blame] | 174 | depends on ARCH_X86 |
Vladimir Serbinenko | 45988da | 2013-03-30 02:02:13 +0100 | [diff] [blame] | 175 | help |
| 176 | Send coreboot debug output through speaker |
| 177 | |
Kyösti Mälkki | ab94bbf | 2014-02-25 12:06:14 +0200 | [diff] [blame] | 178 | config CONSOLE_USB |
| 179 | bool "USB dongle console output" |
| 180 | depends on USBDEBUG |
Nico Huber | 06125eb | 2018-10-03 12:02:09 +0200 | [diff] [blame] | 181 | default y |
Uwe Hermann | 168b11b | 2009-10-07 16:15:40 +0000 | [diff] [blame] | 182 | help |
Kyösti Mälkki | ab94bbf | 2014-02-25 12:06:14 +0200 | [diff] [blame] | 183 | Send coreboot debug output to USB. |
Uwe Hermann | 168b11b | 2009-10-07 16:15:40 +0000 | [diff] [blame] | 184 | |
Kyösti Mälkki | ab94bbf | 2014-02-25 12:06:14 +0200 | [diff] [blame] | 185 | Configuration for USB hardware is under menu Generic Drivers. |
Kyösti Mälkki | d2dac0a | 2013-08-23 23:33:16 +0300 | [diff] [blame] | 186 | |
Uwe Hermann | 168b11b | 2009-10-07 16:15:40 +0000 | [diff] [blame] | 187 | # TODO: Deps? |
| 188 | # TODO: Improve description. |
Rudolf Marek | 4aa93cc | 2010-07-16 20:02:09 +0000 | [diff] [blame] | 189 | config CONSOLE_NE2K |
| 190 | bool "Network console over NE2000 compatible Ethernet adapter" |
| 191 | default n |
Vladimir Serbinenko | d51a089 | 2016-03-04 09:20:20 +0100 | [diff] [blame] | 192 | depends on PCI |
Rudolf Marek | 4aa93cc | 2010-07-16 20:02:09 +0000 | [diff] [blame] | 193 | help |
| 194 | Send coreboot debug output to a Ethernet console, it works |
| 195 | same way as Linux netconsole, packets are received to UDP |
Martin Roth | 0949e73 | 2021-10-01 14:28:22 -0600 | [diff] [blame] | 196 | port 6666 on IP/MAC specified with options below. |
Rudolf Marek | 4aa93cc | 2010-07-16 20:02:09 +0000 | [diff] [blame] | 197 | Use following netcat command: nc -u -l -p 6666 |
| 198 | |
| 199 | config CONSOLE_NE2K_DST_MAC |
| 200 | depends on CONSOLE_NE2K |
| 201 | string "Destination MAC address of remote system" |
| 202 | default "00:13:d4:76:a2:ac" |
| 203 | help |
| 204 | Type in either MAC address of logging system or MAC address |
| 205 | of the router. |
| 206 | |
| 207 | config CONSOLE_NE2K_DST_IP |
| 208 | depends on CONSOLE_NE2K |
| 209 | string "Destination IP of logging system" |
| 210 | default "10.0.1.27" |
| 211 | help |
Daniele Forsi | 53847a2 | 2014-07-22 18:00:56 +0200 | [diff] [blame] | 212 | This is IP address of the system running for example |
Rudolf Marek | 4aa93cc | 2010-07-16 20:02:09 +0000 | [diff] [blame] | 213 | netcat command to dump the packets. |
| 214 | |
| 215 | config CONSOLE_NE2K_SRC_IP |
| 216 | depends on CONSOLE_NE2K |
Stefan Reinauer | d6b4f1c | 2010-09-23 18:29:40 +0000 | [diff] [blame] | 217 | string "IP address of coreboot system" |
Rudolf Marek | 4aa93cc | 2010-07-16 20:02:09 +0000 | [diff] [blame] | 218 | default "10.0.1.253" |
| 219 | help |
Stefan Reinauer | d6b4f1c | 2010-09-23 18:29:40 +0000 | [diff] [blame] | 220 | This is the IP of the coreboot system |
Rudolf Marek | 4aa93cc | 2010-07-16 20:02:09 +0000 | [diff] [blame] | 221 | |
| 222 | config CONSOLE_NE2K_IO_PORT |
| 223 | depends on CONSOLE_NE2K |
| 224 | hex "NE2000 adapter fixed IO port address" |
| 225 | default 0xe00 |
| 226 | help |
| 227 | This is the IO port address for the IO port |
| 228 | on the card, please select some non-conflicting region, |
| 229 | 32 bytes of IO spaces will be used (and align on 32 bytes |
| 230 | boundary, qemu needs broader align) |
| 231 | |
Vadim Bendebury | c34b463 | 2011-09-28 13:51:30 -0700 | [diff] [blame] | 232 | config CONSOLE_CBMEM |
Vadim Bendebury | c34b463 | 2011-09-28 13:51:30 -0700 | [diff] [blame] | 233 | bool "Send console output to a CBMEM buffer" |
Paul Menzel | 60ef456 | 2014-03-08 10:46:52 +0100 | [diff] [blame] | 234 | default y |
Vadim Bendebury | c34b463 | 2011-09-28 13:51:30 -0700 | [diff] [blame] | 235 | help |
| 236 | Enable this to save the console output in a CBMEM buffer. This would |
| 237 | allow to see coreboot console output from Linux space. |
| 238 | |
Kyösti Mälkki | 8659e40 | 2014-12-21 08:55:47 +0200 | [diff] [blame] | 239 | if CONSOLE_CBMEM |
| 240 | |
Vadim Bendebury | c34b463 | 2011-09-28 13:51:30 -0700 | [diff] [blame] | 241 | config CONSOLE_CBMEM_BUFFER_SIZE |
Vadim Bendebury | c34b463 | 2011-09-28 13:51:30 -0700 | [diff] [blame] | 242 | hex "Room allocated for console output in CBMEM" |
Vladimir Serbinenko | eb67a04 | 2014-09-13 20:55:58 +0200 | [diff] [blame] | 243 | default 0x20000 |
Vadim Bendebury | c34b463 | 2011-09-28 13:51:30 -0700 | [diff] [blame] | 244 | help |
| 245 | Space allocated for console output storage in CBMEM. The default |
Vladimir Serbinenko | eb67a04 | 2014-09-13 20:55:58 +0200 | [diff] [blame] | 246 | value (128K or 0x20000 bytes) is large enough to accommodate |
Vadim Bendebury | c34b463 | 2011-09-28 13:51:30 -0700 | [diff] [blame] | 247 | even the BIOS_SPEW level. |
| 248 | |
Vadim Bendebury | 6e20e2f | 2015-04-10 18:04:04 -0700 | [diff] [blame] | 249 | config CONSOLE_CBMEM_DUMP_TO_UART |
| 250 | depends on !CONSOLE_SERIAL |
| 251 | bool "Dump CBMEM console on resets" |
| 252 | default n |
| 253 | help |
| 254 | Enable this to have CBMEM console buffer contents dumped on the |
| 255 | serial output in case serial console is disabled and the device |
| 256 | resets itself while trying to boot the payload. |
| 257 | |
Raul E Rangel | 80a7f4e | 2022-01-11 12:54:36 -0700 | [diff] [blame] | 258 | config CONSOLE_CBMEM_PRINT_PRE_BOOTBLOCK_CONTENTS |
| 259 | bool |
| 260 | help |
| 261 | Pre-bootblock stages (i.e., VBOOT_STARTS_BEFORE_BOOTBLOCK) might not |
| 262 | have the ability to log to the UART, so their console messages are |
| 263 | inaccessible until the boot processes gets into the payload or OS. |
| 264 | This feature will dump the pre-bootblock CBMEM console immediately |
| 265 | after the bootblock console is initialized. |
Kyösti Mälkki | 8659e40 | 2014-12-21 08:55:47 +0200 | [diff] [blame] | 266 | endif |
| 267 | |
Youness Alaoui | c4b4ff3 | 2017-05-11 10:36:29 -0400 | [diff] [blame] | 268 | config CONSOLE_SPI_FLASH |
| 269 | bool "SPI Flash console output" |
| 270 | default n |
Arthur Heymans | 6e8abc4 | 2021-04-30 16:00:38 +0200 | [diff] [blame] | 271 | depends on BOOT_DEVICE_SPI_FLASH |
Youness Alaoui | c4b4ff3 | 2017-05-11 10:36:29 -0400 | [diff] [blame] | 272 | select BOOT_DEVICE_SPI_FLASH_RW_NOMMAP_EARLY if !COMMON_CBFS_SPI_WRAPPER |
| 273 | help |
| 274 | Send coreboot debug output to the SPI Flash in the FMAP CONSOLE area |
| 275 | |
| 276 | This option can cause premature wear on the SPI flash and should not |
| 277 | be used as a normal means of debugging. It is only to be enabled and |
| 278 | used when porting a new motherboard which has no other console |
| 279 | available (no UART, no POST, no cbmem access(non bootable)). Since |
| 280 | a non bootable machine will require the use of an external SPI Flash |
| 281 | programmer, the developer can grab the console log at the same time. |
| 282 | |
| 283 | The flash console will not be erased on reboot, so once it is full, |
| 284 | the flashconsole driver will stop writing to it. This is to avoid |
| 285 | wear on the flash, and to avoid erasing sectors (which may freeze |
| 286 | the SPI controller on skylake). |
| 287 | |
| 288 | The 'CONSOLE' area can be extracted from the FMAP with : |
| 289 | cbfstool rom.bin read -r CONSOLE -f console.log |
| 290 | |
| 291 | config CONSOLE_SPI_FLASH_BUFFER_SIZE |
| 292 | hex "Room allocated for console output in FMAP" |
| 293 | default 0x20000 |
| 294 | depends on CONSOLE_SPI_FLASH |
| 295 | help |
| 296 | Space allocated for console output storage in FMAP. The default |
| 297 | value (128K or 0x20000 bytes) is large enough to accommodate |
| 298 | even the BIOS_SPEW level. |
| 299 | |
Husni Faiz | 67300f8 | 2022-09-05 15:23:15 +0530 | [diff] [blame] | 300 | config CONSOLE_I2C_SMBUS |
| 301 | bool "SMBus console output" |
| 302 | depends on SOUTHBRIDGE_INTEL_COMMON_SMBUS |
| 303 | help |
| 304 | Send coreboot debug output to the SMBus. |
| 305 | The output can be read with an I2C slave device connected |
| 306 | the SMBus. Please refer to the technotes section of the |
| 307 | coreboot documentation for more details. |
| 308 | |
| 309 | if CONSOLE_I2C_SMBUS |
| 310 | comment "Set logging device address and data register address" |
| 311 | |
| 312 | config CONSOLE_I2C_SMBUS_SLAVE_ADDRESS |
| 313 | hex "I2C slave address of the logging device" |
Husni Faiz | b80535a | 2022-09-09 17:49:53 +0530 | [diff] [blame] | 314 | default 0x48 if SC16IS7XX_INIT |
Husni Faiz | 67300f8 | 2022-09-05 15:23:15 +0530 | [diff] [blame] | 315 | help |
| 316 | I2C address of the device which logs the data. |
| 317 | |
| 318 | config CONSOLE_I2C_SMBUS_SLAVE_DATA_REGISTER |
| 319 | hex "Data register address of the I2C logging device" |
Husni Faiz | b80535a | 2022-09-09 17:49:53 +0530 | [diff] [blame] | 320 | default 0x00 if SC16IS7XX_INIT |
Husni Faiz | 67300f8 | 2022-09-05 15:23:15 +0530 | [diff] [blame] | 321 | help |
| 322 | This an 8-bit data register. |
| 323 | |
Husni Faiz | b80535a | 2022-09-09 17:49:53 +0530 | [diff] [blame] | 324 | config SC16IS7XX_INIT |
| 325 | bool "Initialize SC16IS7XX I2C to UART converter chip" |
| 326 | help |
| 327 | SC16IS7XX is a slave I2C to UART converter chip. Enabling |
| 328 | this option will initialize the chip. |
| 329 | |
| 330 | The default I2C slave address value 0x48 is the address of |
| 331 | SC16IS7XX I2C to UART converter chip when the A1 and A0 pins |
| 332 | are set to Vcc. |
| 333 | |
| 334 | The default data register address value 0x00 is the data |
| 335 | register address of SC16IS7XX I2C to UART converter chip. |
| 336 | |
Husni Faiz | 67300f8 | 2022-09-05 15:23:15 +0530 | [diff] [blame] | 337 | endif # CONSOLE_I2C_SMBUS |
| 338 | |
Gerd Hoffmann | d7c6e44 | 2013-05-30 10:32:31 +0200 | [diff] [blame] | 339 | config CONSOLE_QEMU_DEBUGCON |
Gerd Hoffmann | 038aa29 | 2013-05-29 13:06:22 +0200 | [diff] [blame] | 340 | bool "QEMU debug console output" |
Angel Pons | d615230 | 2020-03-01 14:46:38 +0100 | [diff] [blame] | 341 | depends on CPU_QEMU_X86 |
Gerd Hoffmann | 038aa29 | 2013-05-29 13:06:22 +0200 | [diff] [blame] | 342 | default y |
| 343 | help |
| 344 | Send coreboot debug output to QEMU's isa-debugcon device: |
| 345 | |
| 346 | qemu-system-x86_64 \ |
| 347 | -chardev file,id=debugcon,path=/dir/file.log \ |
| 348 | -device isa-debugcon,iobase=0x402,chardev=debugcon |
| 349 | |
Gerd Hoffmann | d7c6e44 | 2013-05-30 10:32:31 +0200 | [diff] [blame] | 350 | config CONSOLE_QEMU_DEBUGCON_PORT |
Gerd Hoffmann | 038aa29 | 2013-05-29 13:06:22 +0200 | [diff] [blame] | 351 | hex "QEMU debug console port" |
Gerd Hoffmann | d7c6e44 | 2013-05-30 10:32:31 +0200 | [diff] [blame] | 352 | depends on CONSOLE_QEMU_DEBUGCON |
Gerd Hoffmann | 038aa29 | 2013-05-29 13:06:22 +0200 | [diff] [blame] | 353 | default 0x402 |
| 354 | |
Angel Pons | 12d48cd | 2020-10-03 12:22:04 +0200 | [diff] [blame] | 355 | config EM100PRO_SPI_CONSOLE |
| 356 | bool "EM100Pro SPI debug console output" |
| 357 | depends on HAVE_EM100PRO_SPI_CONSOLE_SUPPORT && !DEBUG_SPI_FLASH |
Martin Roth | 3a54318 | 2015-09-28 15:27:24 -0600 | [diff] [blame] | 358 | help |
| 359 | Enable support for the debug console on the Dediprog EM100Pro. |
| 360 | This is currently working only in ramstage due to how the spi |
| 361 | drivers are written. |
| 362 | |
Jeremy Soller | 52785ab | 2020-07-22 06:40:28 -0600 | [diff] [blame] | 363 | config CONSOLE_SYSTEM76_EC |
| 364 | bool "System76 EC console output" |
| 365 | default n |
| 366 | depends on EC_SYSTEM76_EC |
| 367 | help |
| 368 | Send coreboot debug output to a System76 embedded controller. |
| 369 | |
Fred Reitberger | a02176d | 2023-02-01 16:00:54 -0500 | [diff] [blame] | 370 | config CONSOLE_AMD_SIMNOW |
| 371 | bool "AMD SimNow console output" |
| 372 | default n |
| 373 | depends on SOC_AMD_COMMON && !POST_IO |
| 374 | select CONSOLE_POST |
| 375 | help |
| 376 | Send coreboot debug output to IO ports for SimNow |
| 377 | |
Julien Viard de Galbert | 4ecd42f | 2018-02-20 15:01:27 +0100 | [diff] [blame] | 378 | config CONSOLE_OVERRIDE_LOGLEVEL |
Patrick Georgi | 0bb8346 | 2019-11-22 20:58:58 +0100 | [diff] [blame] | 379 | bool |
Julien Viard de Galbert | 4ecd42f | 2018-02-20 15:01:27 +0100 | [diff] [blame] | 380 | help |
| 381 | Set to "y" when the platform overrides the loglevel by providing |
| 382 | a get_console_loglevel routine. |
| 383 | |
| 384 | if !CONSOLE_OVERRIDE_LOGLEVEL |
| 385 | |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 386 | choice |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 387 | prompt "Default console log level" |
Julius Werner | e64a585 | 2018-10-15 17:19:58 -0700 | [diff] [blame] | 388 | default DEFAULT_CONSOLE_LOGLEVEL_8 if CHROMEOS |
Nico Huber | 715a502 | 2018-05-04 12:04:00 +0200 | [diff] [blame] | 389 | default DEFAULT_CONSOLE_LOGLEVEL_7 |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 390 | |
| 391 | config DEFAULT_CONSOLE_LOGLEVEL_8 |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 392 | bool "8: SPEW" |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 393 | help |
| 394 | Way too many details. |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 395 | config DEFAULT_CONSOLE_LOGLEVEL_7 |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 396 | bool "7: DEBUG" |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 397 | help |
| 398 | Debug-level messages. |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 399 | config DEFAULT_CONSOLE_LOGLEVEL_6 |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 400 | bool "6: INFO" |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 401 | help |
| 402 | Informational messages. |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 403 | config DEFAULT_CONSOLE_LOGLEVEL_5 |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 404 | bool "5: NOTICE" |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 405 | help |
| 406 | Normal but significant conditions. |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 407 | config DEFAULT_CONSOLE_LOGLEVEL_4 |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 408 | bool "4: WARNING" |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 409 | help |
| 410 | Warning conditions. |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 411 | config DEFAULT_CONSOLE_LOGLEVEL_3 |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 412 | bool "3: ERR" |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 413 | help |
| 414 | Error conditions. |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 415 | config DEFAULT_CONSOLE_LOGLEVEL_2 |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 416 | bool "2: CRIT" |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 417 | help |
| 418 | Critical conditions. |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 419 | config DEFAULT_CONSOLE_LOGLEVEL_1 |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 420 | bool "1: ALERT" |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 421 | help |
| 422 | Action must be taken immediately. |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 423 | config DEFAULT_CONSOLE_LOGLEVEL_0 |
Myles Watson | 0364618 | 2009-10-16 19:29:45 +0000 | [diff] [blame] | 424 | bool "0: EMERG" |
| 425 | help |
| 426 | System is unusable. |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 427 | |
| 428 | endchoice |
| 429 | |
Patrick Georgi | 0588d19 | 2009-08-12 15:00:51 +0000 | [diff] [blame] | 430 | config DEFAULT_CONSOLE_LOGLEVEL |
Uwe Hermann | 7fe4191 | 2009-10-11 13:35:24 +0000 | [diff] [blame] | 431 | int |
| 432 | default 0 if DEFAULT_CONSOLE_LOGLEVEL_0 |
| 433 | default 1 if DEFAULT_CONSOLE_LOGLEVEL_1 |
| 434 | default 2 if DEFAULT_CONSOLE_LOGLEVEL_2 |
| 435 | default 3 if DEFAULT_CONSOLE_LOGLEVEL_3 |
| 436 | default 4 if DEFAULT_CONSOLE_LOGLEVEL_4 |
| 437 | default 5 if DEFAULT_CONSOLE_LOGLEVEL_5 |
| 438 | default 6 if DEFAULT_CONSOLE_LOGLEVEL_6 |
| 439 | default 7 if DEFAULT_CONSOLE_LOGLEVEL_7 |
| 440 | default 8 if DEFAULT_CONSOLE_LOGLEVEL_8 |
| 441 | help |
| 442 | Map the log level config names to an integer. |
Patrick Georgi | 0588d19 | 2009-08-12 15:00:51 +0000 | [diff] [blame] | 443 | |
Julien Viard de Galbert | 4ecd42f | 2018-02-20 15:01:27 +0100 | [diff] [blame] | 444 | endif |
| 445 | |
Igor Bagnucki | f0d6521 | 2022-03-03 11:41:57 +0100 | [diff] [blame] | 446 | config CONSOLE_USE_LOGLEVEL_PREFIX |
| 447 | bool "Use loglevel prefix to indicate line loglevel" |
| 448 | default y |
| 449 | help |
| 450 | When enabled, if the code contains a: |
| 451 | `printk(BIOS_DEBUG, "This is a debug message!\n")`, |
| 452 | it will show up as: |
| 453 | `[DEBUG] This is a debug message!` |
| 454 | |
Julius Werner | a120e0d | 2022-01-21 15:24:12 -0800 | [diff] [blame] | 455 | config CONSOLE_USE_ANSI_ESCAPES |
| 456 | bool "Use ANSI escape sequences for console highlighting" |
Zheng Bao | ddf8d19 | 2023-03-29 10:39:32 +0800 | [diff] [blame] | 457 | default y if !CONSOLE_AMD_SIMNOW |
Julius Werner | a120e0d | 2022-01-21 15:24:12 -0800 | [diff] [blame] | 458 | help |
| 459 | If enabled, certain consoles (e.g. UART) that are meant to be read on |
| 460 | a terminal will use ANSI escape sequences (like `ESC [1m`) to |
| 461 | highlight lines based on their log level. Disable this if your |
| 462 | terminal does not support ANSI escape sequences. |
| 463 | |
Stefan Reinauer | c719f1a | 2010-03-30 09:57:28 +0000 | [diff] [blame] | 464 | config NO_POST |
| 465 | bool "Don't show any POST codes" |
| 466 | default n |
| 467 | |
Duncan Laurie | b6e97b1 | 2012-09-09 19:09:56 -0700 | [diff] [blame] | 468 | config CMOS_POST |
| 469 | bool "Store post codes in CMOS for debugging" |
Stefan Reinauer | c2d5a16 | 2012-12-06 14:25:27 -0800 | [diff] [blame] | 470 | depends on !NO_POST && PC80_SYSTEM |
Duncan Laurie | b6e97b1 | 2012-09-09 19:09:56 -0700 | [diff] [blame] | 471 | default n |
| 472 | help |
| 473 | If enabled, coreboot will store post codes in CMOS and switch between |
| 474 | two offsets on each boot so the last post code in the previous boot |
| 475 | can be retrieved. This uses 3 bytes of CMOS. |
| 476 | |
| 477 | config CMOS_POST_OFFSET |
| 478 | hex "Offset into CMOS to store POST codes" |
| 479 | depends on CMOS_POST |
Martin Roth | 3b87812 | 2016-09-30 14:43:01 -0600 | [diff] [blame] | 480 | default 0x0 |
Duncan Laurie | b6e97b1 | 2012-09-09 19:09:56 -0700 | [diff] [blame] | 481 | help |
| 482 | If CMOS_POST is enabled then an offset into CMOS must be provided. |
| 483 | If CONFIG_HAVE_OPTION_TABLE is enabled then it will use the value |
| 484 | defined in the mainboard option table. |
| 485 | |
Daniele Forsi | ad488d2 | 2014-07-30 12:23:35 +0200 | [diff] [blame] | 486 | config CONSOLE_POST |
Idwer Vollering | 5809a73 | 2014-03-11 15:36:21 +0000 | [diff] [blame] | 487 | bool "Show POST codes on the debug console" |
| 488 | depends on !NO_POST |
| 489 | default n |
| 490 | help |
| 491 | If enabled, coreboot will additionally print POST codes (which are |
| 492 | usually displayed using a so-called "POST card" ISA/PCI/PCI-E |
| 493 | device) on the debug console. |
| 494 | |
| 495 | config POST_DEVICE |
| 496 | bool "Send POST codes to an external device" |
| 497 | depends on !NO_POST |
| 498 | default y |
| 499 | |
| 500 | choice |
| 501 | prompt "Device to send POST codes to" |
| 502 | depends on POST_DEVICE |
Kyösti Mälkki | 657d68b | 2019-12-03 12:36:09 +0200 | [diff] [blame] | 503 | default POST_DEVICE_LPC if DEFAULT_POST_ON_LPC |
Idwer Vollering | 5809a73 | 2014-03-11 15:36:21 +0000 | [diff] [blame] | 504 | default POST_DEVICE_NONE |
| 505 | |
| 506 | config POST_DEVICE_NONE |
| 507 | bool "None" |
| 508 | config POST_DEVICE_LPC |
| 509 | bool "LPC" |
Vladimir Serbinenko | d51a089 | 2016-03-04 09:20:20 +0100 | [diff] [blame] | 510 | depends on PCI |
Idwer Vollering | 5809a73 | 2014-03-11 15:36:21 +0000 | [diff] [blame] | 511 | config POST_DEVICE_PCI_PCIE |
| 512 | bool "PCI/PCIe" |
Vladimir Serbinenko | d51a089 | 2016-03-04 09:20:20 +0100 | [diff] [blame] | 513 | depends on PCI |
Idwer Vollering | 5809a73 | 2014-03-11 15:36:21 +0000 | [diff] [blame] | 514 | endchoice |
| 515 | |
Kyösti Mälkki | 657d68b | 2019-12-03 12:36:09 +0200 | [diff] [blame] | 516 | config DEFAULT_POST_ON_LPC |
| 517 | bool |
| 518 | default n |
| 519 | |
Idwer Vollering | 5809a73 | 2014-03-11 15:36:21 +0000 | [diff] [blame] | 520 | config POST_IO |
David Hendricks | 6b908d0 | 2012-11-05 12:34:09 -0800 | [diff] [blame] | 521 | bool "Send POST codes to an IO port" |
Idwer Vollering | 5809a73 | 2014-03-11 15:36:21 +0000 | [diff] [blame] | 522 | depends on PC80_SYSTEM && !NO_POST |
David Hendricks | 6b908d0 | 2012-11-05 12:34:09 -0800 | [diff] [blame] | 523 | default y |
| 524 | help |
| 525 | If enabled, POST codes will be written to an IO port. |
Stefan Reinauer | c719f1a | 2010-03-30 09:57:28 +0000 | [diff] [blame] | 526 | |
Idwer Vollering | 5809a73 | 2014-03-11 15:36:21 +0000 | [diff] [blame] | 527 | config POST_IO_PORT |
| 528 | depends on POST_IO |
David Hendricks | 6b908d0 | 2012-11-05 12:34:09 -0800 | [diff] [blame] | 529 | hex "IO port for POST codes" |
| 530 | default 0x80 |
| 531 | help |
| 532 | POST codes on x86 are typically written to the LPC bus on port |
Daniele Forsi | 53847a2 | 2014-07-22 18:00:56 +0200 | [diff] [blame] | 533 | 0x80. However, it may be desirable to change the port number |
David Hendricks | 6b908d0 | 2012-11-05 12:34:09 -0800 | [diff] [blame] | 534 | depending on the presence of coprocessors/microcontrollers or if the |
| 535 | platform does not support IO in the conventional x86 manner. |
| 536 | |
Martin Roth | 1455437 | 2015-11-12 14:02:42 -0700 | [diff] [blame] | 537 | config NO_EARLY_BOOTBLOCK_POSTCODES |
| 538 | def_bool n |
| 539 | help |
| 540 | Some chipsets require that the routing for the port 80h POST |
Martin Roth | 8a85a84 | 2021-06-21 09:18:46 -0600 | [diff] [blame] | 541 | code be configured before any POST codes are sent out. If this is |
| 542 | not done, the system can hang on the first POST code. This |
| 543 | initialization can be done in the boot block, but there are a couple |
| 544 | of POST codes that go out before the chipset's C bootblock |
| 545 | initialization can happen. This option suppresses all postcodes in |
| 546 | the early assembly code. |
Martin Roth | 1455437 | 2015-11-12 14:02:42 -0700 | [diff] [blame] | 547 | |
Nico Huber | c83239e | 2016-10-05 17:46:49 +0200 | [diff] [blame] | 548 | config HWBASE_DEBUG_CB |
| 549 | bool |
| 550 | default y if DEFAULT_CONSOLE_LOGLEVEL_7 || DEFAULT_CONSOLE_LOGLEVEL_8 |
| 551 | default n |
| 552 | |
| 553 | config HWBASE_DEBUG_NULL |
| 554 | def_bool y |
| 555 | depends on !HWBASE_DEBUG_CB |
| 556 | |
David Hendricks | 6b908d0 | 2012-11-05 12:34:09 -0800 | [diff] [blame] | 557 | endmenu |