blob: f8e176e998c11a487ffc761d8b9c5d118594eaa5 [file] [log] [blame]
Uwe Hermann661e3802008-03-21 18:37:23 +00001##
2## This file is part of the libpayload project.
3##
4## Copyright (C) 2008 Advanced Micro Devices, Inc.
Stefan Reinauer69863582008-08-08 13:45:03 +00005## Copyright (C) 2008 coresystems GmbH
Uwe Hermann661e3802008-03-21 18:37:23 +00006##
7## Redistribution and use in source and binary forms, with or without
8## modification, are permitted provided that the following conditions
9## are met:
10## 1. Redistributions of source code must retain the above copyright
11## notice, this list of conditions and the following disclaimer.
12## 2. Redistributions in binary form must reproduce the above copyright
13## notice, this list of conditions and the following disclaimer in the
14## documentation and/or other materials provided with the distribution.
15## 3. The name of the author may not be used to endorse or promote products
16## derived from this software without specific prior written permission.
17##
18## THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
19## ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20## IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
21## ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
22## FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
23## DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
24## OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
25## HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
26## LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
27## OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
28## SUCH DAMAGE.
29##
Jordan Crousef6145c32008-03-19 23:56:58 +000030
31mainmenu "Libpayload Configuration"
32
Stefan Reinauere5d30b72010-03-25 22:15:19 +000033menu "Generic Options"
34
Julius Werner22adcd62014-06-11 14:16:35 -070035config GPL
36 bool "GPLv2-licensed Options"
Julius Werner58caa8b2016-05-16 16:37:56 -070037 default y if CHROMEOS
Julius Werner22adcd62014-06-11 14:16:35 -070038 default n
39 help
40 Prompt for options that will build code licensed under the GNU General
41 Public License (version 2). This will subject the whole payload to the
42 terms of this license (including its provision to release all sources,
43 please see the LICENSE_GPL file for details).
44
Stefan Reinauere5d30b72010-03-25 22:15:19 +000045config EXPERIMENTAL
46 bool "Experimental Options"
47 default n
48 help
49 Prompt for experimental functionality. Attention: This is not likely
50 to work without problems
51
Stefan Reinauere5d30b72010-03-25 22:15:19 +000052config DEVELOPER
53 bool "Developer Options"
54 default n
55 help
56 Prompt for developer options. These options are only interesting for
57 libpayload developers.
58
Julius Werner58caa8b2016-05-16 16:37:56 -070059config CHROMEOS
60 bool "Chrome OS Options"
61 default n
62 help
63 Select configuration defaults appropriate for Chrome OS boards.
64
Patrick Georgib7d8f262015-07-06 09:04:42 +000065choice
66 prompt "Compiler to use"
67 default COMPILER_GCC
68 help
69 This option allows you to select the compiler.
70
71config COMPILER_GCC
72 bool "GCC"
73 help
74 Use the GNU Compiler Collection (GCC).
75
76config COMPILER_LLVM_CLANG
77 bool "LLVM/clang"
78 help
79 Use LLVM/clang.
80
81endchoice
82
Julius Werner50a81742014-05-15 11:57:38 -070083config REMOTEGDB
84 bool "Remote GDB stub"
85 default n
86 depends on GPL
87 help
88 Enable Remote GDB debugging support.
89
Stefan Reinauer1e6b86b2016-03-12 12:14:46 -080090config MEMMAP_RAM_ONLY
91 bool "Only consider RAM entries in memory map for further processing"
92 default n
93
Stefan Reinauere5d30b72010-03-25 22:15:19 +000094endmenu
95
Jordan Crouse20c9cf12008-10-20 16:51:43 +000096menu "Architecture Options"
97
Patrick Georgid385ed22009-05-21 10:02:52 +000098choice
99 prompt "Target Architecture"
David Hendricks4b6be982012-11-30 13:56:31 -0800100 default ARCH_X86
Patrick Georgid385ed22009-05-21 10:02:52 +0000101
Gabe Black51edd542013-09-30 23:00:33 -0700102config ARCH_ARM
103 bool "ARM"
Stefan Reinauer8af0d032012-12-14 13:05:21 -0800104 help
Gabe Black51edd542013-09-30 23:00:33 -0700105 Support the ARM architecture
Stefan Reinauer8af0d032012-12-14 13:05:21 -0800106
David Hendricks4b6be982012-11-30 13:56:31 -0800107config ARCH_X86
Patrick Georgid385ed22009-05-21 10:02:52 +0000108 bool "x86"
109 help
110 Support the x86 architecture
111
Furquan Shaikh8c8c3772014-02-19 11:35:30 -0800112config ARCH_ARM64
113 bool "ARM64"
114 help
115 Support the ARM64 architecture
116
Patrick Georgid385ed22009-05-21 10:02:52 +0000117endchoice
118
Jordan Crouse20c9cf12008-10-20 16:51:43 +0000119config MULTIBOOT
120 bool "Multiboot header support"
David Hendricks4b6be982012-11-30 13:56:31 -0800121 depends on ARCH_X86
Julius Werner58caa8b2016-05-16 16:37:56 -0700122 default y if !CHROMEOS
Jordan Crouse20c9cf12008-10-20 16:51:43 +0000123
Stefan Reinauer82184452016-03-12 16:18:17 -0800124config HEAP_SIZE
125 int "Heap size"
126 default 131072
127 help
128 This is the heap size (malloc'able size) available
129 to the payload.
130
131 If unsure, set to 131072 (128K)
132
133config STACK_SIZE
134 int "Stack size"
135 default 16384
136 help
137 This is the stack size available to the payload.
138
139 If unsure, set to 16384 (16K)
140
141config BASE_ADDRESS
142 hex "Base address"
143 default 0x04000000 if ARCH_ARM
144 default 0x80100000 if ARCH_ARM64
Stefan Reinauer82184452016-03-12 16:18:17 -0800145 default 0x00100000 if ARCH_X86
146 help
147 This is the base address for the payload.
148
Julius Wernerf96d9052019-08-16 15:35:39 -0700149 If unsure, set to 0x00100000 on x86,
Stefan Reinauer82184452016-03-12 16:18:17 -0800150 0x04000000 on ARM or 0x80100000 on ARM64.
151
Jordan Crouse20c9cf12008-10-20 16:51:43 +0000152endmenu
153
Lee Leahy6796d782017-06-20 14:33:28 -0700154config USE_MARCH_586
155 bool "Use march=586 qualifier to build"
156 default n
157 depends on ARCH_X86
158 help
159 Allow a platform or processor to select to be compiled using
160 the '-march=i586' option instead of the typical '-march=i686'
161
Stefan Reinauer69863582008-08-08 13:45:03 +0000162menu "Standard Libraries"
163
164config LIBC
165 bool "Enable C library support"
166 default y
167
Patrick Georgi3b77b722011-07-07 15:41:53 +0200168config CURSES
169 bool "Build a curses library"
Julius Werner58caa8b2016-05-16 16:37:56 -0700170 default y if !CHROMEOS
Stefan Reinauer69863582008-08-08 13:45:03 +0000171
Patrick Georgi3b77b722011-07-07 15:41:53 +0200172choice
173 prompt "Curses implementation"
174 default PDCURSES
175 depends on CURSES
176
177config TINYCURSES
Paul Menzeldc1b3c12015-09-26 12:30:08 +0200178 bool "TinyCurses"
Patrick Georgi3b77b722011-07-07 15:41:53 +0200179 help
Paul Menzeldc1b3c12015-09-26 12:30:08 +0200180 TinyCurses was the first curses implementation for libpayload.
Patrick Georgi3b77b722011-07-07 15:41:53 +0200181 It features low memory consumption, static allocation of larger
182 data structures (so few or no memory allocation calls) and a
183 reduced feature set.
184
185config PDCURSES
186 bool "PDCurses"
Patrick Georgi3b77b722011-07-07 15:41:53 +0200187 help
188 libpayload's PDCurses port provides a full features curses
189 implementation, including libpanel, libmenu and libform (which
190 are taken from ncurses).
191 It requires more system resources, in particularily heap memory.
192
193endchoice
194
Stefan Reinauere5d30b72010-03-25 22:15:19 +0000195config CBFS
196 bool "CBFS support"
197 default y
198 help
Patrick Georgi6de1ee4a2011-07-21 15:43:14 +0200199 CBFS is the archive format of coreboot
200
201config LZMA
202 bool "LZMA decoder"
203 default y
204 help
205 LZMA decoder implementation, usable eg. by CBFS,
206 but also externally.
Julius Wernerbf273912015-06-30 10:30:30 -0700207
208config LZ4
209 bool "LZ4 decoder"
210 default y
211 help
212 Decoder implementation for the LZ4 compression algorithm.
213 Adds standalone functions (CBFS support coming soon).
Stefan Reinauer69863582008-08-08 13:45:03 +0000214endmenu
215
216menu "Console Options"
Uwe Hermann2d758b82008-03-31 15:21:24 +0000217
Gabe Black4bb07312012-10-05 11:43:39 -0700218config SKIP_CONSOLE_INIT
219 bool "Skip initializing the consoles at startup"
Julius Werner58caa8b2016-05-16 16:37:56 -0700220 default y if CHROMEOS
Gabe Black4bb07312012-10-05 11:43:39 -0700221 default n
222 help
223 Normally, libpayload will initialize console input/output on startup
224 before the payload itself gets control. This option disables that
225 behavior and leaves console initialization up to the payload.
226
Gabe Blacka54b6a62012-09-29 00:21:27 -0700227config CBMEM_CONSOLE
228 bool "Send output to the in memory CBMEM console"
229 default y
230
Jordan Crousef6145c32008-03-19 23:56:58 +0000231config SERIAL_CONSOLE
Uwe Hermann2d758b82008-03-31 15:21:24 +0000232 bool "See output on the serial port console"
233 default y
Jordan Crousef6145c32008-03-19 23:56:58 +0000234
Gabe Black9135cb42013-09-26 16:13:08 -0700235config 8250_SERIAL_CONSOLE
Alexandru Gagniuc4d5317e2015-11-23 16:18:12 -0800236 bool "8250-compatible serial port driver (including IO and MMIO)"
Gabe Black9135cb42013-09-26 16:13:08 -0700237 depends on SERIAL_CONSOLE
Julius Werner58caa8b2016-05-16 16:37:56 -0700238 default y if ARCH_X86
Ronald G. Minnich7b694542013-02-15 08:13:29 -0800239
Gabe Blacka6aecc42014-04-10 01:07:28 -0700240config S5P_SERIAL_CONSOLE
241 bool "Exynos SOC, S5P compatible serial port driver"
242 depends on SERIAL_CONSOLE
243 default n
244
Vadim Bendebury897123a2014-05-27 18:28:59 -0700245config IPQ806X_SERIAL_CONSOLE
246 bool "IPQ806x SOC compatible serial port driver"
247 depends on SERIAL_CONSOLE
248 default n
249
Varadarajan Narayananc1ae7e92016-02-01 11:32:12 +0530250config IPQ40XX_SERIAL_CONSOLE
251 bool "IPQ40xx SOC compatible serial port driver"
252 depends on SERIAL_CONSOLE
253 default n
254
Prudhvi Yarlagadda1b054792019-03-22 12:38:20 +0530255config QCS405_SERIAL_CONSOLE
256 bool "QCS405 SOC compatible serial port driver"
257 depends on SERIAL_CONSOLE
258 default n
259
T Michael Turney45473dd2019-10-10 12:26:15 -0700260config QUALCOMM_QUPV3_SERIAL_CONSOLE
261 bool "Qualcomm QUPV3 serial port driver"
262 depends on SERIAL_CONSOLE
263 default n
264
Marcelo Povoa558e9b52014-02-18 14:17:38 -0800265config PL011_SERIAL_CONSOLE
266 bool "PL011 compatible serial port driver"
267 depends on 8250_SERIAL_CONSOLE
268 default n
269
Jordan Crousef6145c32008-03-19 23:56:58 +0000270config SERIAL_IOBASE
Gabe Black9135cb42013-09-26 16:13:08 -0700271 ## This default is currently not used on non-x86 systems.
272 hex "Default I/O base for the serial port (default 0x3f8)"
273 depends on SERIAL_CONSOLE && ARCH_X86
Uwe Hermann2d758b82008-03-31 15:21:24 +0000274 default 0x3f8
275
Jordan Crousef6145c32008-03-19 23:56:58 +0000276config SERIAL_SET_SPEED
277 bool "Override the serial console baud rate"
278 default n
Uwe Hermannfad8c2b2008-04-11 18:01:50 +0000279 depends on SERIAL_CONSOLE
Jordan Crousef6145c32008-03-19 23:56:58 +0000280
281config SERIAL_BAUD_RATE
282 int "Serial console baud rate (default 115200)"
Uwe Hermannfad8c2b2008-04-11 18:01:50 +0000283 depends on SERIAL_SET_SPEED
Jordan Crousef6145c32008-03-19 23:56:58 +0000284 default 115200
285
Ulf Jordan2aea11f2008-08-18 19:29:41 +0000286config SERIAL_ACS_FALLBACK
287 bool "Use plain ASCII characters for ACS"
288 default n
289 depends on SERIAL_CONSOLE
290 help
291 The alternate character set (ACS) is used for drawing lines and
292 displaying a couple of other special graphics characters. The
293 ACS characters generally look good on screen, but can be difficult
294 to cut and paste from a terminal window to a text editor.
Stefan Reinauer14e22772010-04-27 06:56:47 +0000295
Ulf Jordan2aea11f2008-08-18 19:29:41 +0000296 Say 'y' here if you want to always use plain ASCII characters to
Stefan Reinauer14e22772010-04-27 06:56:47 +0000297 approximate the appearance of ACS characters on the serial port
Ulf Jordan2aea11f2008-08-18 19:29:41 +0000298 console.
299
Jordan Crouse30939bd2008-04-10 22:49:02 +0000300config VIDEO_CONSOLE
301 bool "See output on a video console"
302 default y
303
304config VGA_VIDEO_CONSOLE
305 bool "VGA video console driver"
Stefan Reinauer8af0d032012-12-14 13:05:21 -0800306 depends on ARCH_X86 && VIDEO_CONSOLE
Julius Werner58caa8b2016-05-16 16:37:56 -0700307 default y if !CHROMEOS
Jordan Crousef6145c32008-03-19 23:56:58 +0000308
Peter Stuge4b1971c2008-10-08 14:47:41 +0000309config GEODELX_VIDEO_CONSOLE
310 bool "Geode LX video console driver"
Stefan Reinauer8af0d032012-12-14 13:05:21 -0800311 depends on ARCH_X86 && VIDEO_CONSOLE
Jordan Crouse54315532008-04-11 15:48:21 +0000312 default n
313
Stefan Reinauerb7002542010-03-25 18:56:26 +0000314config COREBOOT_VIDEO_CONSOLE
315 bool "coreboot video console driver"
316 depends on VIDEO_CONSOLE && !GEODELX_VIDEO_CONSOLE
Julius Werner58caa8b2016-05-16 16:37:56 -0700317 default y if CHROMEOS
Stefan Reinauerb7002542010-03-25 18:56:26 +0000318 default n
319 help
320 Say Y here if coreboot switched to a graphics mode and
321 your payload wants to use it.
322
Nico Huberde748422020-01-23 13:23:09 +0100323config COREBOOT_VIDEO_CENTERED
324 bool "Center a classic 80x25 console on bigger screens"
325 depends on COREBOOT_VIDEO_CONSOLE
326 help
327 Say 'y' here if your payload is hardcoded to a 80x25 console. Otherwise
328 its output would look squeezed into the upper-left corner of the screen.
329
Paul Kocialkowskid85e4852017-07-23 16:05:47 +0300330config FONT_SCALE_FACTOR
331 int "Scale factor for the included font"
332 depends on GEODELX_VIDEO_CONSOLE || COREBOOT_VIDEO_CONSOLE
333 default 0
334 help
335 By default (value of 0), the scale factor is automatically
336 calculated to ensure at least 130 columns (when possible).
337
Patrick Rudolphe6a38212017-03-01 19:07:37 +0100338config PC_I8042
339 bool "A common PC i8042 driver"
Patrick Rudolph5afc2932017-02-06 15:26:58 +0100340 default y if PC_KEYBOARD || PC_MOUSE
Patrick Rudolphe6a38212017-03-01 19:07:37 +0100341 default n
342 help
343 To be used by PC_KEYBOARD and PC_MOUSE.
344
Patrick Rudolph5afc2932017-02-06 15:26:58 +0100345config PC_MOUSE
346 bool "Allow input from a PC mouse"
Patrick Georgie8604b82018-05-17 17:57:14 +0200347 default n if CHROMEOS
Patrick Rudolph5afc2932017-02-06 15:26:58 +0100348 default y if ARCH_X86 # uses IO
349 default n
350 help
351 PS/2 mouse driver on top of PC_I8042.
352
Jordan Crousef6145c32008-03-19 23:56:58 +0000353config PC_KEYBOARD
Uwe Hermann2d758b82008-03-31 15:21:24 +0000354 bool "Allow input from a PC keyboard"
Marc Jones019bacb42014-12-23 15:22:30 -0700355 default y if ARCH_X86 # uses IO
356 default n
Jordan Crousef6145c32008-03-19 23:56:58 +0000357
Eric Laib643d3d2019-12-09 15:05:12 +0800358config PC_KEYBOARD_AT_TRANSLATED
359 bool "AT Translation keyboard device"
360 default n
361
Stefan Reinauerd84ef1e2008-09-26 18:37:26 +0000362config PC_KEYBOARD_LAYOUT_US
363 bool "English (US) keyboard layout"
364 depends on PC_KEYBOARD
365 default y
366
367config PC_KEYBOARD_LAYOUT_DE
368 bool "German keyboard layout"
369 depends on PC_KEYBOARD
370 default n
371
Stefan Reinauer69863582008-08-08 13:45:03 +0000372endmenu
373
374menu "Drivers"
375
376config PCI
377 bool "Support for PCI devices"
Stefan Reinauer8af0d032012-12-14 13:05:21 -0800378 depends on ARCH_X86 # for now
Stefan Reinauer69863582008-08-08 13:45:03 +0000379 default y
380
Uwe Hermannc16d24e2008-03-31 15:17:39 +0000381config NVRAM
Uwe Hermann2d758b82008-03-31 15:21:24 +0000382 bool "Support for reading/writing NVRAM bytes"
Stefan Reinauer8af0d032012-12-14 13:05:21 -0800383 depends on ARCH_X86 # for now
Uwe Hermann2d758b82008-03-31 15:21:24 +0000384 default y
Uwe Hermann8cc38d22008-03-27 23:26:40 +0000385
Patrick Rudolph837da6a2017-02-06 15:02:25 +0100386config MOUSE_CURSOR
387 bool "Support for mouse cursor handling"
Patrick Rudolph5afc2932017-02-06 15:26:58 +0100388 default y if PC_MOUSE
Patrick Rudolph837da6a2017-02-06 15:02:25 +0100389 default n
390 help
391 Provides a common interface for various mouse cursor drivers.
392 * Supports up to 32 buttons.
393 * Supports 3 axis mice.
394 * Applies simple cursor acceleration.
395 * Allows to set cursor acceleration and cursor speed.
396
Uwe Hermann30d789b2008-03-31 20:21:49 +0000397config RTC_PORT_EXTENDED_VIA
398 bool "Extended RTC ports are 0x74/0x75"
399 default n
400 help
401 For recent chipsets with 256 NVRAM bytes, you have to access the
402 upper 128 bytes (128-255) using two different I/O ports,
403 usually 0x72/0x73.
Stefan Reinauer14e22772010-04-27 06:56:47 +0000404
Uwe Hermann30d789b2008-03-31 20:21:49 +0000405 On some chipsets this can be a different set of ports, though.
406 The VIA VT8237R for example only recognizes the ports 0x74/0x75
407 for accessing the high 128 NVRAM bytes (as seems to be the case for
408 multiple VIA chipsets).
Stefan Reinauer14e22772010-04-27 06:56:47 +0000409
Uwe Hermann30d789b2008-03-31 20:21:49 +0000410 If you want to read or write CMOS bytes on computers with one of
411 these chipsets, say 'y' here.
412
Stefan Reinauer69863582008-08-08 13:45:03 +0000413config SPEAKER
414 bool "Support for PC speaker"
Stefan Reinauer8af0d032012-12-14 13:05:21 -0800415 depends on ARCH_X86
Julius Werner58caa8b2016-05-16 16:37:56 -0700416 default y if !CHROMEOS
Jordan Crousef6145c32008-03-19 23:56:58 +0000417
Antonello Dettoriaded2142016-07-27 12:41:04 +0200418source "drivers/timer/Kconfig"
419source "drivers/storage/Kconfig"
420source "drivers/usb/Kconfig"
huang lin41e24992015-05-20 17:27:10 +0800421
Stefan Reinauere5d30b72010-03-25 22:15:19 +0000422endmenu
423
424menu "Debugging"
425 depends on DEVELOPER
426
427config DEBUG_MALLOC
428 bool "Debug memory allocator"
Stefan Reinauere5d30b72010-03-25 22:15:19 +0000429 default n
430 help
431 Select this option if you want to debug the memory allocator. This
432 option logs all uses of the following functions:
433
434 void free(void *ptr);
435 void *malloc(size_t size);
436 void *calloc(size_t nmemb, size_t size);
437 void *realloc(void *ptr, size_t size);
438 void *memalign(size_t align, size_t size);
439
440 Say N here unless you are debugging memory allocator problems.
Patrick Georgid21f68b2008-09-02 16:06:22 +0000441
Jordan Crousef6145c32008-03-19 23:56:58 +0000442endmenu
Stefan Reinauer69863582008-08-08 13:45:03 +0000443
Gabe Black0af03d22012-03-19 03:06:46 -0700444config BIG_ENDIAN
445 default n
446 bool
447
448config LITTLE_ENDIAN
449 default n
450 bool
451
Gabe Blackd2679872013-01-18 15:49:00 -0800452config IO_ADDRESS_SPACE
453 default n
454 bool
Stefan Reinauer347a7522016-03-12 11:48:44 -0800455 help
456 This option is turned on if the target system has a separate
457 IO address space. This is typically only the case on x86.
Gabe Blackd2679872013-01-18 15:49:00 -0800458
Stefan Reinauerdee44202015-06-11 14:33:11 -0700459source "arch/arm/Kconfig"
460source "arch/arm64/Kconfig"
Stefan Reinauerdee44202015-06-11 14:33:11 -0700461source "arch/x86/Kconfig"